PUT
/v1/postflows/{id}/flow/draftReplace the journey draft
Send the revision from the last read in If-Match; a stale revision answers 412. A draft may hold issues (see validate); publishing refuses errors. A secret header takes a new value or, without one, keeps the value it had. Needs the flow builder.
Scope
postflows.writePath parameters
idstringrequiredHeaders
If-MatchstringBody
definitionobjectrequired2 fields
schemaVersionnumberrequiredstepsarray of objectsrequiredmin items 1Returns
8 fields of the 200 answer
postflowIdstringrequiredbuilderbooleanrequiredWhether the plan has the flow builder
simplebooleanrequiredWhether the published journey is only "trigger, then Send card"
currentobjectrequired4 fields
versionIdstring or nullrequirednumberinteger or nullrequiredpublishedAtdate-time or nullrequireddefinitionobjectrequired2 fields
schemaVersionnumberrequiredstepsarray of one ofrequireddraftobject or nullrequired4 fields
definitionobjectrequired2 fields
schemaVersionnumberrequiredstepsarray of one ofrequiredrevisionintegerrequiredupdatedAtdate-time or nullrequiredupdatedByIdstring or nullrequiredrevisionintegerrequiredThe draft revision to send in If-Match
versionsarray of objectsrequired7 fields
idstringrequirednumberintegerrequiredpublishedAtdate-timerequiredpublishedByTypestringrequiredpublishedByIdstring or nullrequiredstepsintegerrequiredcurrentbooleanrequiredsigningSecretSetbooleanrequiredResponses
200Success
401Authentication required or API key invalid
403Permission or scope missing, organisation suspended
404Not found
412The flow was saved elsewhere (draft_conflict)
422Validation failed
429Rate limited for this API key and class; wait Retry-After seconds
otherError (RFC 9457 problem details)