Documentation and example of Digital Virgo Direct Carrier Billing.
Following this guide your app will be technically enabled to be promoted and integrated with Digital Virgo mobile payment.
After the integration of the sdk the resultant app can check if the user coming from Digital Virgo acquisition (optionally with explicit login with msdisdn+pin) and can check expiration date and several information.
Add package from "File" → "Add Packages..." → "Search or Enter Package URL"
Under "Dependency Rule" select "Up to Next Major Version" and input "5.0.1"
Press the "Add Package" button
Wait for package fetching
Verify that "DCBApiExtSDKPackage" is checked and select the target to add the package
Press the "Add Package" button
Two extra package dependencies will be automatically imported: "DCBApiExtSDK" and "NewtonSDK"
In the application target, under "Frameworks, Libraries, and Embedded Content" verify the presence of the "DCBApiExtSDKPackage" library
To use Direct Carrier Billing by Digital Virgo, use the following code.
let client = DCBApiClient(baseDomain: URL(string:"<FINGERPRINT_DOMAIN>")!,
confInfoDomain: URL(string:"<SERVICE_DOMAIN>")!,
apikey: "<YOUR_APIKEY>",
catalog: "<YOUR_CATALOG>",
country: "<YOUR_COUNTRY>",
namespace: "<YOUR_NAMESPACE>")
DCBUserManager(client: client).checkFlowDCB(isActive: false) { date, error in
if let dcbUser = DCBUserManager.dcbUser {
//User is recognised as Digital Virgo Acquisition
if let date = date {
//User is subscribed
} else {
//User expired, not subscribed
//user must pay again to access the product
}
} else {
//Normal user discover the app from AppStore
}
}
Hooray! You've finished the integration!
For further assistance, please get in touch with the Team by dropping an email to [email protected]
link |
Stars: 1 |
Last commit: 1 year ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics