IFTTT webhook to google sheets - google-sheets

I am sending a request to a IFTTT webhook, which receives the request and saves it to a google sheets file.
There are a few predefined available fields that I can use to send to IFTTT, which in turn get passed forward to the google sheets file (Value1, Value2, Value3).
When sending the request to IFTTT, I can pass those fields in the JSON object I am sending, like this:
{
"value1": article.title,
"value2": article.summary,
"value3": article.text,
}
The problem arises if I wish to send another value. Imagine I want to add an "image" field. I can update the JSON to be sent to:
{
"value1": article.title,
"value2": article.summary,
"value3": article.text,
"image": article.image
}
but within IFTTT, if I try to add that field in the action to send it to google, I can save the applet (even though the field shows up in red) but nothing gets passed to the google sheets file in that field (the other 3 fields are still being sent).
Where and how can I add the extra field? Do I need to change something in the webhook, do something in the filter, or how can I pass other, custom fields?
Thank you.

This can't be done the way I was looking to do it.
You cannot add custom fields to the webhook.
What I ended up doing was sending all of the fields I needed inside VALUE1 as JSON, and forward that to another service to be processed.
Hell of a hack, but seems like an IFTTT limitation. In the meanwhile I have migrated to Zapier, and it's a whole different world!

Related

jira createmeta not showing all customfields

If I navigate to /rest/api/2/issue/createmeta/PROJ/issuetype/N (in this case, I'm getting Task), the list of fields returned is incomplete. There are a number of customfields that are in use (I can see them both in the tickets themselves, and also in /plugins/servlet/project-config/PROJ/fields ) that are in the createmeta data.
I'm really trying to do this in python jira, where I'm using "expand='projects.issuetypes.fields'" in the createmeta() call, but I figured I'd double-check the results in the rest API directly, and I'm getting the same results there, too.
This is happening in jira 8.20.7.
Essentially, what I'm trying to do, is to programatically get a name/id mapping of all fields in the ticket type. I'm having far more difficulty doing that than I thought there would be. I would do it based on /rest/api/2/field but the jira admins have allowed some duplicated names...
EDIT: I realized that it might be worth noting that some of the fields I'm looking for are coming from a ServiceDesk form, although, as far as I can tell, there's no way to determine that, since one of the missing fields contains the name of the form.
Why are you using createmeta endpoint?
Instead of that, in order to get all of the customfields and their values; just note their id and get the values from /rest/api/2/issue/{issueKey} endpoint.
When you send a GET request to /rest/api/2/issue/{issueKey} endpoint, you will get a JSON object which contains "fields" object in it.
And using the "fields" you can determine all of the values that include system fields (description, assignee, etc.) and custom fields (like customfield_<customfieldid>).
And for a general approach, you may want to look at the field types in that response.

Zapier - Zap, How to call an Action on a list one by one

I'm configuring a zap which does the following:
Get a list of emails from an API endpoint.
Subscribe each record to Mailchimp
My problem here is that the subscriber email takes in a list of emails and this returns the following error message:
Bargle. We hit an error creating a subscriber. :-( Error: Invalid
Resource - Please provide a valid email address.
This is because Mailchimp aparently doesn't allow multple subscriptions in one single form.
So my question is, is there a way to perform an action per element in the list ?
Some sort of
emailList.foreach(function(email){
performAction(email);
})
Note that I cannot use the cli, is this possible with some sort of funnel action in zapier or maybe using the scrpting ?
Thanks
David here, from the Zapier Platform team.
By default, when a trigger returns a top-level list of objects, subsequent actions occur for each. I'm not sure what type of trigger you're working with, but make sure it returns an object like this:
return [{email: 'email1#gmail.com'}, {email: 'email2#gmail.com'}, {email: 'email3#gmail.com'}]
and it should work as expected.

Loop through Zapier webhook result

Just trying to figure out if it is possible to loop through Zapier webhook result set and do something with it.
I have a zap that runs once a day and makes a GET request to a specific URL. There's a JSON result that comes back and now I would like to loop through this resultset and fetch emails from each record for using this email list when sending emails with Mailgun.
Any hints?
Yes, that's possible! Zapier can loop through actions up to 25 times. You just need to give it data in the right format (an array of JSON objects).
Here's the steps you'd have in your zap:
Scheduler trigger to run the zap each day
Your webhook GET request
Code step which takes your webhook result, and converts it into an array of JSON objects with email addresses in them
Do something for each email address. You can pick any zapier action, and it will run for every address.
Add any more actions that you want for every email address here...
I think the simpler approach is to use a "Code by Zapier" action and make the HTTP request directly in the code where you can process the response.
Some more info here.

Office 365 - Filter on expanded messages

Thanks to How do I retrieve the event for an eventMessage we've sucessfully retrieve now the events in our inbox on o365.
Now our problem is that we want to show the user only events to which he hasn't responded. We've tried things like:
$expand=Microsoft.OutlookServices.EventMessage/Event($filter=ResponseStatus/Response%20eq%20'NotResponded')
But without success, we still get accepted events. If we try to put it outside in a filter
$filter=Microsoft.OutlookServices.EventMessage/Event/ResponseStatus/Response%20eq%20'NotResponded'
we get an error like "message": "The query filter contains one or more invalid nodes."
Is there an easy way to achieve that without a filtering inside the application?
It seems that ResponseStatus/Response is marked as not filterable, so this cannot be achieved in this fashion

How do I get the date a text message was sent to my Twilio number?

I try to get and analyse data from text with the Twilio API. With their example, I can get the phone number from the text is sent, but I would like to get the datetime and the body of the message.
For the phone nmber you just have to use that:
$phone = $_REQUEST['From'];
It works also for To and Body but I tried with DateSent and it's not working.
$date = $_REQUEST['DateSent'];
Do you have an idea about what could be the word to get it?
According to the Twilio Docs the date is not sent as a parameter. However, you can use the Rest API to retrieve the SMS using the $_REQUEST['SmsSid'], and the returned data will contain a DateCreated.
Note: As John commented, unless you really need the 'official' timestamp, it's essentially the current time. Also note that if you try to query the API for a message that just came in, it may not have propagated, so you may not not get the data you're requesting.
If there's some use case where you can't just use the current timestamp, that would be interesting.

Resources