Digital Value Services API (1.21.0)

Download OpenAPI specification:Download

Starting out on your integration journey? Access our quick start guide.

Overview

Welcome to the comprehensive reference and guide to the Digital Value Services (DVS) API.

As the main gateway, this API plays a crucial role in faciliating a broad spectrum of digital value transactions across the extensive DT One network. Beyond its remarkable global reach, which includes over 160 countries and partnerships with more than 875 mobile operators and billers, the network also encompasses a diverse array of services. These include eSIM options, utility and bill payment services, a multitude of gift card products, gaming PINs, and much more. This diversity in offering ensures that the API can cater to a wide range of digital transaction needs, making it a versatile tool for users worldwide.

Structured in the robust foundations of REST principles, the DVS API uses JSON for its data interchange format. It encompasses a variety of services, including:

To access the API, you will need a valid pair of keys as detailed in the Authentication section. This requires you to first register for a DT Shop account. Once registered, you can generate keys for both production and pre-production environments in the Developer Section of your DT Shop account.

Your queries and feedback are invaluable to us. Should you have any questions or suggestions about our API, we warmly encourage you to reach out to us by sending an email to the DVS API support team. Your inputs help us continually improve and tailor our services to better meet your needs.

Integration Libraries

Officially supported SDKs are available for the following languages:

These SDKs offer an accelerated path to developing your applications as an alternative to accessing the REST API directly.

Separately, we would love to hear from you! If you have any questions and/or suggestions related to our SDKs, please do not hesitate to create corresponding GitHub issues or send an email to the DVS Open Source team.

Sandbox

A sandbox environment is available for testing integrations with the DVS API. It is available at https://preprod-dvs-api.dtone.com/v1/.

You can generate sandbox API keys from your DT Shop account, under the Pre-Production API Keys section.

All transactions on the sandbox environment are simulated: no real transaction goes through. To simulate different responses, the last three digits of the credit_party_identifier (i.e. mobile_number or account_number, depending on the required_credit_party_identifier_fields of a given Product) will have to be replaced with one of the following suffixes:

Suffix Transaction Status Example
100, 200, 300 COMPLETED (PIN-less) +6595123100
101, 201, 301 COMPLETED (PIN-based) +6595123201
102, 202, 302 DECLINED-INVALID-CREDIT-PARTY +6595123102
103, 203, 303 DECLINED-BARRED-CREDIT-PARTY +6595123103
104, 204, 304 DECLINED-OPERATOR-CURRENTLY-UNAVAILABLE +6595123204
105, 205, 305 DECLINED-DUPLICATED-TRANSACTION +6595123105
106, 206, 306 DECLINED +6595123206
107, 207, 307 DECLINED-EXCEPTION +6595123107

The different suffixes for a given transaction status can be used to simulate delays, as follows:

  • 10X suffix will take at least 3 seconds to finish
  • 20X suffix will take at least 20 seconds to finish
  • 30X suffix will take at least 5 minutes to finish

Please note that there are products that do not require any credit party identifier such as Gift Cards. For these products, the simulated transaction will always be in COMPLETED status.

Versioning

Endpoints of the API are prefixed with a corresponding version number. This method provides complete isolation between implementations and guarantees subsequent major changes to the API will never affect existing integrations. No breaking changes will be introduced within a major version. This distinction is further expounded in the subsection that follows.

Non-Breaking Changes

Also known as backward-compatible changes, such changes allow for your integration to continue without requiring additional changes on your side. Such changes also do not warrant a new version number and will be released without prior communication.

Changes in this category are mainly "additive" in nature, with the following examples:

  • Adding new API endpoints
  • Adding optional fields to a request body and/or header
  • Adding fields to a response body and/or header
  • Data changes:
    • Adding new Countries / Operators / Products / Services
    • Modification of text and/or numeric field values, such as:
      • Country / Operator / Product / Service Names
      • Wholesale / Retail Prices and/or Rates
      • Status and Error Descriptions
  • Adding fields to a callback request body

💡 Before going live, it is very important to validate that your integration is capable of handling non-breaking API changes to mitigate avoidable disruptions to your service.

Breaking Changes

Breaking changes, on the other hand, require additional changes to your integration. Such changes correspond to major updates in the API and are mainly reserved for changes that brings about a substantial feature and/or improvement to the platform. When such changes occur, as endpoints of the API are prefixed with a corresponding version number, your existing integration won't be at risk of breaking as complete isolation of differences in implementation between versions are provided.

