Wallet
Get Wallet Balance
Returns the workspace's prepaid wallet balance. X actions are paid from it. When it is too low, they return INSUFFICIENT_WALLET.
GET
Bearerheader
AuthorizationBearer <op_>Workspace API key, sent as Authorization: Bearer op_... Keys are created in the dashboard.
Wallet
application/json- response
balance*stringThe balance in US dollars, with three decimal places.
currency*"usd"Always usd.
Value in
"usd"Example Request
import { Configuration, WalletApi } from "@onepostly/sdk";const walletApi = new WalletApi( new Configuration({ accessToken: process.env.ONEPOSTLY_API_KEY }));const response = await walletApi.getWalletBalance();console.log(response);Example Response
{ "balance": "12.345", "currency": "usd"}