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

# Upload Ssh Key



## OpenAPI

````yaml https://api.primeintellect.ai/openapi.json post /api/v1/ssh_keys/
openapi: 3.1.0
info:
  title: PI API
  version: 0.1.0
servers:
  - url: https://api.primeintellect.ai
security: []
paths:
  /api/v1/ssh_keys/:
    post:
      tags:
        - SSH Keys
      summary: Upload Ssh Key
      operationId: upload_ssh_key_api_v1_ssh_keys__post
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/APISSHKeyUploadRequestConfig'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APISSHKeyConfig'
        '401':
          description: Authorization failed
        '422':
          description: Invalid request data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - HTTPBearer: []
components:
  schemas:
    APISSHKeyUploadRequestConfig:
      properties:
        name:
          type: string
          title: Name
          description: The name for the key.
        publicKey:
          type: string
          title: Publickey
          description: The public key part of the SSH key.
      type: object
      required:
        - name
        - publicKey
      title: APISSHKeyUploadRequestConfig
    APISSHKeyConfig:
      properties:
        id:
          type: string
          title: Id
          description: Unique identifier for the SSH key.
        userId:
          type: string
          title: Userid
          description: ID of the user associated with this pod, if applicable.
        name:
          type: string
          title: Name
          description: Name of the SSH key.
        publicKey:
          type: string
          title: Publickey
          description: The public key part of the SSH key.
        isPrimary:
          type: boolean
          title: Isprimary
          description: Whether this SSH key is the primary key.
        isUserKey:
          type: boolean
          title: Isuserkey
          description: Whether this a custom key uploaded by the user.
        createdAt:
          type: string
          format: date-time
          title: Createdat
          description: Timestamp when the SSH key was added.
        updatedAt:
          type: string
          format: date-time
          title: Updatedat
          description: Timestamp when the SSH key was last updated.
      type: object
      required:
        - id
        - userId
        - name
        - publicKey
        - isPrimary
        - isUserKey
      title: APISSHKeyConfig
    ErrorResponse:
      properties:
        errors:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
          title: Errors
      type: object
      required:
        - errors
      title: ErrorResponse
    ErrorDetail:
      properties:
        param:
          type: string
          title: Param
        details:
          type: string
          title: Details
      type: object
      required:
        - param
        - details
      title: ErrorDetail
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````