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

# config/publish

> Publish a draft configuration as the live config. Requires the `configuration:write` permission.



## OpenAPI

````yaml https://provisioning.cloudx.io/api/v1/openapi.yaml post /config/publish
openapi: 3.0.3
info:
  title: CloudX API
  description: >-
    Use the CloudX API to retrieve reporting metrics, inspect auctions, and read
    account configuration.
  version: 1.0.0
servers:
  - url: https://provisioning.cloudx.io/api/v1
security: []
tags:
  - name: Authentication
    description: Validate CloudX API keys and inspect authenticated account details.
  - name: Reporting
    description: >-
      Retrieve CloudX reporting metrics for apps, ad units, bidders, and
      exports.
  - name: Configuration
    description: Read live, draft, and published CloudX account configuration.
  - name: Auction Inspection
    description: Inspect auctions, rounds, bids, and related delivery details.
paths:
  /config/publish:
    post:
      tags:
        - Configuration
      summary: config/publish
      description: >-
        Publish a draft configuration as the live config. Requires the
        `configuration:write` permission. The draft is validated with the same
        publish-time checks used by the CloudX app before it becomes live.
      operationId: postConfigPublish
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ConfigPublishRequest'
      responses:
        '200':
          description: Published config now serving as live.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConfigPublishResponse'
        '400':
          description: Invalid request or blocking config validation failure.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Forbidden.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Draft config 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:
    ConfigPublishRequest:
      type: object
      required:
        - draft_id
      properties:
        draft_id:
          type: string
          description: Draft config row ID to publish as live.
        version_label:
          type: string
          description: Optional label for the published config version.
    ConfigPublishResponse:
      type: object
      required:
        - config_id
        - version_number
        - validation
      properties:
        config_id:
          type: string
          description: Published config row ID that is now live.
        version_number:
          type: integer
          format: int32
          description: Account-local published config version number.
        validation:
          $ref: '#/components/schemas/ConfigValidationResponse'
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
    ConfigValidationResponse:
      type: object
      required:
        - valid
        - error_count
        - warning_count
        - issues
        - yaml
      properties:
        valid:
          type: boolean
        error_count:
          type: integer
          format: int32
        warning_count:
          type: integer
          format: int32
        issues:
          type: array
          items:
            $ref: '#/components/schemas/ConfigValidationIssue'
        yaml:
          type: string
        source:
          $ref: '#/components/schemas/ConfigValidationSource'
    ConfigValidationIssue:
      type: object
      required:
        - code
        - message
        - severity
      properties:
        code:
          type: string
        path:
          type: string
        message:
          type: string
        severity:
          type: string
          enum:
            - error
            - warning
        line:
          type: integer
          format: int32
        column:
          type: integer
          format: int32
        length:
          type: integer
          format: int32
    ConfigValidationSource:
      type: object
      properties:
        type:
          type: string
        name:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        Create or manage API keys in [CloudX
        Settings](https://app.cloudx.io/settings/api-keys).
      x-default: YOUR_CLOUDX_API_KEY

````