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

# Activate a closed-launch access code



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/access/activate
openapi: 3.1.0
info:
  title: ekiden-gateway
  description: >-
    API Gateway and WebSocket proxy based on Axum and Utoipa, handling auth,
    rate limiting, and connection buffering.
  license:
    name: ''
  version: 0.1.1
servers:
  - url: https://api.ekiden.fi/
    description: Production
  - url: https://api.cnt.ekiden.fi/
    description: Testnet
  - url: https://api.canton.ekiden.fi/
    description: Staging
security: []
paths:
  /api/v1/access/activate:
    post:
      tags:
        - Access
      summary: Activate a closed-launch access code
      operationId: activate
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AccessActivateRequest'
        required: true
      responses:
        '200':
          description: Wallet activated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccessActivateResponse'
        '400':
          description: Invalid, expired, or revoked code
        '401':
          description: Bad or stale signature
        '404':
          description: Access module disabled
        '409':
          description: Code already used or wallet already activated
        '429':
          description: Rate limited
components:
  schemas:
    AccessActivateRequest:
      type: object
      description: >-
        Public Stage 1 activation request (spec §4). The caller is NOT yet

        whitelisted. The wallet signs a canonical message that binds the code
        hash,

        its root address, and `signed_at`:

        `ekiden-stage1-activate:{sha256(normalized
        code)}:{root_address}:{signed_at}`

        using the same wallet-signature scheme JWT login uses. The root address
        is

        derived from `public_key` (never trusted from the client), exactly as

        `/authorize` does.
      required:
        - code
        - public_key
        - signed_at
        - signature
      properties:
        code:
          type: string
          description: |-
            Plaintext access code. Normalized (trim + uppercase) and hashed
            server-side; the plaintext is never persisted (S1-D5).
        nonce:
          type:
            - string
            - 'null'
          description: >-
            Replay nonce bound into the Canton activation message. REQUIRED on
            the

            Canton rail, ignored on Aptos.
        party_id:
          type:
            - string
            - 'null'
          description: >-
            Canton party id (`<hint>::<fingerprint>`). REQUIRED on the Canton
            rail,

            ignored on Aptos.


            Canton has no address derivable from the public key alone, so the
            wallet

            signs for its party and the server derives the root from that party
            —

            the same identity `/authorize` uses. The party's `::<fingerprint>`
            suffix

            commits to the public key, so a caller cannot claim someone else's
            party.
        public_key:
          type: string
          description: Wallet public key, same encoding as `/authorize`'s `public_key`.
        signature:
          type: string
          description: Wallet signature over the canonical activation message.
        signed_at:
          type: integer
          format: int64
          description: |-
            Unix seconds at which the message was signed. Must be within the
            configured signature window of server time.
    AccessActivateResponse:
      type: object
      required:
        - activated
        - multiplier_bps
        - badge
      properties:
        activated:
          type: boolean
        badge:
          type: boolean
        multiplier_bps:
          type: integer
          format: int32
          minimum: 0

````