Examples of changes in this category are as follows:

  • Removing and/or renaming API endpoints
  • Adding required fields to a request body and/or header
  • Removing and/or renaming fields from a request body and/or header
  • Removing and/or renaming fields from a response body and/or header
  • Removing and/or renaming fields from a callback request body

💡 When a new version of the API is available and you are keen to upgrade, testing in the sandbox environment to ensure that everything works well with your implementation before switching to the production environment comes highly recommended.

Transactions

The main purpose of this API is to deliver value (e.g. mobile airtime top-up, data bundles, etc.) to a beneficiary. This is what we call a "transaction".

During the course of a transfer, a transaction undergoes various status changes (or transitions) as illustrated below.

transaction states

As changes in transaction status occur, updates are sent in real-time when a callback URL is provided. In conjunction, transaction status can be queried through one of two means: via the returned id or a provided external_id.

The latter serves as your unique reference and provides a utility to retrieve transaction details when exceptions occur, such as when the supposed API response was not received, as an example.

Balances

Transactions can be created through the platform as long as there is enough balance available in your account. A given balance is composed of the following:

Balance Description
Available Balance amount available for use
Holding Amount being held while transactions are being processed

As a given transaction goes through various changes in status as outlined here, corresponding balance movements will be made. The following table illustrates the relationship between transaction status and balance movements:

Transaction Status Balance Movement Description
CREATED Authorize Transfer wholesale price and fee from available to holding
CANCELLED, REJECTED, DECLINED Void Amount authorized in holding moves back to available
COMPLETED Capture Amount authorized in holding is captured, i.e. debited
REVERSED Reverse Debited amount is reversed back into available

Flow

Once a product has been selected through one of the discovery methods provided by the API, the actual transfer (i.e. transaction) can be performed in either one of the following modes:

  • Asynchronous (recommended)
  • Synchronous

Each mode is accessible via a specific endpoint.

As soon as a transaction is confirmed, the transfer order will be sent to the operator for immediate processing. During this time, the transaction will remain in a CONFIRMED status until the final status is received from the operator.

Asynchronous Mode

When a transaction is created and confirmed in an asynchronous fashion, the HTTP connection won't have to be kept open. This preserves system resources on your applications. As such, performing transactions asynchronously is recommended.

Synchronous Mode

When a transaction is created and confirmed in a synchronous fashion, the HTTP connection will be kept open in an attempt to capture the final status from the receiving operator so it can be returned in the API response. The processing time usually takes just a few seconds. However, with some receiving operators, it may take longer.

Our system will keep the HTTP connection open for up to 180 seconds and will return a status before closing this connection. This status can be in one of the final status (e.g. COMPLETED, DECLINED) or not (e.g. SUBMITTED). In the latter case, this denotes the transaction is still being processed by the receiving operator.

Note: your application does not have to wait for the connection to close, it can listen for a shorter period of time and query the final status later on (refer to the "Final Status" section below for more details).

Final Status

Regardless of the processing mode, the application should be designed to capture the final status of a transaction. This can be done through one of the following means:

  • Checking the status of a specific transaction via the corresponding API method ("pull" mechanism)
  • Configuring a callback URL passed in the request when creating a transaction ("push" mechanism)

Callbacks

As a transaction is being processed, changes in status will be notified in real-time if a callback URL was provided. Even though one callback per transaction is expected (i.e. change to either COMPLETED or DECLINED), a manual reversal from the DT One team, which may happen in very rare occasions, will also trigger a callback to inform your application of a change in transaction status to REVERSED.

This callback endpoint must be implemented by the sending partner, which should expect an HTTP POST request containing a transaction object represented in JSON. As callbacks will be sent from the DT One servers, these endpoints will have to be publicly-accessible in most cases. During development, a service such as ngrok can be used to expose local servers to the internet.

Upon successful receipt of data, the callback endpoint should respond with an HTTP 2XX status. In the event that the platform did not receive a successful status, callback notifications will be retried several times, beyond which, the transaction status will have to be queried through the API.

Status and Errors

HTTP Status Codes

DT One uses standard HTTP response codes to indicate whether an API request was successful or not.

Status Description
200 OK
201 Created: Resource created
202 Accepted: Request has been accepted for processing
400 Bad Request: Request was malformed
401 Unauthorized: Credentials missing or invalid
404 Not Found: Resource doesn't exist
429 Too Many Requests
500 Server Error: Error occurred on DT One
503 Service Unavailable

API Error Codes

