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

# Allocations List

> Returns a list of allocations for a given wallet



## OpenAPI

````yaml /apis/portal/openapi.json get /api/{portalId}/allocations
openapi: 3.0.2
info:
  title: Magna Portal API
  version: 1.0.0
servers: []
security: []
tags:
  - name: Auth
    description: Authentication related endpoints
  - name: Token
    description: Token claiming
  - name: Config
    description: Portal configuration
  - name: Misc
    description: Miscellaneous operational endpoints
  - name: Staking
    description: Staking pool operations
  - name: Compliance
    description: Wallet compliance operations
paths:
  /api/{portalId}/allocations:
    get:
      tags:
        - Token
      summary: Allocations List
      description: Returns a list of allocations for a given wallet
      parameters:
        - name: portalId
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: unique portal id (provided by Magna)
        - name: cursor
          in: header
          schema:
            type: number
            nullable: true
            description: >-
              cursor for pagination; not required for the first page; for
              subsequent pages, use the cursor from the previous response
              (x-cursor response header)
        - name: wallet
          in: query
          description: wallet address to get allocations for
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Ok
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                      format: uuid
                      description: unique allocation id
                    claimed:
                      type: string
                      description: number of tokens claimed (received by the stakeholder)
                    vested:
                      type: string
                      description: number of tokens vested (available to the stakeholder)
                    total:
                      type: string
                      description: total number of tokens allocated to the stakeholder
                    category:
                      type: string
                      description: category of the allocation
                    timestamps:
                      type: array
                      items:
                        type: object
                        properties:
                          timestamp:
                            type: number
                            description: timestamp of the unlock
                          amount:
                            type: string
                            description: amount of tokens unlocked at the timestamp
                        required:
                          - timestamp
                          - amount
                      description: unlock timestamps for the allocation
                    createdAt:
                      type: string
                      description: allocation creation timestamp
                    description:
                      type: string
                      nullable: true
                      description: description of the allocation
                    isOffChainClaim:
                      type: boolean
                      description: whether the allocation is off-chain
                    isWalletSubmitted:
                      type: boolean
                      nullable: true
                      description: is wallet submitted for allocation
                    submittedWallet:
                      type: string
                      nullable: true
                      description: submitted wallet for allocation
                  required:
                    - id
                    - claimed
                    - vested
                    - total
                    - category
                    - timestamps
                    - createdAt
                    - description
                    - isOffChainClaim
                    - isWalletSubmitted
                    - submittedWallet
                description: Ok
                title: Allocations List
              examples:
                claim:
                  summary: Claim
                  value:
                    id: 49744a32-4549-484b-b6d3-2a14dbfccd07
                    claimed: 200
                    vested: 600
                    total: 1000
                    category: Community
                    timestamps:
                      - timestamp: 1706738400
                        amount: 200
                      - timestamp: 1709244000
                        amount: 200
                      - timestamp: 1711918800
                        amount: 200
                      - timestamp: 1714510800
                        amount: 200
                      - timestamp: 1717189200
                        amount: 200
                    createdAt: '2024-05-15T00:00:00.000Z'
                    description: Allocation based on community contributions
        '400':
          description: Client Error
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    properties:
                      errors:
                        type: array
                        items:
                          type: object
                          properties:
                            path:
                              type: string
                            message:
                              type: string
                          required:
                            - path
                            - message
                    required:
                      - errors
                  - type: object
                    properties:
                      error:
                        oneOf:
                          - type: string
                            enum:
                              - DISTRIBUTION_NOT_FOUND
                              - HUMANITY_CHECK_INCOMPLETE
                              - DISTRIBUTION_NOT_STARTED
                              - STAKING_POOL_NOT_FOUND
                              - STAKE_NOT_FOUND
                          - type: string
                    required:
                      - error
                description: Client Error
                example:
                  errors:
                    - path: query.wallet
                      message: Required
        '500':
          description: Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: error message
                required:
                  - error
                description: Server Error
                example:
                  error: internal server error

````