> ## 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.

# Verify an on-chain funding transaction

> Submit an on-chain transaction hash to credit your treasury balance. The platform verifies the transaction on-chain, confirms the Transfer event matches the treasury address, and atomically credits your balance. Idempotent: re-submitting an already-confirmed tx_hash returns the existing balance without double-crediting.




## OpenAPI

````yaml /openapi.yaml post /api/fund/verify
openapi: 3.1.0
info:
  title: mag3nt API
  version: '2026-06-04'
  description: >
    Payment infrastructure for AI agents. Issue virtual cards, pay for API
    access via x402/AP2/MPP protocols, and settle in USDC on Base.
  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
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.settled notifications for sellers
  - name: Status
    description: System health and configuration
externalDocs:
  description: mag3nt documentation
  url: https://docs.mag3nt.com
paths:
  /api/fund/verify:
    post:
      tags:
        - Funding
      summary: Verify an on-chain funding transaction
      description: >
        Submit an on-chain transaction hash to credit your treasury balance. The
        platform verifies the transaction on-chain, confirms the Transfer event
        matches the treasury address, and atomically credits your balance.
        Idempotent: re-submitting an already-confirmed tx_hash returns the
        existing balance without double-crediting.
      operationId: fundingVerify
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - tx_hash
              properties:
                tx_hash:
                  type: string
                  description: On-chain transaction hash to verify
                network:
                  type: string
                  default: eip155:8453
                asset:
                  type: string
                  default: USDC
      responses:
        '200':
          description: Funding verified or pending
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                  status:
                    type: string
                    enum:
                      - confirmed
                      - pending
                  funded:
                    type:
                      - number
                      - string
                    description: Amount credited from this transaction
                  balance:
                    $ref: '#/components/schemas/Balance'
        '400':
          description: Missing tx_hash or no matching transfer found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    Balance:
      type: object
      properties:
        total_funded:
          type:
            - number
            - string
        total_allocated:
          type:
            - number
            - string
        total_spent:
          type:
            - number
            - string
        total_withdrawn:
          type:
            - number
            - string
        available:
          type:
            - number
            - string
        network:
          type: string
        asset:
          type: string
    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_...'

````