Code Description HTTP Status
1000400 Bad Request 400
1000401 Unauthorized 401
1000404 Resource not found 404
1000429 Too many requests 429
1003001 Product is not available in your account 404
1003002 Requested product amount is out of range 400
1003003 Requested product unit is invalid 400
1003101 Benefits not defined for available products 404
1003201 Promotion not found 404
1003301 Campaign not found 404
1005003 Credit party mobile number is invalid 400
1005004 Service not found 404
1005005 Country not found 404
1005006 Operator not found 404
1005503 Sender mobile number is invalid 400
1006001 Insufficient balance 400
1006003 Debit party mobile number is invalid 400
1006009 Account balance not found 404
1006503 Beneficiary mobile number is invalid 400
1007001 Transaction external ID has already been used 400
1007002 Transaction has already been confirmed 400
1007004 Transaction can no longer be confirmed 400
1007005 Transaction has already been cancelled 400
1007007 Transaction can no longer be cancelled 400
1007500 Method not supported by operator 400
1008004 Transaction not found 404
1009001 Unexpected error, please contact our support team 500
1009503 Service unavailable, please retry later 503

Transaction Status

Class Status Description
CREATED CREATED Created
CONFIRMED CONFIRMED Confirmed
REJECTED REJECTED Rejected
REJECTED REJECTED-INVALID-CREDIT-PARTY Rejected - Credit party is invalid
REJECTED REJECTED-BARRED-CREDIT-PARTY Rejected - Credit party is barred
REJECTED REJECTED-INELIGIBLE-CREDIT-PARTY Rejected - Credit party is ineligible for chosen product
REJECTED REJECTED-INVALID-DEBIT-PARTY Rejected - Debit party is invalid
REJECTED REJECTED-BARRED-DEBIT-PARTY Rejected - Debit party is barred
REJECTED REJECTED-LIMITATIONS-ON-CREDIT-PARTY-AMOUNT Rejected - Limitations on credit party cumulative transaction amount
REJECTED REJECTED-LIMITATIONS-ON-CREDIT-PARTY-QUANTITY Rejected - Limitations on credit party cumulative transaction quantity
REJECTED REJECTED-OPERATOR-CURRENTLY-UNAVAILABLE Rejected - Operator currently unavailable
REJECTED REJECTED-INSUFFICIENT-BALANCE Rejected - Insufficient balance
CANCELLED CANCELLED Cancelled
SUBMITTED SUBMITTED Submitted
COMPLETED COMPLETED Completed
REVERSED REVERSED Reversed
DECLINED DECLINED Declined (no additional information available)
DECLINED DECLINED-INVALID-CREDIT-PARTY Declined - Credit party is invalid
DECLINED DECLINED-BARRED-CREDIT-PARTY Declined - Credit party is barred
DECLINED DECLINED-INELIGIBLE-CREDIT-PARTY Declined - Credit party is ineligible for chosen product
DECLINED DECLINED-INVALID-DEBIT-PARTY Declined - Debit party is invalid
DECLINED DECLINED-BARRED-DEBIT-PARTY Declined - Debit party is barred
DECLINED DECLINED-LIMITATIONS-ON-OPERATOR-AMOUNT Declined - Limitations on operator cumulative transaction amount
DECLINED DECLINED-LIMITATIONS-ON-CREDIT-PARTY-AMOUNT Declined - Limitations on credit party cumulative transaction amount
DECLINED DECLINED-LIMITATIONS-ON-CUSTOMER-AMOUNT Declined - Limitations on customer cumulative transaction amount
DECLINED DECLINED-LIMITATIONS-ON-OPERATOR-QUANTITY Declined - Limitations on operator cumulative transaction quantity
DECLINED DECLINED-LIMITATIONS-ON-CREDIT-PARTY-QUANTITY Declined - Limitations on credit party cumulative transaction quantity
DECLINED DECLINED-LIMITATIONS-ON-CUSTOMER-QUANTITY Declined - Limitations on customer cumulative transaction quantity
DECLINED DECLINED-DUPLICATED-TRANSACTION Declined - Duplicated transaction
DECLINED DECLINED-OPERATOR-CURRENTLY-UNAVAILABLE Declined - Operator currently unavailable

REJECTED and DECLINED status classes both denote unsuccessful transactions. The primary distinction between these two relates to the party that determined the failure:

  • REJECTED are issued by the DVS platform based on various business rules (e.g. insufficient balance, limitations, etc)
  • DECLINED are issued by the operators

Separately, it is recommended to define application logic based on classes, while additional distinction and/or insight are reflected on the actual status.

Pagination

API resources supporting bulk fetches via "list" API methods will be returned in a paginated fashion.

Input Parameters

Field Required Type Description
page No Integer Page number
per_page No Integer Number of results per page (default 50, max 100)

Output Headers

