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

# Create the client's wallet

> Generates MPC shares for both SECP256K1 (EVM, Bitcoin, etc.) and ED25519
(Solana, XRP, etc.) curves (a Portal wallet).

After storing the MPC shares from this endpoint, confirm storage with the
Client API's update signing share pairs statuses endpoint before attempting
to sign.




## OpenAPI

````yaml /openapi/enclave-mpc-api.yaml post /v1/generate
openapi: 3.1.0
info:
  title: Portal Enclave MPC API
  version: '1.0'
  description: |
    The Enclave MPC API provides endpoints for MPC wallet generation, signing,
    backup, and recovery. All endpoints require a Client API Key or Client
    Session Token as a Bearer token.

    ## Base URL
    `https://mpc-client.portalhq.io`
servers:
  - url: https://mpc-client.portalhq.io
security:
  - bearerAuth: []
tags:
  - name: MPC Operations
    description: MPC wallet generation, signing, asset transfers, backup, and recovery
paths:
  /v1/generate:
    post:
      tags:
        - MPC Operations
      summary: Create the client's wallet
      description: >
        Generates MPC shares for both SECP256K1 (EVM, Bitcoin, etc.) and ED25519

        (Solana, XRP, etc.) curves (a Portal wallet).


        After storing the MPC shares from this endpoint, confirm storage with
        the

        Client API's update signing share pairs statuses endpoint before
        attempting

        to sign.
      operationId: generate
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: Empty object. No parameters required.
            example: {}
      responses:
        '200':
          description: Wallet created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MpcShareResponse'
              example:
                SECP256K1:
                  share: eyJjbG...
                  id: cm0r6nkek00ej10dwwx8wdjmf
                ED25519:
                  share: eyJjbG...
                  id: cm0r6nk7c00hbzefaq9s93s0x
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MpcErrorResponse'
              example:
                id: DKG_FAILED
                message: Some message
        '401':
          description: Unauthorized
          content:
            text/plain:
              schema:
                type: string
              example: Incorrect API key format
components:
  schemas:
    MpcShareResponse:
      type: object
      description: MPC shares for both supported curves.
      properties:
        SECP256K1:
          $ref: '#/components/schemas/MpcShare'
        ED25519:
          $ref: '#/components/schemas/MpcShare'
      required:
        - SECP256K1
        - ED25519
    MpcErrorResponse:
      type: object
      description: Standard error response from the Enclave MPC API.
      properties:
        id:
          type: string
          description: >-
            Short error identifier (e.g. `DKG_FAILED`, `BAD_REQUEST`,
            `RPC_OP_FAILED`).
        message:
          type: string
          description: Human-readable error details.
      required:
        - id
    MpcShare:
      type: object
      description: An MPC share for a single curve.
      properties:
        share:
          type: string
          description: The MPC share data (base64-encoded).
        id:
          type: string
          description: Unique identifier for this share.
      required:
        - share
        - id
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Client API Key or Client Session Token

````