> ## Documentation Index
> Fetch the complete documentation index at: https://help.statisfy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a flow from a template, off

> Saves a copy of the template as a new flow of yours with the name you give, turned off, in `folder` (by name) or Agent Studio's default folder, as the app's "Start With A Template" does. The template is unchanged. Read the new flow with GET /v1/automations/flows/{flow_id}/spec to change it; turning it on is as for any flow. Templates are the ready-made flows Agent Studio offers when you start a new flow (its "Start With A Template" dialog). They are Statisfy's, the same in every workspace.



## OpenAPI

````yaml /api/statisfy-api.openapi.json post /v1/automations/templates/{template_id}/flows
openapi: 3.1.0
info:
  description: >-
    The agent-first Statisfy API. Authenticate with an API key (`Authorization:
    Bearer stfy_live_…`), then call `GET /v1/meta/capabilities` to discover
    every operation and its schemas.
  title: Statisfy API
  version: 1.0.0
servers:
  - url: https://api.statisfy.com
    description: Production
security: []
paths:
  /v1/automations/templates/{template_id}/flows:
    post:
      tags:
        - automations
      summary: Create a flow from a template, off
      description: >-
        Saves a copy of the template as a new flow of yours with the name you
        give, turned off, in `folder` (by name) or Agent Studio's default
        folder, as the app's "Start With A Template" does. The template is
        unchanged. Read the new flow with GET
        /v1/automations/flows/{flow_id}/spec to change it; turning it on is as
        for any flow. Templates are the ready-made flows Agent Studio offers
        when you start a new flow (its "Start With A Template" dialog). They are
        Statisfy's, the same in every workspace.
      operationId: automations_create_flow_from_template
      parameters:
        - description: The template's id, from GET /v1/automations/templates
          in: path
          name: template_id
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: false
              properties:
                folder:
                  anyOf:
                    - maxLength: 255
                      minLength: 1
                      type: string
                    - type: 'null'
                  default: null
                  description: >-
                    The Agent Studio folder to put it in, by name (as GET
                    /v1/automations/flows' `folder` filter); default: the
                    editor's default folder
                  title: Folder
                name:
                  description: 'The new flow''s name; one of your flows already has it: 409'
                  maxLength: 200
                  minLength: 1
                  title: Name
                  type: string
              required:
                - name
              type: object
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SavedFlowSpec'
          description: Successful Response
      security:
        - HTTPBearer: []
components:
  schemas:
    SavedFlowSpec:
      properties:
        editor_url:
          description: The flow in Agent Studio
          title: Editor Url
          type: string
        enabled:
          title: Enabled
          type: boolean
        flow_id:
          title: Flow Id
          type: string
        name:
          title: Name
          type: string
        nodes:
          additionalProperties:
            type: string
          description: step id -> node id in the editor
          title: Nodes
          type: object
        trigger:
          description: The audience in words
          title: Trigger
          type: string
        version:
          title: Version
          type: integer
      required:
        - flow_id
        - name
        - version
        - enabled
        - trigger
        - editor_url
      title: SavedFlowSpec
      type: object
  securitySchemes:
    HTTPBearer:
      scheme: bearer
      type: http
      description: >-
        An API key, sent as `Authorization: Bearer stfy_live_…`. See
        [Authentication](/rest-api/authentication) for how to get one and which
        scopes it needs.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.