Data Gifting API
To secure our API we use OAuth2 with password flow for all endpoints. Authorization header must always contain a Bearer token obtained using tokenURL.
On this link you can find the part of our documentation regarding token acquisition.
Once you have acquired the Bearer token you can use the following instructions to obtain Data Gifting
Assigning data
api.centili.com/datagifting/v1/service/transaction
Host: api.centili.com:443
Content-Type: application/json
token: *Bearer token obtained using tokenURL*
{
"serviceKey": "3586a2363bcd51a2b3c4d5f34918263a",
"msisdn": "4366124567",
"clientId": "454585",
"amount": 500 //in MB
}
Once the data has been assigned you can use the following GET requests to check on the services, balance and transactions.
Get transactions
api.centili.com/datagifting/v1/transaction?serviceKey=3586a2363bcd51a2b3c4d5f34918263a&msisdn=4366124567
Get a list of all data transactions for the given service key and msisdn. MSISDN is not required, in which case all transactions associated with the service are returned.
Get Services
api.centili.com/datagifting/v1/services?merchantId=11111
Get all services and packages for the merchant. If invoked via API Gateway, merchantId is not passed, but is read from Keycloak token.
Get Balance
api.centili.com/datagifting/v1/services/balance?serviceKey=3586a2363bcd51a2b3c4d5f34918263a&operator=FR_ORANGE
Get current state of all Service data pools associated with the given service key and operator (totalAmount, assignedAmount, expirationDate).
Updated 5 months ago