Get
Subs API Get methods
API up ?
GET
https://api.subsprotocol.com/creator/status
This call is a good way to see if pur API is up and operational.
Path Parameters
appId*
String
App ID
chain*
String
Chain Name
Headers
x-api-key*
String
API Key
{
"status": "ok",
"timestamp": 1694528528826
}
Get Payment IDs for an App
GET
https://api.subsprotocol.com/creator/payments
Path Parameters
appId*
String
App ID
chain*
String
Chain Name
rpc*
String
Node Provider
Headers
x-api-key*
String
API Key
[
{
"paymentId": "0xdd346f6491955977a0f2ffdadd3efe4173e7ffd0404aaf4bb452ca5a78106dce",
"payment": {
"name": "5500 with 10 months",
"owner": "0xc11CB8898B06AE1Ec901Bd8624E4D3F93a78a584",
"fee": 0,
"paymentType": 0,
"paymentTokens": [
{
"token": "0xA02f6adc7926efeBBd59Fd43A84f4E0c0c91e832",
"price": "550000000000000000000",
"firstAmount": "825000000000000000000"
},
{
"token": "0x0FA8781a83E46826621b3BC094Ea2A0212e71B23",
"price": "550000000000000000000",
"firstAmount": "825000000000000000000"
},
{
"token": "0xd393b1E02dA9831Ff419e22eA105aAe4c47E1253",
"price": "550000000000000000000",
"firstAmount": "825000000000000000000"
}
],
"trialPeriod": 0,
"periodType": "MONTH",
"limitPeriod": 10,
"loadingTime": 3
}
]
Check user subscription for an App
GET
https://api.subsprotocol.com/creator/isMyUser
Path Parameters
appId*
String
App ID
chain*
String
Chain Name
user*
String
User Address
rpc*
String
Node Provider
Headers
x-api-key*
String
API Key
{
"isSubscribed": false,
"isTrial": false,
"paymentId": "0x0000000000000000000000000000000000000000000000000000000000000000",
"subId": "0x0000000000000000000000000000000000000000000000000000000000000000"
}
All subscribers for a specific App
GET
https://api.subsprotocol.com/creator/subs
Path Parameters
appId*
String
App ID
chain*
String
Chain Name
rpc*
String
Node Provider
Headers
x-api-key*
String
Api Key
[
{
"subsId": "0xdb09f6a1baeacf8e0d63953fcf09536bce633e5bda1d57c60bb392351439a211",
"payeeAddress": "0xD3C509e32983ffA469d48863CBBB275BD885E891",
"tokenAddress": "0x326C977E6efc84E512bB9C30f76E30c160eD06FB",
"PaymentName": "Premium",
"finalPay": 200000000000000,
"appId": 2,
"paymentId": "0x2182d817093e51c19d2776aa2eee9b2c72d8a529a3d9a63a321c1634f569d984",
"periodType": 5,
"periodMultiplier": 2592000,
"timePeriod": {
"nTimePaid": 1,
"limitPeriod": 36
},
"startTime": 1696281619,
"activeTrial": false,
"active": true,
"nextPaymentTime": 1698873619,
"renewTime": 1789593619
}
]
Subscribers of a specific payment of an App
GET
https://api.subsprotocol.com/creator/subsOfPayment
Path Parameters
appId*
String
App ID
chain*
String
Chain Name
rpc*
String
Node Provider
paymentID*
String
Payment ID
Headers
x-api-key*
String
API Key
[
{
"subsId": "0xdb09f6a1baeacf8e0d63953fcf09536bce633e5bda1d57c60bb392351439a211",
"payeeAddress": "0xD3C509e32983ffA469d48863CBBB275BD885E891",
"tokenAddress": "0x326C977E6efc84E512bB9C30f76E30c160eD06FB",
"PaymentName": "Premium",
"finalPay": 200000000000000,
"appId": 2,
"paymentId": "0x2182d817093e51c19d2776aa2eee9b2c72d8a529a3d9a63a321c1634f569d984",
"periodType": 5,
"periodMultiplier": 2592000,
"timePeriod": {
"nTimePaid": 1,
"limitPeriod": 36
},
"startTime": 1696281619,
"activeTrial": false,
"active": true,
"nextPaymentTime": 1698873619,
"renewTime": 1789593619
}
]
All the subscriptions for a specific User
GET
https://api.subsprotocol.com/creator/userSubs
Path Parameters
chain*
String
Chain Name
rpc*
String
Node Provider
user*
String
User Address
Headers
x-api-key*
String
API Key
[
{
"subsId": "0x9062f838b0d875f3d892694883f209878037ffe6e81019821286e0c06d1ca92d",
"appId": "2",
"paymentId": "0x2182d817093e51c19d2776aa2eee9b2c72d8a529a3d9a63a321c1634f569d984",
"token": "0x326C977E6efc84E512bB9C30f76E30c160eD06FB",
"owner": "0xD3C509e32983ffA469d48863CBBB275BD885E891",
"status": "active"
}
]
Last updated