> ## Documentation Index
> Fetch the complete documentation index at: https://docs.staging.questra.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Set or skip programming fine-tuning template

> Persists the fine-tuning template on the programming target (`null` clears it and uses the code-owned canonical platform template) and, when programming is waiting on Configure template selection, resumes that wait. Call during Configure before Compile starts.



## OpenAPI

````yaml /openapi/program.openapi.json put /surveys/{surveyId}/programming/template
openapi: 3.1.0
info:
  title: Questra Program API
  version: 0.0.1
  description: >-
    REST API for the Questra Program product. Browser users authenticate through
    Questra Auth SSO; automation uses workspace-scoped API keys (`Authorization:
    Bearer qpk_live_…`). API keys carry scopes enforced before handlers.
    Outbound webhooks follow Standard Webhooks (at-least-once delivery;
    consumers must be idempotent).
servers:
  - url: /v1
    description: Program API base path
security: []
paths:
  /surveys/{surveyId}/programming/template:
    put:
      tags:
        - Survey programming
      summary: Set or skip programming fine-tuning template
      description: >-
        Persists the fine-tuning template on the programming target (`null`
        clears it and uses the code-owned canonical platform template) and, when
        programming is waiting on Configure template selection, resumes that
        wait. Call during Configure before Compile starts.
      parameters:
        - schema:
            type: string
            format: uuid
          required: true
          name: surveyId
          in: path
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PutProgrammingTemplateRequest'
      responses:
        '200':
          description: Programming target
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProgrammingTargetResponse'
        '400':
          description: Programming target not set or platform mismatch
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
components:
  schemas:
    PutProgrammingTemplateRequest:
      type: object
      properties:
        fine_tuning_template_id:
          type:
            - string
            - 'null'
          format: uuid
          description: >-
            Fine-tuning template to apply, or `null` to skip and use Questra
            defaults.
      required:
        - fine_tuning_template_id
    ProgrammingTargetResponse:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/ProgrammingTarget'
      required:
        - data
    ErrorBody:
      type: object
      properties:
        error:
          type: string
        message:
          type: string
        resource:
          type: string
        slug:
          type: string
        file_id:
          type: string
        endpoint_id:
          type: string
        event_id:
          type: string
        delivery_id:
          type: string
        api_key_id:
          type: string
        integration_id:
          type: string
        audit_id:
          type: string
        status:
          type: string
        details: {}
        question_ids:
          type: array
          items:
            type: string
        survey_ids:
          type: array
          items:
            type: string
        revisions:
          type: array
          items:
            type: number
      required:
        - error
    ProgrammingTarget:
      type:
        - object
        - 'null'
      properties:
        survey_id:
          type: string
          format: uuid
        platform:
          $ref: '#/components/schemas/ProgrammingPlatform'
        instructions:
          type:
            - string
            - 'null'
        fine_tuning_template_id:
          type:
            - string
            - 'null'
          format: uuid
          description: >-
            Fine-tuning template applied to this survey, or null when none is
            chosen.
        config:
          type: object
          additionalProperties: {}
        initial_push_succeeded:
          type: boolean
          description: >-
            Whether Program has landed its own survey configuration upstream at
            least once.
        updated_at:
          type: string
          format: date-time
      required:
        - survey_id
        - platform
        - instructions
        - fine_tuning_template_id
        - config
        - initial_push_succeeded
        - updated_at
    ProgrammingPlatform:
      type: string
      enum:
        - questra
        - decipher
        - confirmit
        - qualtrics
        - alchemer

````