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

# Get schedule by ID

> Returns a single schedule by identifier.



## OpenAPI

````yaml https://raw.githubusercontent.com/InsForge/InsForge/main/openapi/schedules.yaml get /api/schedules/{id}
openapi: 3.0.3
info:
  title: Insforge Schedules API
  version: 1.0.0
  description: Schedule management endpoints
servers: []
security: []
paths:
  /api/schedules/{id}:
    get:
      tags:
        - Admin
      summary: Get schedule by ID
      description: Returns a single schedule by identifier.
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Schedule found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Schedule'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Schedule not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    Schedule:
      type: object
      required:
        - id
        - name
        - cronSchedule
        - functionUrl
        - httpMethod
        - isActive
        - createdAt
        - updatedAt
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
        cronSchedule:
          type: string
        functionUrl:
          type: string
          format: uri
        httpMethod:
          type: string
          enum:
            - GET
            - POST
            - PUT
            - PATCH
            - DELETE
        headers:
          type: object
          nullable: true
          additionalProperties:
            type: string
        body:
          nullable: true
          oneOf:
            - type: string
            - type: object
        cronJobId:
          type: string
          nullable: true
        lastExecutedAt:
          type: string
          format: date-time
          nullable: true
        isActive:
          type: boolean
        nextRun:
          type: string
          format: date-time
          nullable: true
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
    ErrorResponse:
      type: object
      required:
        - error
        - message
        - statusCode
      properties:
        error:
          type: string
        message:
          type: string
        statusCode:
          type: integer
        nextActions:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````