v1
Double column
API
CLI
JS Client

Templates /

Run template

Run a template

Required permission

Account > Templates > General > Run

Path parameters

    • templateId

      string required

      ID of the template

Response body

  • {object}

    Response object.

    • data

      {object} required

      Result data.

      • id

        string required

        ID of the template run.

      • createdAt

        date required

        Timestamp of when the run was initiated.

      • updatedAt

        date required

        Timestamp of when the run was last updated.

      • template

        {object} required

        Details about the template being run.

        • id

          string required

          ID of the template

        • name

          string required

          The name of the template

      • status

        string required

        Status of the template run.

        one of
        waiting, failure, retrying, success, unknown
      • content

        {object} required

        Details about the template run.

        • name

          string required

          Name of the template.

          min length
          3
          max length
          20
          pattern
          ^[a-zA-Z]((-|\s)?[a-zA-Z0-9]+((-|\s)[a-zA-Z0-9]+)*)?$
        • description

          string

          Description of the template.

          max length
          200
          pattern
          ^[a-zA-Z0-9.,?\s\\/'"()[\];`%^&*\-_:!]+$
        • apiVersion

          string required

          The version of the Northflank API to run the template against.

          one of
          v1
        • project

          required
        • spec

          required
API
CLI
JS Client

POST /v1/templates/{templateId}/runs

Example response

200 OK

Details about the newly create template run.

JSON

{
  "data": {
    "id": "501c1e03-a021-4659-9048-85f8f6ee2bc7",
    "createdAt": "2022-06-14 15:10:42.842Z",
    "updatedAt": "2022-06-14 15:10:42.842Z",
    "template": {
      "id": "example-template",
      "name": "Example Template"
    },
    "status": "success",
    "content": {
      "name": "Example Template",
      "description": "This is a sample template.",
      "apiVersion": "v1"
    }
  }
}

© 2022 Northflank Ltd. All rights reserved.