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

# Update App Variables

> Update variables for a specific app.



## OpenAPI

````yaml patch /apps/{app_id}/variables
openapi: 3.0.0
info:
  version: 1.0.0
  title: API
servers: []
security: []
paths:
  /apps/{app_id}/variables:
    patch:
      summary: Update App Variables
      description: Update variables for a specific app.
      parameters:
        - schema:
            type: string
          required: true
          description: The ID of the app
          name: app_id
          in: path
        - schema:
            type: number
          required: false
          description: Page number
          name: page
          in: query
        - schema:
            type: number
          required: false
          description: Number of items to take
          name: take
          in: query
        - schema:
            type: string
          required: false
          description: Next page token (Only used on special endpoints)
          name: next
          in: query
      requestBody:
        description: An array of app variables to update.
        content:
          application/json:
            schema:
              type: array
              items:
                $ref: '#/components/schemas/AppVariableSchema'
          multipart/form-data:
            schema:
              type: array
              items:
                $ref: '#/components/schemas/AppVariableSchema'
      responses:
        '200':
          description: An array of updated app variables.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/AppVariableSchema'
components:
  schemas:
    AppVariableSchema:
      type: object
      properties:
        key:
          type: string
          maxLength: 128
          pattern: ^[a-zA-Z_][a-zA-Z_0-9]*$
          description: The key of the app variable
        value:
          type: string
          maxLength: 2048
          description: The value of the app variable
        secret:
          type: boolean
          description: Indicates if the variable is a secret
          example: true
      required:
        - key
      description: Detailed information about a variable in your app

````