Field Description
X-Total Total number of records
X-Total-Pages Total number of pages
X-Per-Page Number of records per page
X-Page Current page number
X-Next-Page Next page number (if any)
X-Prev-Page Previous page number (if any)

Internationalization

Support for internationalization (i18n) is implemented via standard HTTP content negotiation. API resources offering i18n will have the following request and response headers:

Input Headers

Field Required Type Description
Accept-Language No String List of preferred languages for the content

Output Headers

Field Description
Content-Language List of languages in the returned content

Rate Limiting

The API endpoints have rate limiting in place to protect our service from excessive number of requests. Rate limiting is enforced for every pair of API key and secret and the number of remaining API requests over a period of time (i.e. expressed in seconds) is conveyed through corresponding HTTP headers:

Response Headers

Field Description
X-Ratelimit-Limit Number of allowed API calls over period of time
X-Ratelimit-Remaining Remaining number of allowed API calls

If the limit is reached, an HTTP error 429 will be returned by the server.

Authentication

BasicAuth

The Digital Value Services API requires requests to be authenticated through individualized API keys. You can view and manage your API keys in DT Shop.

Your API keys carry many privileges, so please keep them secure! Do not share your secret API keys in publicly-accessible areas such as GitHub, client-side code, and so forth.

Authentication to the API is performed via HTTP Basic Auth. Provide your API key as the basic auth username value and your API secret as your password.

Except when site-to-site VPN is set up, all API requests must be made over HTTPS with TLS 1.2.

On a side note, we strongly recommend securing your applications against common security flaws by employing best practices such as the OWASP Top 10.

Security Scheme Type HTTP
HTTP Authorization Scheme basic

Services

The Digital Value Services platform offers a wide array of products spread across diverse industries, categorized as "services." Each service encompasses specific examples, providing a broad spectrum of options to cater to different needs.

Digital products on our platform are designed for different areas: some are for use in just one country, while others can be used across multiple countries or even globally. One of the key features of the API is its ability to return "coverage" - a list of countries where a particular product is supported. This feature is currently in beta-testing mode. To start utilizing it, it's important to ensure that your account is opted-in for beta features. You can activate this by sending a detailed request to our Customer Care team, expressing your interest in accessing this feature. This will enable you to fully leverage the global capabilities of the API.

Service ID Examples
Mobile 1 Airtime Top Ups, Mobile Data Bundles, SMS
Utilities 3 Electricity, Water, Gas, Internet, etc
Gift Cards 4 Vouchers, Groceries, General Gift Cards, etc
Insurance 7 Insurance
Finance 10 Financial Services and Institutions
Government 11 Government Agencies
Education 12 Educational Institutions
eSIM 13 eSIM

Additionally, some services are further subdivided into subservices:

Service ID Subservices
Mobile 11
12
13
Airtime
Bundle
Data
Utilities 31
32
33
34
35
36
37
Electricity
Water
Gas
Internet
Landline
Television
VoIP
Gift Cards 41
42
44
44
45
46
Retail
Gaming
Cash Cards
Food
Entertainment
Travel and Transport

💡 Access to services and subservices on the DVS platform will depend on whether these services are included in your pricelist. If you notice a service that you need is not available, it may be because products under this specific service has not yet been added to your pricelist. To address this, you can reach out directly to your Account Manager, who can assist in customizing your pricelist to include the needed services. Alternatively, you can send an email to our Customer Care team with a detailed request of adding a specific service type. This process ensures that your pricelist is tailored to meet your unique business requirements and preferences, allowing you to fully utilize the range of services offered by the platform.

Retrieve list of services

Authorizations:
query Parameters
country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve service by ID

Authorizations:
path Parameters
service_id
required
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details.

Responses

Response samples

Content type
application/json
{
  • "id": 1,
  • "name": "string",
  • "subservices": [
    ]
}

Countries

Products available in the platform cover various geographical areas. These endpoints provide the means to enumerate available countries, which can then be used to filter against the list of available products in your account. Countries are displayed in the official names along with their standard ISO 3166 codes. For countries that have multi-country coverage, these are indicated by especially-designated 3-digit codes that conforms with the same pattern as with the standard ISO codes:

Country ISO Code
Global GXX
Europe EXX

Please note that these countries are in addition to the official list of ISO 3166 codes, and are introduced to cater to specific needs to denote regional coverage. This flexibility allows for more comprehensive product discovery and tailored services, especially in contexts like eSIM and multi-country products, where geographical specificity is important.

Retrieve list of countries

Authorizations:
query Parameters
service_id
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details. Required when subservice_id is specified.

subservice_id
integer <int32> (SubServiceID) >= 1

