Templates

Create template

Changed on

Creates an approval template. A customer can create a maximum of 1000 templates. Requires template management permissions.

post/api/v1/templates

Request

  • Base URL: https://workfront.adobe.io/workfront-approvals
  • URL: https://workfront.adobe.io/workfront-approvals/api/v1/templates
  • Auth: HTTP bearer

Headers

x-api-keystring required

client_id of the Adobe Developer Console technical account. Identifies the calling integration to the AIO gateway.

x-gw-subdomainstring required

Workfront customer subdomain (e.g. mycompany). Must match the subdomain of the Workfront instance being accessed. Passing an incorrect or unrecognized subdomain will result in a 502 Bad Gateway response from the AIO gateway.

wf-customeridstring required

Workfront customer ID.

wf-useridstring required

Workfront user ID of the acting user.

wf-lane'prod' | 'preview' | 'hub' | 'staging' | 'devtest' required

Workfront deployment lane.

x-request-idstring uuid

Unique identifier for request tracing. Auto-generated if not provided.

x-correlation-idstring

Unique identifier for correlation across multiple service calls. Auto-generated if not provided.

Request body

namestring required

Display name of the template.

assetType'DOCV'

Asset type the template applies to.

companyIdstring nullable

Example request

{
  "name": "Test Template",
  "stages": [
    {
      "stageId": "stage-1",
      "name": "Stage 1",
      "parentIds": [],
      "triggers": [
        {
          "type": "activation",
          "when": "onCreate"
        }
      ],
      "deadlineBusinessDays": 3,
      "deadlineTimeOfDay": {
        "hours": 17,
        "minutes": 0
      },
      "participants": [
        {
          "participantId": "user-123",
          "participantType": "USER",
          "participantRole": "approver",
          "participantMetadata": {}
        }
      ]
    },
    {
      "stageId": "stage-2",
      "name": "Stage 2",
      "parentIds": [
        "stage-1"
      ],
      "triggers": [
        {
          "type": "activation",
          "when": "onStagesComplete",
          "parameters": {
            "stages": [
              "stage-1"
            ],
            "allowedDecisions": [
              "approved"
            ]
          }
        }
      ],
      "deadlineBusinessDays": 2,
      "deadlineTimeOfDay": {
        "hours": 12,
        "minutes": 30
      },
      "participants": [
        {
          "participantId": "user-456",
          "participantType": "USER",
          "participantRole": "reviewer",
          "participantMetadata": {}
        }
      ]
    }
  ],
  "paths": []
}

Response

OK

templateIdstring
namestring
assetType'DOCV'
timeframeEstimateinteger

Computed timeframe estimate, in business days, derived from the sum of each stage's deadlineBusinessDays value. Read-only.

usageCountinteger
lastUsedOnDatestring date-time
creatorIdstring
createdBystring

Display name of the creator

createdByAvatarDatestring nullable
createdByLinkTostring

Profile URL path, e.g. /USER/{id}/detail

createdByMetadataobject
customerIdstring
companyIdstring nullable
createdAtstring date-time
updatedAtstring date-time
timeframeinteger

Deprecated. Use timeframeEstimate instead. Previously used to store the expected duration of the approval in days.

Example response

{
  "templateId": "template-id",
  "name": "Test Template",
  "assetType": "DOCV",
  "creatorId": "user-id",
  "customerId": "customer-id",
  "stages": [
    {
      "stageId": "stage-1",
      "name": "Stage 1",
      "deadlineBusinessDays": 3,
      "deadlineTimeOfDay": {
        "hours": 17,
        "minutes": 0
      },
      "participants": [
        {
          "participantId": "user-123",
          "participantType": "USER",
          "participantRole": "approver",
          "participantMetadata": {}
        }
      ]
    },
    {
      "stageId": "stage-2",
      "name": "Stage 2",
      "deadlineBusinessDays": 2,
      "deadlineTimeOfDay": {
        "hours": 12,
        "minutes": 30
      },
      "participants": []
    }
  ],
  "structure": [
    {
      "stageId": "stage-1",
      "parentIds": [],
      "triggers": [
        {
          "type": "activation",
          "when": "onCreate"
        }
      ]
    },
    {
      "stageId": "stage-2",
      "parentIds": [
        "stage-1"
      ],
      "triggers": [
        {
          "type": "activation",
          "when": "onStagesComplete",
          "parameters": {
            "stages": [
              "stage-1"
            ],
            "allowedDecisions": [
              "approved"
            ]
          }
        }
      ]
    }
  ],
  "paths": [],
  "usageCount": 0,
  "createdAt": "2026-01-15T17:00:00.000Z",
  "updatedAt": "2026-01-15T17:00:00.000Z"
}

Changes

    • breaking

      removed the enum value needs work of the request property ////////

    • breaking

      removed the enum value needs work of the request property //////

    • info

      removed the needs work enum value from the //////// response property for the response status

    • info

      removed the needs work enum value from the ////// response property for the response status

    • breaking

      the response property ////// became optional for the status

    • breaking

      the response property //// became optional for the status

    • warning

      removed the request property ///////

    • warning

      removed the request property /////

    • warning

      removed the optional property /////// from the response with the status

    • warning

      removed the optional property ///// from the response with the status

    • info

      the request property ////// became optional

    • info

      the request property //// became optional