Skip to main content
POST
/
contracts
/
subscription
/
initSubscription
Initiate a subscription
curl --request POST \
  --url https://mainnet.gomaestro-api.org/v1/contracts/subscription/initSubscription \
  --header 'Content-Type: application/json' \
  --header 'api-key: <api-key>' \
  --data '{
  "service_nft_tn": "<string>",
  "account_nft_tn": "<string>",
  "subscription_fee": {
    "policy_id": "<string>",
    "asset_name": "<string>"
  },
  "total_subscription_fee": "<string>",
  "subscription_start": "<string>",
  "subscription_end": "<string>",
  "interval_length": "<string>",
  "interval_amount": "<string>",
  "num_intervals": "<string>",
  "last_claimed": "<string>",
  "penalty_fee": {
    "policy_id": "<string>",
    "asset_name": "<string>"
  },
  "penalty_fee_qty": "<string>",
  "minimum_ada": "<string>"
}'
{
  "cbor_hex": "<string>",
  "tx_hash": "<string>"
}

Authorizations

api-key
string
header
required

Project API Key

Body

application/json
service_nft_tn
string
required

Service NFT token name

account_nft_tn
string
required

Account NFT token name

subscription_fee
object
required
total_subscription_fee
string
required

Total subscription fee

subscription_start
string
required

Subscription start timestamp

subscription_end
string
required

Subscription end timestamp

interval_length
string
required

Length of the interval

interval_amount
string
required

Amount per interval

num_intervals
string
required

Number of intervals

last_claimed
string
required

Last claimed timestamp

penalty_fee
object
required
penalty_fee_qty
string
required

Quantity of the penalty fee

minimum_ada
string
required

Minimum ADA required

Response

Subscription initiated successfully

Unsigned transaction

cbor_hex
string
required

CBOR hexadecimal representation of the transaction

tx_hash
string
required

Transaction hash

I