API Documentation
Paytring Checkout Payment
Merchant Hosted Checkout Payment
Subscription Management
Payout Management
Settlement Management
Vendor Management
Subscription Management
Fetch Subscription
POST
/
api
/
v1
/
subscription
/
subscription
/
fetch
Copy
curl --request POST \
--url https://api.paytring.com/api/v1/subscription/subscription/fetch \
--header 'Content-Type: application/json' \
--data '{
"key": "<string>",
"id": "<string>",
"hash": "<string>"
}'
Copy
"{\n \"status\": true,\n \"subscription\": {\n \"subscription_id\": \"677361288237548476\",\n \"mer_reference_id\": \"TXN934579\",\n \"amount\": 500,\n \"initial_amount\": null,\n \"currency\": \"USD\",\n \"subscription_status\": \"active\",\n \"pg\": \"Transactbridge\",\n \"customer\": {\n \"name\": \"Preetam Sharma\",\n \"email\": \"preetam@paytring.com\",\n \"phone\": \"7027445661\"\n },\n \"notes\": {\n \"udf1\": \"\",\n \"udf2\": \"\",\n \"udf3\": \"\",\n \"udf4\": \"\",\n \"udf5\": \"\",\n \"udf6\": \"\",\n \"udf8\": \"\",\n \"udf9\": \"\",\n \"udf10\": \"\"\n },\n \"billing_address\": {\n \"firstname\": \"FirstName\",\n \"lastname\": \"LastName\",\n \"phone\": \"9999999999\",\n \"line1\": \"\",\n \"line2\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"country\": \"\",\n \"zipcode\": \"\"\n },\n \"shipping_address\": {\n \"firstname\": \"FirstName\",\n \"lastname\": \"LastName\",\n \"phone\": \"9999999999\",\n \"line1\": \"\",\n \"line2\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"country\": \"\",\n \"zipcode\": \"\"\n }\n },\n \"request_id\": \"66ebdb6678097\"\n}"
This API is used to fetch details of an existing subscription.
Request Body
Copy
{
"subscription_id": "string", // ID of the subscription to fetch
"hash": "string" // Calculated hash for request validation
}
Responses
200 OK
Copy
{
"status": true,
"subscription": {
"id": "string",
"status": "string",
"plan": {
"id": "string",
"name": "string",
"amount": "integer",
"currency": "string",
"interval": "string"
}
},
"message": "Subscription fetched successfully"
}
400 Bad Request
Copy
{
"status": false,
"error": {
"message": "Invalid request",
"code": 400
}
}
Body
application/json
Response
200
application/json
200
The response is of type object
.
Copy
curl --request POST \
--url https://api.paytring.com/api/v1/subscription/subscription/fetch \
--header 'Content-Type: application/json' \
--data '{
"key": "<string>",
"id": "<string>",
"hash": "<string>"
}'
Copy
"{\n \"status\": true,\n \"subscription\": {\n \"subscription_id\": \"677361288237548476\",\n \"mer_reference_id\": \"TXN934579\",\n \"amount\": 500,\n \"initial_amount\": null,\n \"currency\": \"USD\",\n \"subscription_status\": \"active\",\n \"pg\": \"Transactbridge\",\n \"customer\": {\n \"name\": \"Preetam Sharma\",\n \"email\": \"preetam@paytring.com\",\n \"phone\": \"7027445661\"\n },\n \"notes\": {\n \"udf1\": \"\",\n \"udf2\": \"\",\n \"udf3\": \"\",\n \"udf4\": \"\",\n \"udf5\": \"\",\n \"udf6\": \"\",\n \"udf8\": \"\",\n \"udf9\": \"\",\n \"udf10\": \"\"\n },\n \"billing_address\": {\n \"firstname\": \"FirstName\",\n \"lastname\": \"LastName\",\n \"phone\": \"9999999999\",\n \"line1\": \"\",\n \"line2\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"country\": \"\",\n \"zipcode\": \"\"\n },\n \"shipping_address\": {\n \"firstname\": \"FirstName\",\n \"lastname\": \"LastName\",\n \"phone\": \"9999999999\",\n \"line1\": \"\",\n \"line2\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"country\": \"\",\n \"zipcode\": \"\"\n }\n },\n \"request_id\": \"66ebdb6678097\"\n}"
Assistant
Responses are generated using AI and may contain mistakes.