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

# Get a credential by id or on-chain holder address

> Returns verifiable performance plus the on-chain anchor. `ref` may be a credential id or a 0x holder address.



## OpenAPI

````yaml /openapi.yaml get /api/v1/credentials/{ref}
openapi: 3.1.0
info:
  title: mag3nt API
  version: '2026-07-16'
  description: >
    Payment infrastructure for AI agents. Issue virtual cards backed by
    credentials, pay for API access via x402/AP2/MPP protocols, and settle in
    USDC on Base. Also covers Native Token Rails membership and recurring
    billing agreements, ERC-20 project token registration (including B20) and
    prepaid MAG3NT fee metering for DIRECT (non-custodial) settlement, the
    credential marketplace and Credential Token (CT) markets, account-wide token
    holdings, and signed webhooks for payment and subscription lifecycle events.
  contact:
    name: mag3nt
    url: https://mag3nt.com
  license:
    name: Proprietary
    url: https://github.com/mag3nt-com/mag3nt-node/blob/main/LICENSE
servers:
  - url: https://mag3nt.com
    description: Production
  - url: https://staging.mag3nt.com
    description: Staging, Base mainnet
security:
  - ApiKeyAuth: []
tags:
  - name: Payments
    description: Universal outbound protocol payments
  - name: Cards
    description: Virtual payment card lifecycle
  - name: Keys
    description: Developer API key management
  - name: Funding
    description: Treasury deposits and balances
  - name: x402
    description: HTTP 402 payment protocol
  - name: AP2
    description: Agent-to-Agent Payment Protocol
  - name: MPP
    description: Micropayment Protocol with streaming
  - name: Pay Links
    description: Shareable payment URLs
  - name: Withdrawals
    description: Withdraw unspent funds back to wallet
  - name: Settlement
    description: On-chain settlement status
  - name: Webhooks
    description: Signed payment and subscription lifecycle notifications for sellers
  - name: Status
    description: System health and configuration
  - name: Membership
    description: Native Token Rails membership tiers, checkout, and auto-renew
  - name: Billing
    description: Recurring billing agreements funded by AP2 open mandates
  - name: Tokens
    description: >-
      Register an ERC-20 contract (including B20 tokens) for DIRECT credential
      settlement
  - name: Fees
    description: Prepaid MAG3NT fee meter for DIRECT settlement overage
  - name: Marketplace
    description: >-
      List and transfer credential businesses (proof of record) on the mag3nt
      marketplace
  - name: Credential Tokens
    description: Credential Token (CT) launch and Uniswap V4 markets
  - name: Holdings
    description: Account-wide Credential Token balances
externalDocs:
  description: mag3nt documentation
  url: https://docs.mag3nt.com
paths:
  /api/v1/credentials/{ref}:
    get:
      tags:
        - Cards
      summary: Get a credential by id or on-chain holder address
      description: >-
        Returns verifiable performance plus the on-chain anchor. `ref` may be a
        credential id or a 0x holder address.
      operationId: v1GetCredential
      parameters:
        - name: ref
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Credential
          content:
            application/json:
              schema:
                type: object
                properties:
                  credential:
                    $ref: '#/components/schemas/PublicCredentialResource'
        '404':
          description: Credential not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    PublicCredentialResource:
      type: object
      description: >-
        The public developer-facing credential resource served by
        /api/v1/credentials.
      properties:
        id:
          type: string
        status:
          type:
            - string
            - 'null'
        asset:
          type: string
        created_at:
          type:
            - string
            - 'null'
          format: date-time
        onchain:
          type: object
          properties:
            network:
              type: string
            attested:
              type: boolean
              description: True once anything (holder or CRT) is on-chain.
            holder_address:
              type:
                - string
                - 'null'
            chain_status:
              type:
                - string
                - 'null'
            holder_explorer_url:
              type:
                - string
                - 'null'
            crt:
              type:
                - object
                - 'null'
              properties:
                address:
                  type:
                    - string
                    - 'null'
                symbol:
                  type:
                    - string
                    - 'null'
                status:
                  type:
                    - string
                    - 'null'
                explorer_url:
                  type:
                    - string
                    - 'null'
        performance:
          type: object
          properties:
            revenue_lifetime:
              type: number
            revenue_30d:
              type: number
            payments_lifetime:
              type: integer
            payments_30d:
              type: integer
            distinct_protocols:
              type: integer
            balance:
              type: number
            age_days:
              type:
                - integer
                - 'null'
            first_active:
              type:
                - string
                - 'null'
              format: date-time
            last_active:
              type:
                - string
                - 'null'
              format: date-time
        links:
          type: object
          properties:
            self:
              type: string
              format: uri
            market:
              type:
                - string
                - 'null'
              format: uri
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: string
          example: Card not found
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: API key prefixed with 'Bearer sx_live_...'

````