---
title: Create a request from a template request
slug: api-guide/create-a-request-from-a-template-request
createdAt: 2026-11-04T16:08:48.743Z
---

{
  "id": "YcP83sbElW4_IU-3lRgZV",
  "type": "api-oas-v2",
  "data": {
    "method": "POST",
    "url": "https://api.app.kognic.com/v2/requests",
    "servers": [
      {
        "url": "https://api.app.kognic.com/v2/requests"
      }
    ],
    "name": "Create a request from a template request",
    "description": "<p>Creates a request in the project by copying a template request, with the given title and externalId, applying the project's default workflow template and phase settings. externalId is the caller's id for the request and is unique per project. The request is created in its own Open input batch. Returns 201 with the created request, in the same shape as listing requests. template picks the request to copy: {\"type\": \"request\", \"requestId\": …} names any request in the same project (it must be in the same project because the new request keeps the template's annotation instruction, which belongs to the project); {\"type\": \"latest_template\"} uses the latest request of the project's latest batch flagged as template, the same request kognic-io's create_batch copies. As with create_batch, a request created from latest_template becomes the project's next latest_template, for every caller; a request created from a named request does not. The new request keeps the template's producer and reviewer organizations, as create_batch does; they are not re-checked against what the caller could pick when creating a request without a template. Requires the Admin or Developer workspace role on the project. A blank title, a blank or whitespace-padded externalId, or a title or externalId longer than 255 characters returns 400; every invalid field is reported in the same response. latest_template on a project without a template batch also returns 400: the project has no template to copy. An unknown project, a project the caller has neither role on, or a template.requestId that is not a request in the project returns 404. An archived project, an externalId already used in the project (the message names the request that uses it, so a retry after a timeout can look it up), or a batch in the project that kognic-io is still setting up (Pending; publish it with publish_batch and retry), returns 409.</p>",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [
        {
          "name": "accept",
          "type": "string",
          "kind": "optional",
          "description": "Generated from available response content types",
          "enum": [
            "application/json"
          ],
          "default": "application/json"
        }
      ],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "required",
          "name": "body",
          "type": "object",
          "description": "",
          "customType": "CreateRequest",
          "schema": [
            {
              "name": "externalId",
              "kind": "required",
              "type": "string",
              "description": ""
            },
            {
              "name": "projectId",
              "kind": "required",
              "type": "string<uuid>",
              "description": "",
              "format": "uuid"
            },
            {
              "name": "template",
              "kind": "required",
              "type": "object",
              "description": "A named request in the same project.",
              "modelRef": "#/components/schemas/RequestTemplate",
              "customType": "RequestTemplate",
              "schema": [
                {
                  "name": "requestId",
                  "kind": "required",
                  "type": "string<uuid>",
                  "description": "",
                  "format": "uuid"
                },
                {
                  "name": "type",
                  "kind": "required",
                  "type": "string",
                  "description": ""
                }
              ]
            },
            {
              "name": "title",
              "kind": "required",
              "type": "string",
              "description": ""
            }
          ],
          "modelRef": "#/components/schemas/CreateRequest",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": [],
      "cookieParameters": []
    },
    "responses": [
      {
        "statusCode": "201",
        "description": "",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Enveloped_Request",
            "schema": [
              {
                "name": "data",
                "kind": "required",
                "type": "object",
                "description": "",
                "modelRef": "#/components/schemas/Request",
                "customType": "Request",
                "schema": [
                  {
                    "name": "createdAt",
                    "kind": "required",
                    "type": "string<date-time>",
                    "description": "",
                    "format": "date-time"
                  },
                  {
                    "name": "id",
                    "kind": "required",
                    "type": "string<uuid>",
                    "description": "",
                    "format": "uuid"
                  },
                  {
                    "name": "inputProgressCounts",
                    "kind": "optional",
                    "type": "object",
                    "description": "",
                    "modelRef": "#/components/schemas/InputProgressCounts",
                    "customType": "InputProgressCounts",
                    "schema": [
                      {
                        "name": "completed",
                        "kind": "required",
                        "type": "integer<int32>",
                        "description": "",
                        "format": "int32"
                      },
                      {
                        "name": "inProgress",
                        "kind": "required",
                        "type": "integer<int32>",
                        "description": "",
                        "format": "int32"
                      },
                      {
                        "name": "notStarted",
                        "kind": "required",
                        "type": "integer<int32>",
                        "description": "",
                        "format": "int32"
                      },
                      {
                        "name": "total",
                        "kind": "required",
                        "type": "integer<int32>",
                        "description": "",
                        "format": "int32"
                      }
                    ]
                  },
                  {
                    "name": "projectId",
                    "kind": "required",
                    "type": "string<uuid>",
                    "description": "",
                    "format": "uuid"
                  },
                  {
                    "name": "title",
                    "kind": "required",
                    "type": "string",
                    "description": ""
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/Enveloped_Request",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "400",
        "description": "Bad request",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "BadRequest",
            "schema": [
              {
                "name": "errorCode",
                "kind": "optional",
                "type": "string",
                "description": ""
              },
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": ""
              }
            ],
            "modelRef": "#/components/schemas/BadRequest",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "401",
        "description": "Unauthorized",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Unauthorized",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": ""
              }
            ],
            "modelRef": "#/components/schemas/Unauthorized",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "404",
        "description": "Not found",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "NotFound",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": ""
              }
            ],
            "modelRef": "#/components/schemas/NotFound",
            "isExpanded": true
          }
        ]
      },
      {
        "statusCode": "409",
        "description": "Conflict",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "Conflict",
            "schema": [
              {
                "name": "message",
                "kind": "required",
                "type": "string",
                "description": ""
              }
            ],
            "modelRef": "#/components/schemas/Conflict",
            "isExpanded": true
          }
        ]
      }
    ],
    "hasXCodeSamples": false,
    "examples": {
      "languages": [
        {
          "id": "example-0-python",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://api.app.kognic.com/v2/requests\"\n\npayload = json.dumps({\n   \"externalId\": \"\",\n   \"projectId\": \"\",\n   \"template\": {\n      \"requestId\": \"\",\n      \"type\": \"\"\n   },\n   \"title\": \"\"\n})\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "example-0-python"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-201",
          "language": "201",
          "code": "{\n  \"data\": {\n    \"createdAt\": \"\",\n    \"id\": \"\",\n    \"inputProgressCounts\": {\n      \"completed\": \"\",\n      \"inProgress\": \"\",\n      \"notStarted\": \"\",\n      \"total\": \"\"\n    },\n    \"projectId\": \"\",\n    \"title\": \"\"\n  }\n}"
        },
        {
          "id": "response-1-400",
          "language": "400",
          "code": "// Bad request\n{\n  \"errorCode\": \"\",\n  \"message\": \"\"\n}"
        },
        {
          "id": "response-2-401",
          "language": "401",
          "code": "// Unauthorized\n{\n  \"message\": \"\"\n}"
        },
        {
          "id": "response-3-404",
          "language": "404",
          "code": "// Not found\n{\n  \"message\": \"\"\n}"
        },
        {
          "id": "response-4-409",
          "language": "409",
          "code": "// Conflict\n{\n  \"message\": \"\"\n}"
        }
      ],
      "selectedLanguageId": "response-0-201"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}