Sub-service identifier. See Services for more details.

page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve country by ISO code

Authorizations:
path Parameters
country_iso_code
required
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

Responses

Response samples

Content type
application/json
{
  • "name": "string",
  • "iso_code": "string",
  • "regions": [
    ]
}

Operators

Products in the Digital Value Services Platform are associated to individual service providers, termed as "operators".

Some examples of operators include:

Retrieve list of operators

Authorizations:
query Parameters
country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

service_id
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details. Required when subservice_id is specified.

subservice_id
integer <int32> (SubServiceID) >= 1

Sub-service identifier. See Services for more details.

page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve operator by ID

Authorizations:
path Parameters
operator_id
required
integer <int32> (OperatorID) >= 1

Operator identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 1,
  • "name": "string",
  • "country": {
    },
  • "regions": [
    ]
}

Benefits

Products ultimately redeem into one or more underlying benefits. These endpoints provide the means to enumerate available benefits, which can then be used to filter against the list of available products in your account.

Benefit Type Examples
TALKTIME Talktime Minutes
DATA Mobile Data, Broadband Data
SMS SMS, MMS
PAYMENT Bill Payment, Insurance Payment
CREDITS Prepaid Credits

Retrieve list of benefit types

Authorizations:
query Parameters
page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Promotions

Receiving operators are running seasonal promotions on selected products, this endpoint will provide visiblity on these promotions: start date, end date, terms and conditions, eligible products, ...

Retrieve list of promotions

Authorizations:
query Parameters
page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

operator_id
integer <int32> (OperatorID) >= 1

Operator identifier.

product_id
integer <int32> (ProductID) >= 1

Product identifier.

header Parameters
Accept-Language
string
Example: es

Preferred language for the content

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve promotion by ID

Authorizations:
path Parameters
promotion_id
required
integer <int32> (PromotionID) >= 1

Promotion identifier.

header Parameters
Accept-Language
string
Example: es

Preferred language for the content

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "title": "string",
  • "description": "string",
  • "terms": "string",
  • "start_date": "2019-08-24T14:15:22Z",
  • "end_date": "2019-08-24T14:15:22Z",
  • "operator": {
    },
  • "products": [
    ]
}

Campaigns

Custom marketing campaigns, this endpoint will provide visiblity on these campaigns.

Retrieve list of active campaigns

Authorizations:
query Parameters
page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

operator_id
integer <int32> (OperatorID) >= 1

Operator identifier.

product_id
integer <int32> (ProductID) >= 1

Product identifier.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve campaign by ID

Authorizations:
path Parameters
campaign_id
required
integer <int32> (CampaignID) >= 1

Campaign identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "title": "string",
  • "description": "string",
  • "terms": "string",
  • "start_date": "2019-08-24T14:15:22Z",
  • "end_date": "2019-08-24T14:15:22Z",
  • "products": [
    ]
}

Products

Products form the actual digital values and/or products being transferred through the Digital Value Services platform.

Product Type Description
FIXED_VALUE_RECHARGE Fixed denomination recharge
RANGED_VALUE_RECHARGE Recharge against a range of value
FIXED_VALUE_PIN_PURCHASE Digital voucher storing a fixed value
RANGED_VALUE_PIN_PURCHASE Digital voucher with a range of possible values
RANGED_VALUE_PAYMENT Pay bills and/or services

Products are organized and subdivided into distinct types as each one has distinct characteristics and technical implications when transactions are performed. As such, each product type also carries a distinct schema.

The regions field indicates product coverage on a given country across its constituents where applicable. Examples of the discovery flow for such products are as follows:

  1. Retrieve all Global products:

    • Endpoint: GET /v1/products?country_iso_code=GXX
    • Returns: Global products
  2. Retrieve Regional products:

    • Endpoint: GET /v1/products?country_iso_code=EXX
    • Returns: Products in the Europe region.
  3. Retrieve Country-Specific products:

    • Endpoint: GET /v1/products?country_iso_code=MXN
    • Returns: Products specifically for Mexico.
  4. Retrieve all products available for a given country, including Global and Regional products:

    • Endpoint: GET /v1/products?region={country_iso_code}
    • Returns: Products covering a specific country, including Global, Regional, and Country-Specific products.

Retrieve list of products

Authorizations:
query Parameters
type
string (ProductTypes)
Enum: "FIXED_VALUE_RECHARGE" "RANGED_VALUE_RECHARGE" "FIXED_VALUE_PIN_PURCHASE" "RANGED_VALUE_PIN_PURCHASE" "RANGED_VALUE_PAYMENT"
service_id
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details. Required when subservice_id is specified.

