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

# Create a WordPress site token

> Create a site-scoped WordPress token. Use `storageAccess=none` when the site should optimize media without Convertly Storage, or `isolated` when the site needs its own storage scope.



## OpenAPI

````yaml /openapi.json post /api/wordpress-instances
openapi: 3.1.0
info:
  title: Convertly API
  version: 1.0.0
  description: >-
    Convertly provides production API endpoints for media conversion,
    compression, Image CDN delivery, Forma AI, HLS/DASH video streaming, media
    tools, async jobs, workflows, webhooks, and Convertly Storage.
  license:
    name: Proprietary
    url: https://convertly.sh/terms
servers:
  - url: https://convertly.sh
security:
  - bearerAuth: []
  - apiKeyAuth: []
paths:
  /api/wordpress-instances:
    post:
      tags:
        - WordPress
      summary: Create a WordPress site token
      description: >-
        Create a site-scoped WordPress token. Use `storageAccess=none` when the
        site should optimize media without Convertly Storage, or `isolated` when
        the site needs its own storage scope.
      operationId: createWordPressInstance
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateWordPressInstanceRequest'
      responses:
        '200':
          description: Created WordPress site token. The token is returned once.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateWordPressInstanceResponse'
        '400':
          $ref: '#/components/responses/Error'
        '401':
          $ref: '#/components/responses/Error'
        '500':
          $ref: '#/components/responses/Error'
components:
  schemas:
    CreateWordPressInstanceRequest:
      type: object
      properties:
        name:
          type: string
          minLength: 1
          maxLength: 80
          description: Client or WordPress site name. Trimmed before validation.
        siteUrl:
          type: string
          format: uri
          maxLength: 300
          description: >-
            Optional WordPress site URL. Trimmed before validation; blank input
            is stored as no URL.
        storageAccess:
          allOf:
            - $ref: '#/components/schemas/WordPressStorageAccess'
          default: isolated
      required:
        - name
    CreateWordPressInstanceResponse:
      type: object
      properties:
        instance:
          $ref: '#/components/schemas/WordPressInstance'
        token:
          type: string
          description: >-
            The WordPress site token. It is returned only once when the site is
            created.
      required:
        - instance
        - token
    WordPressStorageAccess:
      type: string
      enum:
        - none
        - isolated
      description: >-
        `none` disables Convertly Storage for the site token. `isolated` gives
        the site its own storage scope.
    WordPressInstance:
      type: object
      properties:
        id:
          type: string
          format: uuid
        name:
          type: string
        site_url:
          type:
            - string
            - 'null'
          format: uri
        storage_access:
          $ref: '#/components/schemas/WordPressStorageAccess'
        api_key_id:
          type:
            - string
            - 'null'
          format: uuid
        created_at:
          type: string
          format: date-time
        api_keys:
          type:
            - object
            - 'null'
          properties:
            key_prefix:
              type: string
            last_used_at:
              type:
                - string
                - 'null'
              format: date-time
      required:
        - id
        - name
        - storage_access
        - created_at
    Error:
      type: object
      properties:
        error:
          type: string
        upgradeUrl:
          type: string
      required:
        - error
  responses:
    Error:
      description: Error response
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Dashboard-generated Convertly API key. Keys currently begin with
        `cvly_`.
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: Alternative API key header for server-side clients.

````