Quick start

API
Web
HTML
Java
Create a smooth subscription process by using Antom's payment capabilities. Antom offers client- and server-side sample code for APIs-only integration, to help you easily build a subscription experience that accepts various senarios.
1
Set up the server

Install the Antom Java library

Maven
GitHub
Server

Get integration resources

Get integration resources from the Developer section in Antom Dashboard. Configure the obtained integration resources in your application and these resources are to be further used when sending requests to the Antom server.
Server

Initiate a subscription request

On your server, add an endpoint to call the create API. When sending a subscription request, specify the subscription start time, subscription settlement time, cycle rules, subscription request ID, payment information, and other necessary subscription details.
Server
Set the subscription redirection URL where the buyer is to be redirected after completing the subscription.
Set a notification receiving URL, and the Antom server will send updates to the specified address throughout the subscription cycle, including an immediate notification for the first subscription.
Server

Receive payment notifications

Add an endpoint on your server to receive notifications from Antom's notifyPayment API, including payment results, payment time and payment amount, etc. You can update the payment status and save the information to your database for subsequent queries.
Server

Receive subscription notifications

Add an endpoint on your server to receive notifications from Antom's notifySubscription API, including the subscription status, subscription request ID, and subscription cycle rules. You can update the subscription status and save this information to your database for subsequent queries.
Server
2
Build a subscription page on the client

Build the subscription page

Display the products information that you offer to buyers on the subscription page.
Client
After the buyer selects products to subscript, you send a subscription request with the corresponding subscription information and obtain the authorization subscription continuation URL from the subscription creation response.
Client

Handle the redirection

Redirect the buyer to the authorized subscription continuation URL to complete the authorization.
Client

Obtain the subscription result

When the buyer completes the subscription payment, and is redirected to the subscription redirection URL, you can obtain the subscription status. You can also obtain the subscription status by polling the back-end for subscription result notifications.
Client
Download