Get Balance API API
The Get Balance API API endpoint provides access to the get balance api functionality.
Endpoint Details
- Method:
GET
- URL:
/api/balance
Request Body
Example Request Body
{
// Request payload for Get Balance API API
}
Example Usage
JavaScript Example
const fetch = require('node-fetch');
const getBalance = async () => {
const response = await fetch('https://your-api.com/api/balance', {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_TOKEN',
},
});
if (!response.ok) {
throw new Error('Failed to fetch balance');
}
const data = await response.json();
console.log('Balance:', data.balance);
};
getBalance().catch(console.error);
Response
Successful Response
200 OK
{}
Error Response
Example Error
Error Response
{
// Example error payload
}