Balance API

GET https://services.onlinesales.ai/osBillingServiceV2/marketplace/balance

Query Parameters

Name
Type
Description

token*

String

Valid app token shared by Onlinesales.ai *note: do not use this token in any application on the client side.

merchantId*

String

Merchant id of seller / brand.

Merchant should be a valid merchant in OS systems.

merchantType*

String

Merchant type of the merchant for which the transaction is being carried out.

Expected Values: brand seller

marketplaceClientId*

Integer

Unique client id defined by OS for the marketplace. It will be different for staging and production.

Expected Values: Shared by OS

{
    "balanceAmount": 200,
    "marketplaceClientId": <Marketplace Client Id>,
    "totalCredit" : 1000,
    "totalSpend" : 800,
    "currency" : "USD"
}

Request Body

{
    "token": <token> <Token shared by onlinesales>,
    "merchantType" : "seller",
    "merchantId" : "8979879123",
    "marketplaceClientId": <Marketplace Client Id>
}

Sample Request

curl --location --request GET 
'https://services.onlinesales.ai/osBillingServiceV2/marketplace/balance?
merchantType=seller&merchantId=TOQ-15126
&marketplaceClientId=110600&token=376eae4b770b0efe50b6242bfd4aac47'

Response Field Description

Field
Data Type
Description

balanceAmount

Double (till 2 decimals)

This is the remaining amount for the specified merchant.

totalCredit

Double (till 2 decimals)

Total valid topups (payments) done till now.

totalSpend

Double (till 2 decimals)

Total spend reported in the system

currency

String

Currency in which balanceAmount totalCredit totalSpend is specified.

marketplaceClientId

Integer

Unique client id defined by OS for the marketplace. It will be different for staging and production.

Last updated