Update Workflow
This endpoint allows you to add and remove users from a workflow and allows you to change the workflow name.
User Management: This endpoint is primarily used for managing workflow access permissions and updating basic workflow settings like the name.
POST Parameters
| Parameter | Required | Value | Description |
|---|---|---|---|
api_key | {key} | An API key that has access to the resource you want to query for | |
workflow_id | {integer} | The ID of a specific workflow | |
user_ids | {integer} | The IDs of all the users to add to the workflow, comma separated | |
settings | {xml} | Pass additional information when updating the workflow. Example: <name>New Name</name> |
Code Examples
The cURL, PHP, Python, Node.js, and C# examples call Xtracta from a trusted server. The React example calls an application-defined backend proxy so the API key is never exposed in browser code.
Store XTRACTA_API_KEY as a server-side environment variable. Never embed it in browser-delivered code.
curl --request POST 'https://api-app.xtracta.com/v1/workflow/update' \ --header 'Accept: application/json' \ --header 'Content-Type: application/x-www-form-urlencoded' \ --data-urlencode 'api_key=<API_KEY>' \ --data-urlencode 'workflow_id=<WORKFLOW_ID>' \ --data-urlencode 'user_ids=<USER_IDS>'
Sample Request
POST https://api-app.xtracta.com/v1/workflow/update HTTP/1.1 api_key=123&workflow_id=456789&user_ids=123,456,789
Sample Response
<?xml version="1.0" encoding="UTF-8"?>
<workflow_response>
<status>200</status>
<message>The request has been successfully processed</message>
</workflow_response>
Schema Definition
Response Elements
| Element | Description |
|---|---|
<status> | A status code in response to the operation. |
<message> | Additional information about the operation – human readable. |
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
<xs:simpleType name="ConfidenceType">
<xs:union>
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
<xs:maxInclusive value="100"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value=""/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
<xs:element name="workflow_response">
<xs:complexType>
<xs:sequence>
<xs:element name="status" type="xs:positiveInteger"/>
<xs:element name="message" type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Error Responses
For JSON and XML responses generated by this endpoint, the response is wrapped in workflow_response and includes the HTTP status code and a message.
| Status | Message | Description |
|---|---|---|
400 | workflow_id is required / workflow_id must be natural number | Supply the positive integer workflow ID to update. |
400 | user_ids must be comma separated values | Supply user IDs as a comma-separated list; negative IDs remove assignments. |
400 | new_group_id must be natural number | Use a positive integer target group ID. |
400 | Invalid XML format provided in settings parameter / Invalid XML format in settings | Supply well-formed XML in settings. |
400 | Either user_ids, new_group_id or settings must be passed | Supply at least one update operation. |
400 | The user(...) is not assigned / The user(...) is already assigned | Correct the requested user-assignment change. |
400 | Workflow name should be specified | Include <name> in settings. |
400 | Target group is the same as current group / Target group is invalid | Select a valid subgroup different from the current group. |
400 | Active workflow with related database(s) cannot be moved into the other group | Remove the incompatible database relationship or do not move the active workflow. |
500 | Internal server error occurred. Please try again later or contact support@xtracta.com | Retry and contact support with the request parameters and timestamp if it persists. |
Authentication, permission, IP-access-control, and rate-limit failures can be returned before this endpoint processes the request. Confirm the API key and caller access first.