Apply selected Work Item Enhance drafts
Applies selected field-level drafts to the canonical work item using the run target version. Only explicit selected fields are updated.
POST
/api/v1/work-item-enhancements/:id/applyAuthorization
work-item-enhance:applyapi key scoperequiredRequired scope when calling with an API key.
Path parameters
idstringrequiredEnhancement run id
Example: wie_01k6...
Request body
draft_idsarrayrequiredSelected draft ids to apply. Only one draft per target field is allowed.
expected_target_versionstringrequiredTarget work-item version returned by the run.
confirmbooleanrequiredMust be true.
Example request
{
"draft_ids": [
"draft_01k6..."
],
"expected_target_version": "2026-07-15T14:22:04Z",
"confirm": true
}Request
curl -X POST "https://www.digitalstack360.com/api/v1/work-item-enhancements/wie_01k6.../apply" \
-H "Authorization: Bearer $DS_API_KEY" \
-H "Idempotency-Key: apply-work-42-enhancement-v1" \
-H "Content-Type: application/json" \
-d '{"draft_ids":["draft_01k6..."],"expected_target_version":"2026-07-15T14:22:04Z","confirm":true}'Examples use a placeholder key from your environment. Store your key in $DS_API_KEY — never commit it.
Response
200 OK
{
"data": {
"id": "wie_01k6...",
"state": "applied",
"applied_draft_ids": [
"draft_01k6..."
]
}
}Errors
401
missing_authNo credentials provided
401
invalid_api_keyAPI key is invalid or revoked
400
bad_requestMissing or invalid request fields
403
scope_insufficientKey lacks the required write scope
409
stale_target_versionTarget work item changed after the run was created
409
duplicate_fieldMore than one selected draft targets the same work-item field