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

# Update a scheduler by reference

> Update fields of an existing scheduler configuration by its reference.



## OpenAPI

````yaml https://api-trial.cognigy.ai/testing/openapi/openapi-viewer.json patch /simulations/{simulationReference}/schedules/{schedulerReference}
openapi: 3.0.0
info:
  title: SIMULATOR OPENAPI REST-ful-API Reference
  version: 2025.20.0
  description: >

    ### Introduction

    This is the [OpenAPI 3.0](https://swagger.io/specification/) documentation

    of the
    [REST](https://en.wikipedia.org/wiki/Representational_state_transfer)-ful
    SIMULATOR OPENAPI API.


    ### Cross-Origin Resource Sharing

    This API features Cross-Origin Resource Sharing (CORS) implemented in

    compliance with [W3C spec](https://www.w3.org/TR/cors/), which allows

    cross-domain communication from the browser. All responses have a wildcard

    same-origin header which makes the API completely accessible.


    ### Authentication

    SIMULATOR OPENAPI offers following forms of authentication:

    - Bearer Token (JWT)

    - API Key


    ### Error Handling

    This API uses HTTP status codes equal or above 400 to indicate errors. Error

    details are generated in compliance with [RFC 7807 - "Problem Details for
    HTTP APIs"](https://tools.ietf.org/html/rfc7807).


    Every error response contains a traceId, which should be provided to the
    SIMULATOR OPENAPI Technical Support when reporting an error.
  contact:
    name: Cognigy Technical Support
    url: https://www.cognigy.com
    email: support@cognigy.com
  license:
    name: Cognigy Proprietary License
servers:
  - url: https://api-trial.cognigy.ai/testing
    description: Cognigy Service Testing API
security:
  - bearerAuth: []
  - apiKeyAuth: []
tags:
  - name: Simulations
    description: >-
      Simulation management operations - Create, read, update, and delete
      simulations
externalDocs:
  description: SIMULATOR OPENAPI Documentation
  url: https://docs.cognigy.com/docs/service-testing/
paths:
  /simulations/{simulationReference}/schedules/{schedulerReference}:
    patch:
      tags:
        - Simulations
      summary: Update a scheduler by reference
      description: Update fields of an existing scheduler configuration by its reference.
      operationId: updateScheduler
      parameters:
        - name: projectId
          in: query
          required: true
          schema:
            type: string
          description: Project identifier
        - in: path
          name: simulationReference
          required: true
          schema:
            type: string
          description: Reference ID of the simulation (unused for update but part of path)
        - in: path
          name: schedulerReference
          required: true
          schema:
            type: string
          description: Reference ID of the scheduler to update
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: Any subset of fields to update
              properties:
                runConfig:
                  type: object
                  properties:
                    flowReferenceId:
                      type: string
                    localeReferenceId:
                      type: string
                    entrypoint:
                      type: string
                    largeLanguageModelReferenceId:
                      type: string
                    userId:
                      type: string
                    finalPing:
                      type: number
                    data:
                      type: object
                      additionalProperties: true
                    enableMocking:
                      type: boolean
                enableSchedule:
                  type: boolean
                frequency:
                  type: string
                  enum:
                    - daily
                    - every three days
                    - weekly
                    - biweekly
                    - monthly
                time:
                  type: string
                  format: date-time
                numberOfRuns:
                  type: integer
                nextScheduledRun:
                  type: string
                  format: date-time
                emailNotifications:
                  type: array
                  items:
                    type: string
                scenarioName:
                  type: string
                runName:
                  type: string
                simulationReference:
                  type: string
                endDate:
                  type: string
                  format: date-time
      responses:
        '200':
          description: Scheduler updated successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  scheduler:
                    type: object
                    properties:
                      id:
                        type: string
                      simulationReference:
                        type: string
                      projectReference:
                        type: string
                      organisationReference:
                        type: string
                      runConfig:
                        type: object
                        properties:
                          flowReferenceId:
                            type: string
                          localeReferenceId:
                            type: string
                          entrypoint:
                            type: string
                          largeLanguageModelReferenceId:
                            type: string
                          userId:
                            type: string
                          finalPing:
                            type: number
                          data:
                            type: object
                            additionalProperties: true
                          enableMocking:
                            type: boolean
                      enableSchedule:
                        type: boolean
                      frequency:
                        type: string
                        enum:
                          - daily
                          - every three days
                          - weekly
                          - biweekly
                          - monthly
                      time:
                        type: string
                        format: date-time
                      numberOfRuns:
                        type: integer
                      nextScheduledRun:
                        type: string
                        format: date-time
                      emailNotifications:
                        type: array
                        items:
                          type: string
                      scenarioName:
                        type: string
                      runName:
                        type: string
                      endDate:
                        type: string
                        format: date-time
                      createdAt:
                        type: integer
                        format: int64
                      lastChanged:
                        type: integer
                        format: int64
                      createdBy:
                        type: string
                      lastChangedBy:
                        type: string
                      cronScheduler:
                        type: string
                      timezone:
                        type: string
                        description: >-
                          IANA timezone used for scheduler recurrence
                          calculations. Derived by the server from the project
                          timezone settings and persisted on the scheduler. Not
                          set directly in scheduler create/update requests.
                        example: Europe/Berlin
        '400':
          description: Bad Request - Invalid input parameters
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  field:
                    type: string
                  code:
                    type: string
                  traceId:
                    type: string
                required:
                  - error
                  - field
        '401':
          description: Unauthorized - Invalid or missing authentication
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  code:
                    type: string
                  traceId:
                    type: string
                required:
                  - error
        '403':
          description: Forbidden - Insufficient permissions
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  code:
                    type: string
                  traceId:
                    type: string
                required:
                  - error
        '404':
          description: Not Found - Resource not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  code:
                    type: string
                  traceId:
                    type: string
                required:
                  - error
        '500':
          description: Internal Server Error - Server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  code:
                    type: string
                  traceId:
                    type: string
                required:
                  - error
      security:
        - bearerAuth: []
        - apiKeyAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT Bearer Token for authentication
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: API Key for authentication

````