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

# Rename Org Variable

> Rename a variable for a specific org.



## OpenAPI

````yaml https://api.useinvent.com/openapi.json patch /orgs/{org_id}/variables/{key}
openapi: 3.1.0
info:
  version: 1.0.0
  title: Invent API
servers:
  - url: https://api.useinvent.com
security:
  - bearerAuth: []
paths:
  /orgs/{org_id}/variables/{key}:
    patch:
      tags:
        - Orgs Variables
      summary: Rename Org Variable
      description: Rename a variable for a specific org.
      parameters:
        - schema:
            type: string
          required: true
          description: The ID of the org
          name: org_id
          in: path
        - schema:
            type: string
          required: true
          description: The key of the variable to rename.
          name: key
          in: path
      requestBody:
        description: The new variable information.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateOrgVariableSchema'
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/UpdateOrgVariableSchema'
      responses:
        '200':
          description: The updated org variables.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrgVariableSchema'
components:
  schemas:
    UpdateOrgVariableSchema:
      type: object
      properties:
        key:
          type: string
          maxLength: 128
          pattern: ^[a-zA-Z_][a-zA-Z_0-9]*$
          description: The key of the org variable
        value:
          type: string
          maxLength: 2048
          description: The value of the org variable
        secret:
          type: boolean
          description: Indicates if the variable is a secret
          example: true
      description: Detailed information about a variable in your org
    OrgVariableSchema:
      type: object
      properties:
        key:
          type: string
          maxLength: 128
          pattern: ^[a-zA-Z_][a-zA-Z_0-9]*$
          description: The key of the org variable
        value:
          type: string
          maxLength: 2048
          description: The value of the org variable
        secret:
          type: boolean
          description: Indicates if the variable is a secret
          example: true
      required:
        - key
      description: Detailed information about a variable in your org
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: Bearer token authentication using your API key

````