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

# Export destination credential

> Writes the write-only credential of your bucket straight into the cell vault.



## OpenAPI

````yaml openapi/en/cell.json PUT /v1/exports/destinations/{schedule_id}/credential
openapi: 3.1.0
info:
  title: Niadra data API
  version: '1'
  description: >-
    Writing, context, history, objects, identity, privacy and governance of one
    space. Every space has a stable address, with the space and the region in
    its name.
servers:
  - url: https://{space}.{region}.api.niadra.com
    variables:
      space:
        default: acme-prod
        description: The space, which comes in the source key.
      region:
        default: us-east-1
        description: The region of the space, which also comes in the key.
security: []
paths:
  /v1/exports/destinations/{schedule_id}/credential:
    put:
      tags:
        - governance
      summary: Export destination credential
      description: >-
        Writes the write-only credential of your export destination (S3, GCS or
        Azure Blob) straight into the vault of the cell. The value is never
        returned and never reaches the control plane; the answer only says which
        version is now in use.


        **Authentication.** Console person token with the `security` role (or
        admin), or a source key with the `admin` scope.
      operationId: >-
        put_destination_credential_v1_exports_destinations__schedule_id__credential_put
      parameters:
        - in: path
          name: schedule_id
          required: true
          schema:
            title: Schedule Id
            type: string
          description: >-
            The export schedule, as named in the `export-schedules`
            configuration.
          example: datalake-hourly
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SecretIn'
            example:
              value: >-
                {"role_arn":
                "arn:aws:iam::111122223333:role/niadra-export-writer"}
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SecretWritten'
              example:
                version: 2
          description: Stored. `version` is the credential version now in use.
        '422':
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/Problem'
          description: The request does not match the contract.
      security:
        - sourceKey: []
        - personToken: []
components:
  schemas:
    SecretIn:
      additionalProperties: false
      description: 'Write-only: the value goes to the cell vault and is never returned.'
      properties:
        value:
          maxLength: 8192
          minLength: 1
          title: Value
          type: string
      required:
        - value
      title: SecretIn
      type: object
    SecretWritten:
      additionalProperties: false
      properties:
        version:
          title: Version
          type: integer
      required:
        - version
      title: SecretWritten
      type: object
    Problem:
      additionalProperties: false
      description: RFC 9457 problem details; `code` comes from the versioned error catalog.
      properties:
        code:
          title: Code
          type: string
        detail:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Detail
        request_id:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Request Id
        status:
          title: Status
          type: integer
        title:
          title: Title
          type: string
        type:
          default: about:blank
          title: Type
          type: string
      required:
        - title
        - status
        - code
      title: Problem
      type: object
  securitySchemes:
    sourceKey:
      type: http
      scheme: bearer
      description: nia_sk_...
    personToken:
      type: http
      scheme: bearer
      bearerFormat: JWT

````