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

# Fetch Users

> Retrieve users linked to your project application. This `POST` endpoint allows querying by `email`, `id`, or `referenceId`. Use only one field; priority is given to `email`, then `referenceId`, and finally `id` in the MuFi database.



## OpenAPI

````yaml post /v1/users/fetch
openapi: 3.1.0
info:
  title: Wallet API
  version: 2.72.0
servers:
  - url: https://dev.api.mufi.app/
    description: Staging
security: []
paths:
  /v1/users/fetch:
    post:
      tags:
        - wallets
      summary: Fetch Users
      description: >-
        Retrieve users linked to your project application. This `POST` endpoint
        allows querying by `email`, `id`, or `referenceId`. Use only one field;
        priority is given to `email`, then `referenceId`, and finally `id` in
        the MuFi database.
      requestBody:
        description: >-
          User and pagination parameters. limit defaults to 10 and has a max
          limit of 1000.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GetManyUsersRequest'
      responses:
        '200':
          description: >-
            Returns a list of users associated with the project and the total
            number of users available for pagination. Each user object includes
            details such as `id`, `firstName`, `lastName`, `email`,
            `referenceId`, `isActivated`, and `activatedOn`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetManyUsersResponse'
        '401':
          description: >-
            Unauthorized. The API key is missing or has expired if you are using
            a key with an expiration date that you configured when creating the
            key.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                required:
                  - message
        '403':
          description: >-
            Forbidden. The API key that you provided is not valid or does not
            exist.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                required:
                  - message
      security:
        - BearerAuth: []
components:
  schemas:
    GetManyUsersRequest:
      type: object
      properties:
        limit:
          type: number
          minimum: 1
          maximum: 1000
          default: 10
        offset:
          type: number
          default: 0
    GetManyUsersResponse:
      type: object
      properties:
        users:
          type: array
          items:
            $ref: '#/components/schemas/UserWithWallets'
        total:
          type: number
      required:
        - users
        - total
    UserWithWallets:
      type: object
      properties:
        id:
          type: string
          format: uuid
        firstName:
          type:
            - string
            - 'null'
        lastName:
          type:
            - string
            - 'null'
        email:
          type: string
          format: email
        referenceId:
          $ref: '#/components/schemas/OptionalReferenceId'
        isActivated:
          type: boolean
        activatedOn:
          type:
            - string
            - 'null'
          format: date-time
        wallets:
          type: array
          items:
            type: object
            properties:
              type:
                $ref: '#/components/schemas/WalletType'
              address:
                type: string
              custody:
                $ref: '#/components/schemas/Custody'
            required:
              - type
              - address
              - custody
      required:
        - id
        - isActivated
        - activatedOn
        - wallets
    OptionalReferenceId:
      type:
        - string
        - 'null'
      description: >-
        An optional ID of the reference object in your database. This can be
        used to query events by reference object.
    WalletType:
      type: string
      enum:
        - Polkadot
    Custody:
      type: string
      enum:
        - user-controlled
        - custodial
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: A JWT Access Token obtained from Google Cloud.

````