The meCash Docs is live 🎉 🎉
Wallets
Get Wallet Balance

Get Wallet Balance API Documentation

The Get Wallet Balance API retrieves the balance of a specific wallet. It requires the walletId as a path parameter and an API key for authentication.


Endpoint

GET: https://{{baseURL}}/v1/wallet/{walletId}/balance

Note: Replace {walletId} with the actual wallet ID.


Request Headers

HeaderTypeDescriptionRequiredExample Value
x-api-keyStringAPI key for authentication✅ YesAPI_KEY_HERE
Content-TypeStringRequest content type (JSON)✅ Yesapplication/json

Path Parameters

ParameterTypeDescriptionRequiredExample Value
walletIdStringUnique identifier for wallet✅ Yes12345-xyz

Example Request (cURL)

curl --location --request GET 'https://api.mecash/v1/wallet/{walletId}/balance' \
--header 'x-api-key: YOUR_API_KEY' \
--header 'Content-Type: application/json'

Responses*

Success Response (200 OK)

{
  "walletId": "12345-xyz",
  "balance": 100.50,
  "currency": "USD"
}
FieldTypeDescription
walletIdStringThe unique wallet identifier
balanceNumberAvailable balance in the wallet
currencyStringCurrency of the balance

Error Responses

Unauthorized (401)

{
  "error": "Unauthorized",
  "message": "Invalid API key"
}

Not Found (404)

{
  "error": "Not Found",
  "message": "Wallet not found"
}

Server Error (500)

{
  "error": "Internal Server Error",
  "message": "Something went wrong on our end. Please try again later."
}