subservice_id
integer <int32> (SubServiceID) >= 1

Sub-service identifier. See Services for more details.

tags
Array of strings (ProductTag) non-empty unique
country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

operator_id
integer <int32> (OperatorID) >= 1

Operator identifier.

region
string (X-ISO-3166-2) ^[A-Z]{2,3}(?:-[A-Z0-9]{2,3}(?:-[A-Z]{2})?)?$...

Country subregion code in ISO 3166 format. Note that the official list can be extended with additional country codes.

benefit_types
Array of strings (BenefitTypes) unique
Items Enum: "TALKTIME" "DATA" "SMS" "PAYMENT" "CREDITS"
page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

header Parameters
Accept-Language
string
Example: es

Preferred language for the content

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve product by ID

Authorizations:
path Parameters
product_id
required
integer <int32> (ProductID) >= 1

Product identifier.

header Parameters
Accept-Language
string
Example: es

Preferred language for the content

Responses

Response samples

Content type
application/json
Example
{
  • "id": 0,
  • "name": "string",
  • "description": "string",
  • "tags": [
    ],
  • "service": {
    },
  • "operator": {
    },
  • "regions": [
    ],
  • "type": "FIXED_VALUE_RECHARGE",
  • "validity": {
    },
  • "required_debit_party_identifier_fields": [
    ],
  • "required_credit_party_identifier_fields": [
    ],
  • "required_sender_fields": [
    ],
  • "required_beneficiary_fields": [
    ],
  • "required_statement_identifier_fields": [
    ],
  • "required_additional_identifier_fields": [
    ],
  • "availability_zones": [
    ],
  • "source": {
    },
  • "destination": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ]
}

Transactions

Create a transaction asynchronously

Two transaction modes (asynchronous and synchronous) are available. This endpoint lets you create a transaction in the asynchronous mode. Note that the auto_confirm flag can be set to simultaneously create and confirm a transaction in one step (i.e. HTTP request).

Authorizations:
Request Body schema: application/json
external_id
required
string [ 1 .. 40 ] characters \S

Unique identifier for the transaction in your system.

product_id
required
integer <int32> >= 1

Product identifier.

calculation_mode
string Nullable
Enum: "SOURCE_AMOUNT" "DESTINATION_AMOUNT"

Required when product type is either RANGED_VALUE_RECHARGE, RANGED_VALUE_PIN_PURCHASE, or RANGED_VALUE_PAYMENT

object Nullable

Required for ranged value products and when calculation_mode is set to SOURCE_AMOUNT

object Nullable

Required for ranged value products and when calculation_mode is set to DESTINATION_AMOUNT

auto_confirm
boolean
Default: false

Determines whether a transaction will be automatically confirmed upon creation or not. This is opted-out by default. Setting this field to true is recommended when transaction details, e.g. prices, are known as it removes the need to perform a separate API call to confirm transactions.

object Nullable

Sender details for a transaction. This information is mostly optional and will only be required for products with sender information requirements as outlined in required_sender_fields.

object Nullable

Beneficiary details for a transaction. This information is mostly optional and will only be required for products with beneficiary information requirements as outlined in required_beneficiary_fields.

object Nullable

Sending account details for a transaction. This information is mostly optional and will only be required for products with debit party information requirements as outlined in required_debit_party_identifier_fields.

object Nullable

Receiving account details for a transaction. This information will be required for the majority of products with credit party inofrmation requirements outlined in required_credit_party_identifier_fields, but will be optional for certain products without any upfront recipient, e.g. Gift Cards.

object Nullable

Qualifying statement details for a payment transaction. This information is mostly optional and will only be required for specific payment products with statement identifier requirements as outlined in required_statement_identifier_fields.

object Nullable

Additional details for a transaction. This information is mostly optional and will be required primarily for compliance reasons for products with additional information requirements as outlined in required_additional_identifier_fields.

callback_url
string <uri> (CallbackURL)

Transaction status updates will be sent to this endpoint. See Callbacks for more details.

Responses

Request samples

Content type
application/json
{
  • "external_id": "string",
  • "product_id": 1,
  • "calculation_mode": "SOURCE_AMOUNT",
  • "source": {
    },
  • "destination": {
    },
  • "auto_confirm": false,
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    },
  • "callback_url": "http://example.com"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Create a transaction synchronously

Two transaction modes (asynchronous and synchronous) are available. This endpoint lets you create a transaction in the synchronous mode. Note that the auto_confirm flag can be set to simultaneously create and confirm a transaction in one step (i.e. HTTP request).

