Curlec · Schema

Subscription

A recurring billing subscription linking a customer to a plan. Requires customer mandate authorization via short_url before charges can be collected.

CompanyPaymentsPayment GatewayRecurring PaymentsSubscriptionDirect DebitFintechMalaysiaDuitNowFPXWebhookRazorpayA2A

Properties

Name Type Description
id string Subscription ID. Prefix: sub_
entity string
plan_id string Associated plan ID (plan_*).
status string Subscription lifecycle status. created→authenticated (mandate authorized)→active→completed/cancelled/expired. pending=charge retry scheduled; halted=multiple failures; paused=temporarily stopped.
current_start integer Unix timestamp of current billing cycle start.
current_end integer Unix timestamp of current billing cycle end.
ended_at integer Unix timestamp when subscription ended (cancelled/completed/expired).
quantity integer Number of plan units billed per cycle.
notes object
charge_at integer Unix timestamp of next scheduled charge attempt.
start_at integer Unix timestamp of first charge. Defaults to subscription creation time.
end_at integer Unix timestamp after which no more charges will be attempted.
auth_attempts integer Number of mandate authorization attempts.
total_count integer Total billing cycles. 0 = indefinite.
paid_count integer Number of billing cycles successfully charged.
remaining_count integer Remaining billing cycles.
customer_notify integer 1 = Razorpay sends SMS/email notifications to customer on each charge.
short_url string Mandate authorization URL. Must be sent to the customer to activate the subscription.
has_scheduled_changes boolean True if a plan/quantity change is scheduled for the next cycle.
change_scheduled_at string When scheduled changes take effect.
source string Source that created the subscription (e.g., api, dashboard).
offer_id string Offer/coupon applied to the subscription.
expire_by integer Unix timestamp by which the customer must authorize the mandate.
created_at integer
View JSON Schema on GitHub

JSON Schema

curlec-subscription-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/curlec/json-schema/curlec-subscription-schema.json",
  "title": "Subscription",
  "description": "A recurring billing subscription linking a customer to a plan. Requires customer mandate authorization via short_url before charges can be collected.",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/curlec-subscriptions-api-openapi.yml#/components/schemas/Subscription",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Subscription ID. Prefix: sub_"
    },
    "entity": {
      "type": "string",
      "enum": [
        "subscription"
      ]
    },
    "plan_id": {
      "type": "string",
      "description": "Associated plan ID (plan_*)."
    },
    "status": {
      "type": "string",
      "enum": [
        "created",
        "authenticated",
        "active",
        "pending",
        "halted",
        "cancelled",
        "completed",
        "expired",
        "paused"
      ],
      "description": "Subscription lifecycle status. created→authenticated (mandate authorized)→active→completed/cancelled/expired. pending=charge retry scheduled; halted=multiple failures; paused=temporarily stopped."
    },
    "current_start": {
      "type": "integer",
      "description": "Unix timestamp of current billing cycle start."
    },
    "current_end": {
      "type": "integer",
      "description": "Unix timestamp of current billing cycle end."
    },
    "ended_at": {
      "type": "integer",
      "description": "Unix timestamp when subscription ended (cancelled/completed/expired)."
    },
    "quantity": {
      "type": "integer",
      "default": 1,
      "description": "Number of plan units billed per cycle."
    },
    "notes": {
      "$ref": "#/$defs/Notes"
    },
    "charge_at": {
      "type": "integer",
      "description": "Unix timestamp of next scheduled charge attempt."
    },
    "start_at": {
      "type": "integer",
      "description": "Unix timestamp of first charge. Defaults to subscription creation time."
    },
    "end_at": {
      "type": "integer",
      "description": "Unix timestamp after which no more charges will be attempted."
    },
    "auth_attempts": {
      "type": "integer",
      "description": "Number of mandate authorization attempts."
    },
    "total_count": {
      "type": "integer",
      "description": "Total billing cycles. 0 = indefinite."
    },
    "paid_count": {
      "type": "integer",
      "description": "Number of billing cycles successfully charged."
    },
    "remaining_count": {
      "type": "integer",
      "description": "Remaining billing cycles."
    },
    "customer_notify": {
      "type": "integer",
      "enum": [
        0,
        1
      ],
      "description": "1 = Razorpay sends SMS/email notifications to customer on each charge."
    },
    "short_url": {
      "type": "string",
      "description": "Mandate authorization URL. Must be sent to the customer to activate the subscription."
    },
    "has_scheduled_changes": {
      "type": "boolean",
      "description": "True if a plan/quantity change is scheduled for the next cycle."
    },
    "change_scheduled_at": {
      "type": "string",
      "enum": [
        "now",
        "cycle_end"
      ],
      "description": "When scheduled changes take effect."
    },
    "source": {
      "type": "string",
      "description": "Source that created the subscription (e.g., api, dashboard)."
    },
    "offer_id": {
      "type": "string",
      "description": "Offer/coupon applied to the subscription."
    },
    "expire_by": {
      "type": "integer",
      "description": "Unix timestamp by which the customer must authorize the mandate."
    },
    "created_at": {
      "type": "integer"
    }
  },
  "$defs": {
    "Notes": {
      "type": "object",
      "description": "Key-value pairs for storing custom metadata. Maximum 15 pairs. Each key and value must not exceed 256 characters.",
      "additionalProperties": {
        "type": "string"
      },
      "maxProperties": 15
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • 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.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/curlec-subscription"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API 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. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.