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

# Create a new secret

> Create a new secret. Secret values are encrypted and stored securely.



## OpenAPI

````yaml /openapi.json put /secrets
openapi: 3.0.4
info:
  title: Nexrender API
  version: '2.0'
  description: >
    REST API for the Nexrender cloud rendering platform, enabling programmatic
    control over After Effects template processing, job management, and asset
    handling.


    Features include:


    - Template upload and management (AEP, MOGRT, ZIP files)

    - Job creation and status monitoring with real-time progress

    - Job nesting for multi-composition renders (parent/child jobs)

    - Job stitching to combine multiple videos into one

    - Batch job creation for submitting up to 1000 jobs at once

    - Font library management for typography consistency

    - Secret management for secure API key storage

    - Webhook notifications for job lifecycle events

    - Asset injection for dynamic content replacement


    Authentication is required for all endpoints using Bearer token
    authorization.
servers:
  - url: https://api.nexrender.com/api/v2
    description: Production API server
security:
  - apiToken: []
paths:
  /secrets:
    put:
      tags:
        - Secret Management
      summary: Create a new secret
      description: Create a new secret. Secret values are encrypted and stored securely.
      operationId: createOrUpdateSecret
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SecretCreation'
      responses:
        '201':
          description: Secret successfully created
        '400':
          description: Invalid request - missing required fields or invalid secret data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
        '401':
          description: Unauthorized - invalid or missing API token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '409':
          description: Conflict - secret with this name already exists
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    SecretCreation:
      type: object
      description: Configuration for creating a secret
      properties:
        name:
          type: string
          description: Secret name/key for identification and reference
        value:
          type: string
          description: Secret value to store securely (will be encrypted)
      required:
        - name
        - value
    ValidationErrorResponse:
      type: object
      description: Validation error response with detailed field information
      properties:
        error:
          type: string
          description: Main error message
        details:
          type: array
          description: Array of specific validation errors for individual fields
          items:
            type: object
            properties:
              field:
                type: string
                description: Field name that failed validation
              message:
                type: string
                description: Specific validation error for this field
    ErrorResponse:
      type: object
      description: Standard error response format
      properties:
        error:
          type: string
          description: Human-readable error message explaining what went wrong
      required:
        - error
  securitySchemes:
    apiToken:
      type: http
      scheme: bearer
      description: >
        Bearer token authentication using API tokens for team-based access
        control.


        You can generate your own API token at:
        https://app.nexrender.com/settings/api-tokens

````