Authorizations:
Request Body schema: application/json
external_id
required
string [ 1 .. 40 ] characters \S

Unique identifier for the transaction in your system.

product_id
required
integer <int32> >= 1

Product identifier.

calculation_mode
string Nullable
Enum: "SOURCE_AMOUNT" "DESTINATION_AMOUNT"

Required when product type is either RANGED_VALUE_RECHARGE, RANGED_VALUE_PIN_PURCHASE, or RANGED_VALUE_PAYMENT

object Nullable

Required for ranged value products and when calculation_mode is set to SOURCE_AMOUNT

object Nullable

Required for ranged value products and when calculation_mode is set to DESTINATION_AMOUNT

auto_confirm
boolean
Default: false

Determines whether a transaction will be automatically confirmed upon creation or not. This is opted-out by default. Setting this field to true is recommended when transaction details, e.g. prices, are known as it removes the need to perform a separate API call to confirm transactions.

object Nullable

Sender details for a transaction. This information is mostly optional and will only be required for products with sender information requirements as outlined in required_sender_fields.

object Nullable

Beneficiary details for a transaction. This information is mostly optional and will only be required for products with beneficiary information requirements as outlined in required_beneficiary_fields.

object Nullable

Sending account details for a transaction. This information is mostly optional and will only be required for products with debit party information requirements as outlined in required_debit_party_identifier_fields.

object Nullable

Receiving account details for a transaction. This information will be required for the majority of products with credit party inofrmation requirements outlined in required_credit_party_identifier_fields, but will be optional for certain products without any upfront recipient, e.g. Gift Cards.

object Nullable

Qualifying statement details for a payment transaction. This information is mostly optional and will only be required for specific payment products with statement identifier requirements as outlined in required_statement_identifier_fields.

object Nullable

Additional details for a transaction. This information is mostly optional and will be required primarily for compliance reasons for products with additional information requirements as outlined in required_additional_identifier_fields.

Responses

Request samples

Content type
application/json
{
  • "external_id": "string",
  • "product_id": 1,
  • "calculation_mode": "SOURCE_AMOUNT",
  • "source": {
    },
  • "destination": {
    },
  • "auto_confirm": false,
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Query a transaction by ID

This endpoint will return the details of the requested transaction.

Authorizations:
path Parameters
transaction_id
required
integer <int64> (TransactionID) >= 1

Unique transaction identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    },
  • "callback_url": "http://example.com"
}

Query list of transactions

This endpoint will return a list of transactions matching the search criteria. Please note that when this endpoint is called without any parameters and/or if neither date ranges (i.e. from_date, to_date) nor external_id are specified, transactions created within the last 24 hours will be returned by default.

Authorizations:
query Parameters
external_id
string non-empty

Unique identifier for the transaction in your system.

product_type
string (ProductTypes)
Enum: "FIXED_VALUE_RECHARGE" "RANGED_VALUE_RECHARGE" "FIXED_VALUE_PIN_PURCHASE" "RANGED_VALUE_PIN_PURCHASE" "RANGED_VALUE_PAYMENT"
service_id
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details.

subservice_id
integer <int32> (SubServiceID) >= 1

Sub-service identifier. See Services for more details.

country_iso_code
string (X-ISO-3166-1_Alpha-3) ^[A-Z]{3}$

Country code in ISO 3166 format. Note that the official list can be extended with additional country codes.

operator_id
integer <int32> (OperatorID) >= 1

Operator identifier.

status_id
integer
credit_party_mobile_number
string (E164) ^\+[1-9][0-9]{6,14}$

Mobile number in E.164 format.

credit_party_account_number
string (AccountNumber) [ 1 .. 90 ] characters \S

Account number.

from_date
string <date-time>
Example: from_date=1970-01-01T00:00:00.000000Z

Starting date to filter transactions based on creation date, inclusive of the provided date. Please note that the window between from_date and to_date can not exceed 24 hours.

to_date
string <date-time>
Example: to_date=2020-02-02T14:00:00.022220+08:00

Ending date to filter transactions based on creation date, inclusive of the provided date. Please note that the window between from_date and to_date can not exceed 24 hours.

page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Confirm a transaction asynchronously

If an asynchronous transaction was created without setting the auto_confirm flag, this endpoint will have to be called to confirm the transaction. Once successfully confirmed, the transfer order will be submitted to the operator to be processed.

Please note that only unexpired transactions can be confirmed, as denoted in the confirmation_expiration_date field of the transaction. Beyond this, the only allowed change is to cancel the transaction, so as to release the held balance.

Authorizations:
path Parameters
transaction_id
required
integer <int64> (TransactionID) >= 1

