Update flow
const url = 'https://api-dev.mindflow.io/v1/organizations/ORGA-57b858ed-ec60-4507-b2ef-ea58244ac742/flows/PLAY-17a64601-40bb-4304-90f8-08ebf6ae3c19';const options = { method: 'PATCH', headers: { Authorization: 'Bearer <token>', 'Content-Type': 'application/merge-patch+json' }, body: '{ "timeout": 600, "notifyOnError": true, "emailsToNotify": [ "ops@example.com" ] }'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://api-dev.mindflow.io/v1/organizations/ORGA-57b858ed-ec60-4507-b2ef-ea58244ac742/flows/PLAY-17a64601-40bb-4304-90f8-08ebf6ae3c19 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/merge-patch+json' \ --data '{ "timeout": 600, "notifyOnError": true, "emailsToNotify": [ "ops@example.com" ] }'Partially updates a flow. JSON null clears nullable fields (description, icon, emailsToNotify,
outputSchema). Arrays replace wholesale. Returns the updated flow.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Opaque id of the organization that owns the resource. In a playbook step this can be filled from the current organization when the caller leaves it unset.
Opaque id of the organization. Pass it unchanged.
Example
ORGA-57b858ed-ec60-4507-b2ef-ea58244ac742Opaque id of a flow. Use it on get, update, delete, versions, and when deploying the flow.
Opaque id of the flow. Pass it unchanged.
Example
PLAY-17a64601-40bb-4304-90f8-08ebf6ae3c19Request Bodyrequired
Section titled “Request Bodyrequired”Fields to change. Omitted fields stay as they are. JSON null clears a clearable field. Arrays replace wholesale. Content type is application/merge-patch+json (JSON Merge Patch, RFC 7396).
Fields to change. Omitted fields stay as they are. JSON null clears a clearable field. Arrays replace wholesale.
object
New name people see for this flow. 1 to 128 characters. Control characters are rejected.
A user-friendly description of the flow. Null clears the field.
URL to an icon representing the flow. Null clears the field.
Execution timeout for the flow in seconds.
Email addresses to notify on flow events. Null clears the list.
Whether to send notifications on flow errors.
Whether to send notifications on flow success.
Schema of the flow’s output. Null clears the schema.
object
Example
{ "timeout": 600, "notifyOnError": true, "emailsToNotify": [ "ops@example.com" ]}Responses
Section titled “Responses”The flow was successfully updated.
Metadata for one flow. Steps, links, and the canvas are not included.
Use flowId for later calls. timeout is how long one run may last, in seconds.
object
Organization that owns this flow. Same value as the organizationId path parameter.
Opaque id of this flow.
Name people see for this flow. 1 to 128 characters. Control characters are rejected.
Icon for the flow. This may be an absolute URL or a short emoji. Maximum 200 characters.
Optional note about what the flow does. Maximum 1000 characters. Empty when unset.
How long one run of this flow may last, in seconds. Minimum 1. Create requires this field.
Email addresses notified about runs. Maximum 25 addresses. Each address is at most 254 characters. The whole array is replaced on update.
When true, send mail to emailsToNotify after a run fails. When false or omitted, do not send that mail.
When true, send mail to emailsToNotify after a run succeeds. When false or omitted, do not send that mail.
JSON Schema for the value the flow returns. Callers use it to know the output shape. An empty object means no output schema is set. Extra keywords inside the schema are preserved.
object
When the flow was created, as ISO 8601 UTC.
When the flow metadata was last changed, as ISO 8601 UTC.
Example
{ "organizationId": "$CURRENT_ORGANIZATION_ID", "flowId": "PLAY-17a64601-40bb-4304-90f8-08ebf6ae3c19", "name": "Export audit logs", "icon": "https://cdn.example.com/icons/flow.png", "description": "Writes the latest audit page to storage.", "timeout": 300, "emailsToNotify": [ "ops@example.com" ], "notifyOnError": true, "notifyOnSuccess": false, "outputSchema": { "type": "object", "properties": { "status": { "type": "string" } } }, "createdAt": "2026-03-01T09:00:00.000Z", "updatedAt": "2026-03-20T15:30:45.123Z"}Headers
Section titled “Headers”Example
1000Maximum number of requests allowed in the current window. Present when this response is rate limited.
Example
42Number of requests still allowed in the current window. 0 means the next call can return 429 until the window resets.
Example
2026-03-20T15:31:00.000ZTime when the current window resets, as ISO 8601 UTC. After this time, X-RateLimit-Remaining starts over.
Example
30HTTP Retry-After value in seconds. Wait at least this long before retrying a 429 response.
Example
*CORS Access-Control-Allow-Origin value. Origin allowed to read this response from a browser. * means any origin may read it.
The request was invalid. Common causes include:
- Invalid timestamp format.
- Using
cursorwithbeforeorafter. - Missing
limitwhen usingbeforeorafter. - Invalid field names in the
fieldsparameter.
See the error response for specific details about what went wrong.
object
URI reference identifying the problem type. When absent, “about:blank” per RFC 9457 Section 3.1.1.
Short, human-readable summary of the problem type (RFC 9457 Section 3.1.3).
HTTP status code for this occurrence (advisory; same as response status) (RFC 9457 Section 3.1.2).
Human-readable explanation specific to this occurrence (RFC 9457 Section 3.1.4).
URI reference identifying the specific occurrence (RFC 9457 Section 3.1.5).
Always BAD_REQUEST on this response. Read detail for which value to change, then send a corrected request.
Example
{ "type": "about:blank", "title": "Bad Request", "status": 400, "detail": "The request body or query is invalid.", "code": "BAD_REQUEST"}Headers
Section titled “Headers”Example
1000Maximum number of requests allowed in the current window. Present when this response is rate limited.
Example
42Number of requests still allowed in the current window. 0 means the next call can return 429 until the window resets.
Example
2026-03-20T15:31:00.000ZTime when the current window resets, as ISO 8601 UTC. After this time, X-RateLimit-Remaining starts over.
Example
30HTTP Retry-After value in seconds. Wait at least this long before retrying a 429 response.
Example
*CORS Access-Control-Allow-Origin value. Origin allowed to read this response from a browser. * means any origin may read it.
Authentication failed. The request lacks valid credentials or the provided credentials are invalid.
Ensure you have:
- A valid API key or token.
- Proper authentication headers.
- Required permissions.
object
URI reference identifying the problem type. When absent, “about:blank” per RFC 9457 Section 3.1.1.
Short, human-readable summary of the problem type (RFC 9457 Section 3.1.3).
HTTP status code for this occurrence (advisory; same as response status) (RFC 9457 Section 3.1.2).
Human-readable explanation specific to this occurrence (RFC 9457 Section 3.1.4).
URI reference identifying the specific occurrence (RFC 9457 Section 3.1.5).
Always MISSING_OR_INVALID_TOKEN on this response. Branch on this value, not on detail.
Example
{ "type": "about:blank", "title": "Unauthorized", "status": 401, "detail": "The bearer token is missing or invalid.", "code": "MISSING_OR_INVALID_TOKEN"}Headers
Section titled “Headers”Example
1000Maximum number of requests allowed in the current window. Present when this response is rate limited.
Example
42Number of requests still allowed in the current window. 0 means the next call can return 429 until the window resets.
Example
2026-03-20T15:31:00.000ZTime when the current window resets, as ISO 8601 UTC. After this time, X-RateLimit-Remaining starts over.
Example
30HTTP Retry-After value in seconds. Wait at least this long before retrying a 429 response.
Example
*CORS Access-Control-Allow-Origin value. Origin allowed to read this response from a browser. * means any origin may read it.
Too many requests. The request rate limit has been exceeded.
Please wait until the rate limit window resets before making additional requests.
object
URI reference identifying the problem type. When absent, “about:blank” per RFC 9457 Section 3.1.1.
Short, human-readable summary of the problem type (RFC 9457 Section 3.1.3).
HTTP status code for this occurrence (advisory; same as response status) (RFC 9457 Section 3.1.2).
Human-readable explanation specific to this occurrence (RFC 9457 Section 3.1.4).
URI reference identifying the specific occurrence (RFC 9457 Section 3.1.5).
Always RATE_LIMIT_EXCEEDED on this response. Wait Retry-After seconds before retrying.
Example
{ "type": "about:blank", "title": "Too Many Requests", "status": 429, "detail": "The request rate limit has been exceeded.", "code": "RATE_LIMIT_EXCEEDED"}Headers
Section titled “Headers”Example
1000Maximum number of requests allowed in the current window. Present when this response is rate limited.
Example
42Number of requests still allowed in the current window. 0 means the next call can return 429 until the window resets.
Example
2026-03-20T15:31:00.000ZTime when the current window resets, as ISO 8601 UTC. After this time, X-RateLimit-Remaining starts over.
Example
30HTTP Retry-After value in seconds. Wait at least this long before retrying a 429 response.
Example
*CORS Access-Control-Allow-Origin value. Origin allowed to read this response from a browser. * means any origin may read it.
Internal server error. The server encountered an unexpected condition that prevented it from fulfilling the request.
Please try again later or contact support if the problem persists.
object
URI reference identifying the problem type. When absent, “about:blank” per RFC 9457 Section 3.1.1.
Short, human-readable summary of the problem type (RFC 9457 Section 3.1.3).
HTTP status code for this occurrence (advisory; same as response status) (RFC 9457 Section 3.1.2).
Human-readable explanation specific to this occurrence (RFC 9457 Section 3.1.4).
URI reference identifying the specific occurrence (RFC 9457 Section 3.1.5).
Always INTERNAL_ERROR on this response. Retry later. Do not retry a create in a tight loop.
Example
{ "type": "about:blank", "title": "Internal Server Error", "status": 500, "detail": "The request could not be completed.", "code": "INTERNAL_ERROR"}Headers
Section titled “Headers”Example
1000Maximum number of requests allowed in the current window. Present when this response is rate limited.
Example
42Number of requests still allowed in the current window. 0 means the next call can return 429 until the window resets.
Example
2026-03-20T15:31:00.000ZTime when the current window resets, as ISO 8601 UTC. After this time, X-RateLimit-Remaining starts over.
Example
30HTTP Retry-After value in seconds. Wait at least this long before retrying a 429 response.
Example
*CORS Access-Control-Allow-Origin value. Origin allowed to read this response from a browser. * means any origin may read it.