Skip to main content
GET
/
payment
/
summary
Get summary
curl --request GET \
  --url https://api.onswitch.xyz/payment/summary \
  --header 'x-service-key: <api-key>'
{
  "success": true,
  "message": "Payment summary fetched successfully",
  "timestamp": "2024-01-01T00:00:00.000Z",
  "data": {
    "payment_summary": {
      "payment_volume": 29492.907963,
      "no_of_payment": 18,
      "fee_collected": 0
    },
    "asset_breakdown": {
      "total": 29492.907963,
      "breakdown": {
        "ngn": {
          "amount": 7168.772496,
          "count": 1,
          "percentage": 24.306767
        },
        "usdc": {
          "amount": 12146.557741,
          "count": 11,
          "percentage": 41.184673
        },
        "usdt": {
          "amount": 10177.577726,
          "count": 6,
          "percentage": 34.50856
        }
      }
    },
    "network_breakdown": {
      "total": 29492.907963,
      "breakdown": {
        "avalanche": {
          "amount": 5578.306134,
          "count": 4,
          "percentage": 18.914059
        },
        "solana": {
          "amount": 10177.577726,
          "count": 6,
          "percentage": 34.50856
        },
        "fiat": {
          "amount": 7168.772496,
          "count": 1,
          "percentage": 24.306767
        },
        "base": {
          "amount": 6568.251607,
          "count": 7,
          "percentage": 22.270614
        }
      }
    },
    "status_breakdown": {
      "total": 71095.86236,
      "breakdown": {
        "awaiting_deposit": {
          "amount": 16477.199897,
          "count": 20,
          "percentage": 23.176032
        },
        "processing": {
          "amount": 25125.7545,
          "count": 1,
          "percentage": 35.340671
        },
        "completed": {
          "amount": 29492.907963,
          "count": 18,
          "percentage": 41.483297
        }
      }
    },
    "weekly_breakdown": {
      "last_week": {
        "onramp": [
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "offramp": [
          0,
          298.525286,
          0,
          0,
          0,
          0,
          0
        ],
        "swap": [
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ]
      },
      "this_week": {
        "onramp": [
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "offramp": [
          1457.63691,
          5092.969024,
          1999.679085,
          1066.31279,
          0,
          0,
          0
        ],
        "swap": [
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ]
      }
    },
    "monthly_breakdown": {
      "last_month": {
        "onramp": [
          0,
          0,
          7168.772496,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "offramp": [
          0,
          0,
          0,
          0,
          1.997596,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          1487.419139,
          742.017911,
          0,
          0,
          0,
          0,
          0,
          298.525286,
          0,
          0,
          0,
          0,
          0,
          1457.63691,
          5092.969024
        ],
        "swap": [
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ]
      },
      "this_month": {
        "onramp": [
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "offramp": [
          1999.679085,
          1066.31279,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ],
        "swap": [
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0,
          0
        ]
      }
    }
  }
}

Authorizations

x-service-key
string
header
required

Service key for API authentication

Query Parameters

start_date
string

Optional start of date range.

end_date
string

Optional end of date range.

Response

Payment summary retrieved successfully

success
boolean
required
message
string
required
timestamp
string<date-time>
required
data
object
required