Unique transaction identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Confirm a transaction synchronously

If a synchronous transaction was created without setting the auto_confirm flag, this endpoint will have to be called to confirm the transaction. Once successfully confirmed, the transfer order will be submitted to the operator to be processed.

Please note that only unexpired transactions can be confirmed, as denoted in the confirmation_expiration_date field of the transaction. Beyond this, the only allowed change is to cancel the transaction, so as to release the held balance.

Authorizations:
path Parameters
transaction_id
required
integer <int64> (TransactionID) >= 1

Unique transaction identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Cancel a transaction

If a transaction is still in the CREATED state, it has not yet been submitted to the receiving operator for processing. You can thus request to cancel such transactions by calling this endpoint.

Authorizations:
path Parameters
transaction_id
required
integer <int64> (TransactionID) >= 1

Unique transaction identifier.

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "external_id": "string",
  • "creation_date": "2019-08-24T14:15:22Z",
  • "confirmation_expiration_date": "2019-08-24T14:15:22Z",
  • "confirmation_date": "2019-08-24T14:15:22Z",
  • "status": {
    },
  • "operator_reference": "string",
  • "pin": {
    },
  • "product": {
    },
  • "prices": {
    },
  • "rates": {
    },
  • "benefits": [
    ],
  • "promotions": [
    ],
  • "requested_values": {
    },
  • "adjusted_values": {
    },
  • "sender": {
    },
  • "beneficiary": {
    },
  • "debit_party_identifier": {
    },
  • "credit_party_identifier": {
    },
  • "statement_identifier": {
    },
  • "additional_identifier": {
    }
}

Balances

This endpoint can be used to retrieve the status of all your balances in real time.

Note that transactions will only be accepted if you have enough funds on your account so it's important to keep an eye on it.

Retrieve balances

Authorizations:
query Parameters
unit_type
string (UnitTypes)
Value: "CURRENCY"
unit
string
page
integer <int32> >= 1
Default: 1

Page number.

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page.

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Mobile-Number

The Look Up endpoint are designed to enhance the discovery of mobile products by resolving mobile phone numbers to their respective mobile operators. This is achieved using DT One's proprietary algorithm and logic. The service plays a vital role in reducing failed transactions by validating the MSISDN and identifying the correct operator.

💡 It's important to offer end users the option to make a final operator selection. In rare instances, the results returned from a lookup request may not reflect the most current information, especially if there has been a recent porting of the mobile number to a new operator. This additional step ensures accuracy and improves the overall user experience.

Look up operators for a given mobile number

Authorizations:
Request Body schema: application/json
mobile_number
required
string (E164) ^\+[1-9][0-9]{6,14}$

Mobile number in E.164 format.

page
integer <int32> >= 1
Default: 1

Page number

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page

Responses

Request samples

Content type
application/json
{
  • "mobile_number": "string",
  • "page": 1,
  • "per_page": 50
}

Response samples

Content type
application/json
[
  • {
    }
]

Statement-Inquiry

Inquire statements for a given account number

Authorizations:
Request Body schema: application/json
product_id
required
integer <int32> (ProductID) >= 1

Product identifier.

account_number
required
string (AccountNumber) [ 1 .. 90 ] characters \S

Account number.

account_qualifier
string (NonEmptyString) non-empty \S
page
integer <int32> >= 1
Default: 1

Page number

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page

Responses

Request samples

Content type
application/json
{
  • "product_id": 1,
  • "account_number": "string",
  • "account_qualifier": "string",
  • "page": 1,
  • "per_page": 50
}

Response samples

Content type
application/json
[
  • {
    }
]

Credit-Party

Retrieve remaining product benefits for a given credit party

Authorizations:
Request Body schema: application/json
service_id
required
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details.

required
object
page
integer <int32> >= 1
Default: 1

Page number

per_page
integer <int32> [ 1 .. 100 ]
Default: 50

Number of records per page

Responses

Request samples

Content type
application/json
{
  • "service_id": 1,
  • "credit_party_identifier": {
    },
  • "page": 1,
  • "per_page": 50
}

Response samples

Content type
application/json
[
  • {
    }
]

Retrieve status for a given credit party

Authorizations:
Request Body schema: application/json
service_id
required
integer <int32> (ServiceID) >= 1

Service identifier. See Services for more details.

required
object

Responses

Request samples

Content type
application/json
{
  • "service_id": 1,
  • "credit_party_identifier": {
    }
}

Response samples

Content type
application/json
{
  • "installation_date": "2019-08-24T14:15:22Z",
  • "activation_date": "2019-08-24T14:15:22Z"
}