📬
MobiPay API Documentation
Mobivate
📬
MobiPay API Documentation
  • 👋Welcome to MobiPay
  • Send SMS via HTTP (MT)
  • Receive SMS via HTTP (MO)
  • Use Cases
    • Send SMS via HTTP (MT) Example
    • Receive SMS via HTTP (MO) Example
    • Gateway Responses
    • Send Silent OBS Billing Message Example
    • Unsubscribe VIA MT Unsubscribe Notification
    • Receive Delivery Receipt via HTTP (DR)
    • Acknowledging MO's and DR's
    • Send A Premium SMS via HTTP (MT) Example
    • Vodafone/Airtel Ghana Billing
  • API Message Paramaters
    • API Message Parameters
    • Send BINARY SMS (MT) parameters
    • Receive SMS (MO) parameters
    • Subscription API (RESTFul)
      • Initiate Subscription (API)
      • Validate PIN (API)
      • Unsubscribing Users (API)
      • Checking Subscription Status (API)
      • Sending Messages To Subscribers (API)
      • Sending Content To Subscribers (API)
    • Content API (RESTFul)
      • Content Types (API)
      • Content Categories (API)
      • Search Content (API)
      • Latest Content Items (API)
      • Content Items (API)
  • Network Double Opt-In
    • Network Double Opt-in (NDOI)
    • Network Double Opt-in (NDOI) Unsubscribe
    • NDOI Keyword Patterns per country
  • MNO Web Opt-in
    • MNO Web Opt-in Introduction
    • MNO Web Opt-In South Africa
    • MNO Web Opt-In Kenya
      • Configuring your campaign
      • Subscribing users to your service
        • Subscribing users via Upstream
        • Subscribing users via Scienlabs
      • Unsubscribing users from your service
      • Receiving callback notifications
    • MNO Web Opt-In Nigeria
      • Subscribing the User to the Service
      • Unsubscribing user from the Service
      • Delivery Notifications
  • UK Direct Carrier Billing
    • UK DCB/Charge to Bill
      • UK Network Flows
Powered by GitBook
On this page
  • GET /api/doi/<account_id>/<api_key>/
  • Asynchronous Final Notification

Was this helpful?

  1. Network Double Opt-In

Network Double Opt-in (NDOI)

Learn how to handle an NDOI request using our API.

GET /api/doi/<account_id>/<api_key>/

Initiate a network DOI subscription.

curl -XGET -H "Content-type: application/json" 'https://hostname/api/doi/<account_id>/<api_key>/?source=<shortcode>&destination=<msisdn>&keyword=<kw>&frequency=7&amount=100&campaign=Test&provider=<networkprovider>&reference=<your internal reference>'
import requests

headers = {
    'Content-type': 'application/json',
}

response = requests.get(
    'https://hostname/api/doi/<account_id>/<api_key>/?source=<shortcode>&destination=<msisdn>&keyword=<kw>&frequency=7&amount=100&campaign=Test&provider=<networkprovider>&reference=<your internal reference>',
    headers=headers,
)

Headers

Name
Value

Content-Type

application/json

Authorization

No Auth

Required Body

Parameter
Type
Example
Description

account_id

string

43e36f50aaf111e272639171000000a9

Your unique Mobivate account id.

api_key

string

3b41d767316541bacef19d1382ac1e12

Your unique associated Mobivate account api-key.

source

integer

12345

The associated shortcode for your service.

destination

integer

XX7432104492

The recipient you want to send this message to.

keyword

string

mv-100620006

Your unique Mobivate keyword for your service.

amount

integer

10

The amount your message will be billed for receiving.

reference

string

ABC1234

Your internal unique reference.

provider

string

safaricom

The network provider this message will be sent via.

Optional Body

Parameter
Type
Example
Description

campaign

string

87e36f50aaf113e272629971000000a3

Your unique Mobivate campaign id.

frequency

integer

7

Billing frequency, in this case 7 is weekly.

stop

string

stop

To indicate a user is being unsubscribed from your service.

Response

{
  "200": "MT-c65561314eb34088b6df42d8241aace0"
}
{
  "error": "541"
}

Asynchronous Final Notification

Asynchronous final notification will be delivered to your standard DR Path with codes:

Code
Description
Your action

540

DOI Confirmed by user

Continue with the subscription (ie. send welcome messages and content)

541

Message delayed while waiting for DOI

Existing NDOI exists. Please hold before retrying

542

Message rejected due to DOI

The user has not confirmed the NDOI yet. Please wait before retrying.

543

DOI Unconfirmed / Awaiting user action

The user has not confirmed the NDOI yet. Please wait before retrying.

544

DOI Declined by user

The user declined NDOI. You should wait for the user to initiate a request again.

545

DOI Failed

Network DOI failed. Try again or contact Mobivate support to investigate further.

PreviousContent Items (API)NextNetwork Double Opt-in (NDOI) Unsubscribe

Last updated 1 year ago

Was this helpful?

For a full list of response codes, please .

click here