Download integrator.io Postman collection
Understand and create custom flows
Contents
Flow API endpoints
Relative URI | Method | Success code | Description |
/flows | GET | 200 | Get all flows. |
POST | 201 | Create a flow. | |
/flows/<_id> | GET | 200 | Get a specific flow. |
PUT | 200 | Update a specific flow. | |
DELETE | 204 | Delete a specific flow. | |
/flows/<_id>/clone | POST | 201 | Clone a specific flow. |
/flows/<_id>/run | POST | 201 | Run a specific flow on demand. |
/flows/<_id>/audit | GET | 200 | Get a log for a specific flow. |
Flow API examples
GET /v1/flows/55e••••••••••••••••••367 HTTP/1.1
Host: api.integrator.io
Authorization: Bearer my_api_token
Sample response
{ "_id":"55e••••••••••••••••••367", "lastModified":"2017-06-19T21:27:09.945Z", "name":"Send GitHub Events to Slack", "disabled":false, "timezone":"America/Los_Angeles", "_exportId":"55e••••••••••••••••••366", "_importId":"55e••••••••••••••••••d14", "_integrationId":"58f••••••••••••••••••1bc", "skipRetries":false, "createdAt":"2017-06-19T21:27:09.900Z" }
GET /v1/flows/598••••••••••••••••••d9a HTTP/1.1
Host: api.integrator.io
Authorization: Bearer my_api_token
Sample response
{ "_id":"598••••••••••••••••••d9a", "lastModified":"2017-08-19T17:04:54.005Z", "name":"Update Usage Stats for all Trialers", "disabled":false, "schedule":"? 0 2 ? * *", "timezone":"America/Los_Angeles", "_integrationId":"593••••••••••••••••••74e", "skipRetries":false, "pageProcessors":[ { "type":"export", "_exportId":"598••••••••••••••••••428", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numConnections" } ] } }, { "type":"export", "_exportId":"598••••••••••••••••••d32", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"dlSuccessAndErrors" } ] } }, { "type":"export", "_exportId":"598••••••••••••••••••6c6", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"lastSignIn" } ] } }, { "type":"export", "_exportId":"598••••••••••••••••••638", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numDataLoaders" } ] } }, { "type":"export", "_exportId":"598e0c", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numFlows" } ] } }, { "type":"export", "_exportId":"598••••••••••••••••••54b", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numPasswordChanges" } ] } }, { "type":"export", "_exportId":"598••••••••••••••••••e22", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numPasswordResets" } ] } }, { "type":"export", "_exportId":"598e29", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"numSignIns" } ] } }, { "type":"export", "_exportId":"598e37", "responseMapping":{ "lists":[], "fields":[ { "extract":"data", "generate":"successAndErrors" } ] } }, { "type":"import", "_importId":"598••••••••••••••••••615", "proceedOnFailure":true, "responseMapping":{ "lists":[], "fields":[] } }, { "type":"import", "_importId":"598••••••••••••••••••9f9", "responseMapping":{ "lists":[], "fields":[] } } ], "pageGenerators":[ { "_exportId":"598••••••••••••••••••286", "_id":"599••••••••••••••••••b36" }, { "_exportId":"598••••••••••••••••••6dd", "_id":"599••••••••••••••••••b35" } ], "createdAt":"2017-08-01T20:43:42.156Z" }
POST /v1/flows/55e••••••••••••••••••367 HTTP/1.1
Host: api.integrator.io
Authorization: Bearer my_api_token
Sample body
Send a JSON body payload and the POST /run command in the following syntax. In this example, the delta startDate would be January 1st, 2019.
{"export": {"startDate": 2019-01-01T00:00:00.000"}}
Comments
5 comments
Hello,
What are the parameters (both required and optional) for `/flows/<_id>/clone` and response?
Thank you!
Pablo Gonzalez here you go. We'll get docs updated as well.
Hi Tyler Lamparter,
Awesome, thank you for the info. I saw the connectionMap and was wondering why it was being written twice and decided to try this another time. I looked at it again today and it makes sense! It's literally mapping the amount of connections from the source flow to the destination flow. I was able to successfully clone my flow via API, thank you again for your quick response!
- Pablo G.
Hi Tyler Lamparter. Am I able to send non date parameters using the Flow Run Endpoint?
Example:
I Know the endDate and startDate are both mapping to currentExportDateTime and lastExportDateTime respectively, but I'm not able to use additional parameters as the sku on the example.
This behavior would be helpful for APIs that are not based on Dates for filtering.
Using the Run Export API, I'm able to send that SKU parameter, but not on the Flow API.
Emil Daniel Ordoñez Avila unfortunately not at this time. It is currently slated as an enhancement for summer/fall of this year.
Please sign in to leave a comment.