Skip to main content

SubscriptionPayment

Makes a subscription payment to a service provider for a specific plan. The recipient is automatically set to the service provider.

Request

POST /nxt?requestType=subscriptionPayment

All endpoints use port 22024 by default.

Parameters

NameTypeDescriptionRequired
serviceIdstringSubscription service IDYes
planstringPlan name (must match an existing plan)Yes
amountQNTstringAmount in QNT (must match the plan amount)Yes
secretPhrasestringSubscriber's secret passphraseYes

Response

{
"transaction": "1234567890123456789",
"fullHash": "abc123def456...",
"errorCode": 0,
"errorDescription": ""
}

Example

curl -X POST "http://localhost:22024/nxt?requestType=subscriptionPayment" \
-d "serviceId=9876543210123456789" \
-d "plan=Basic" \
-d "amountQNT=100000000" \
-d "secretPhrase=your_secret_passphrase"