SolKnife Collecting subscription payments API
The Collecting subscription payments API from SolKnife — 4 operation(s) for collecting subscription payments.
The Collecting subscription payments API from SolKnife — 4 operation(s) for collecting subscription payments.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/solknife-xyz:solknife-xyz-collecting-subscription-payments-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
description: 'Merchant API for SolKnife Gateway: Solana payment intents, subscription plans, customer subscriptions, and signed callbacks. Every response is a JSON envelope: { ok: true, data } on success, { ok: false, error: { code, message } } on failure.'
title: SolKnife Gateway Collecting subscription payments API
version: 1.0.0
servers:
- url: https://gate.solknife.xyz
tags:
- name: Collecting subscription payments
paths:
/api/subscriptions/due:
get:
description: Returns active or past due customer subscriptions whose active plan is ready for collection.
operationId: get/api/subscriptions/due
responses:
'200':
content:
application/json:
schema:
properties:
data:
description: Due customer subscriptions.
items:
type: object
type: array
ok:
const: true
type: boolean
required:
- ok
- data
type: object
description: Success.
'400':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: VALIDATION_ERROR or another request error.
'401':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'UNAUTHENTICATED: missing or invalid x-gateway-key.'
'409':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'CONFLICT: the request conflicts with an existing record. SUBSCRIPTION_STATE_CHANGED: another request changed the subscription first; read it again and retry.'
'500':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'INTERNAL_ERROR: unexpected server error.'
security:
- gatewayKey: []
summary: List due subscriptions
tags:
- Collecting subscription payments
x-operation-id-source: normalized
x-operation-id-original: get /api/subscriptions/due
/api/subscriptions/due/queue:
get:
description: Returns due collection worker items with subscription, plan, pullerWallet, collectTransactionPath, confirmPath, and pastDuePath.
operationId: get/api/subscriptions/due/queue
responses:
'200':
content:
application/json:
schema:
properties:
data:
description: Collection worker items.
items:
type: object
type: array
ok:
const: true
type: boolean
required:
- ok
- data
type: object
description: Success.
'400':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: VALIDATION_ERROR or another request error.
'401':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'UNAUTHENTICATED: missing or invalid x-gateway-key.'
'409':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'CONFLICT: the request conflicts with an existing record. SUBSCRIPTION_STATE_CHANGED: another request changed the subscription first; read it again and retry.'
'500':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'INTERNAL_ERROR: unexpected server error.'
security:
- gatewayKey: []
summary: Collection worker queue
tags:
- Collecting subscription payments
x-operation-id-source: normalized
x-operation-id-original: get /api/subscriptions/due/queue
/api/subscriptions/{subscriptionId}/transactions/collect:
post:
description: Returns an unsigned base64 transaction that collects the next due subscription payment. The signer must be the plan's puller wallet.
operationId: post/api/subscriptions/{subscriptionId}/transactions/collect
responses:
'200':
content:
application/json:
schema:
properties:
data:
type: object
properties:
message:
type: string
transaction:
type: string
description: Unsigned base64 Solana transaction for the wallet to sign.
required:
- message
- transaction
ok:
const: true
type: boolean
required:
- ok
- data
type: object
description: Success.
'400':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: VALIDATION_ERROR or another request error.
'401':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'UNAUTHENTICATED: missing or invalid x-gateway-key.'
'404':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: The resource does not exist for this merchant.
'409':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'CONFLICT: the request conflicts with an existing record. SUBSCRIPTION_STATE_CHANGED: another request changed the subscription first; read it again and retry.'
'500':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'INTERNAL_ERROR: unexpected server error.'
security:
- gatewayKey: []
summary: Collect subscription payment transaction
tags:
- Collecting subscription payments
parameters:
- in: path
name: subscriptionId
required: true
schema:
type: string
requestBody:
content:
application/json:
schema:
type: object
properties:
account:
type: string
required:
- account
required: true
x-operation-id-source: normalized
x-operation-id-original: post /api/subscriptions/{subscriptionId}/transactions/collect
/api/subscriptions/{subscriptionId}/past-due:
post:
description: Marks an active customer subscription PAST_DUE after the next billing date when the worker could not collect, and sends a subscription.past_due callback.
operationId: post/api/subscriptions/{subscriptionId}/past-due
responses:
'200':
content:
application/json:
schema:
properties:
data:
description: The past due customer subscription.
type: object
ok:
const: true
type: boolean
required:
- ok
- data
type: object
description: Success.
'400':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: VALIDATION_ERROR or another request error.
'401':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'UNAUTHENTICATED: missing or invalid x-gateway-key.'
'404':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: The resource does not exist for this merchant.
'409':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'CONFLICT: the request conflicts with an existing record. SUBSCRIPTION_STATE_CHANGED: another request changed the subscription first; read it again and retry.'
'500':
content:
application/json:
schema:
$ref: '#/components/schemas/ErrorEnvelope'
description: 'INTERNAL_ERROR: unexpected server error.'
security:
- gatewayKey: []
summary: Mark subscription past due
tags:
- Collecting subscription payments
parameters:
- in: path
name: subscriptionId
required: true
schema:
type: string
x-operation-id-source: normalized
x-operation-id-original: post /api/subscriptions/{subscriptionId}/past-due
components:
schemas:
ErrorEnvelope:
properties:
error:
properties:
code:
type: string
message:
type: string
required:
- code
- message
type: object
ok:
const: false
type: boolean
required:
- ok
- error
type: object
securitySchemes:
gatewayKey:
description: The Gateway API key returned by POST /api/merchants/register.
in: header
name: x-gateway-key
type: apiKey
externalDocs:
description: Integration docs
url: https://gate.solknife.xyz/docs