Properties
| Name | Type | Description |
|---|---|---|
| object | string | |
| subscription_id | string | |
| switch_type | object | |
| execution_mode | object | |
| current_plan | object | |
| new_plan | object | |
| proration | object | |
| effective_date | string | Effective date |
| next_billing_date | string | Next billing date |
| proration_behavior | object | |
| requires_payment | boolean | Whether a payment is required |
| can_proceed | boolean | Whether the switch can be executed |
| blocking_reason | stringnull | Why the switch is blocked, when it cannot run |
| is_in_trial | boolean | Whether the subscription is in its trial |
| trial_end | stringnull | When the trial ends |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://artifacts.apis.io/recur-tw/json-schema/recur-tw-switch-preview-response-schema.json",
"title": "SwitchPreviewResponse",
"x-generated": "2026-11-23",
"x-method": "derived",
"x-generator": "derive-json-schema.py",
"x-source": "openapi/recur-tw-openapi.json#/components/schemas/SwitchPreviewResponse",
"type": "object",
"required": [
"object",
"subscription_id",
"switch_type",
"execution_mode",
"current_plan",
"new_plan",
"effective_date",
"next_billing_date",
"proration_behavior",
"requires_payment",
"can_proceed"
],
"properties": {
"object": {
"type": "string",
"enum": [
"switch_preview"
]
},
"subscription_id": {
"type": "string"
},
"switch_type": {
"$ref": "#/$defs/SwitchType"
},
"execution_mode": {
"$ref": "#/$defs/ExecutionMode"
},
"current_plan": {
"$ref": "#/$defs/PlanSummary"
},
"new_plan": {
"$ref": "#/$defs/PlanSummary"
},
"proration": {
"$ref": "#/$defs/ProrationDetails",
"nullable": true
},
"effective_date": {
"type": "string",
"format": "date-time",
"description": "Effective date"
},
"next_billing_date": {
"type": "string",
"format": "date-time",
"description": "Next billing date"
},
"proration_behavior": {
"$ref": "#/$defs/ProrationBehavior"
},
"requires_payment": {
"type": "boolean",
"description": "Whether a payment is required"
},
"can_proceed": {
"type": "boolean",
"description": "Whether the switch can be executed"
},
"blocking_reason": {
"type": [
"string",
"null"
],
"description": "Why the switch is blocked, when it cannot run"
},
"is_in_trial": {
"type": "boolean",
"description": "Whether the subscription is in its trial"
},
"trial_end": {
"type": [
"string",
"null"
],
"format": "date-time",
"description": "When the trial ends"
}
},
"$defs": {
"ExecutionMode": {
"type": "string",
"enum": [
"immediate",
"scheduled"
],
"description": "How the switch runs:\n- `immediate`: right away\n- `scheduled`: at the end of the billing period\n"
},
"PlanSummary": {
"type": "object",
"required": [
"product_id",
"product_name",
"amount",
"currency",
"interval",
"interval_count",
"monthly_equivalent"
],
"properties": {
"product_id": {
"type": "string",
"description": "Product ID"
},
"product_name": {
"type": "string",
"description": "Product name"
},
"amount": {
"type": "integer",
"description": "Price. TWD is a whole-number integer: 499 means NT$499, not cents"
},
"currency": {
"type": "string",
"description": "Currency"
},
"interval": {
"type": "string",
"enum": [
"day",
"week",
"month",
"year"
],
"description": "Billing interval"
},
"interval_count": {
"type": "integer",
"description": "Interval count"
},
"monthly_equivalent": {
"type": "integer",
"description": "Monthly equivalent, for comparison"
}
}
},
"ProrationBehavior": {
"type": "string",
"enum": [
"create_prorations",
"none",
"always_invoice"
],
"description": "Proration behavior:\n- `create_prorations`: create proration line items\n- `none`: no proration\n- `always_invoice`: always create an invoice\n"
},
"ProrationDetails": {
"type": "object",
"required": [
"credit_amount",
"charge_amount",
"net_amount",
"unused_days",
"total_days_in_period",
"credit_description"
],
"properties": {
"credit_amount": {
"type": "integer",
"description": "Credit for the unused days on the current plan"
},
"charge_amount": {
"type": "integer",
"description": "Charge for a full period on the new plan"
},
"net_amount": {
"type": "integer",
"description": "Net amount the customer pays"
},
"unused_days": {
"type": "integer",
"description": "Days remaining on the current plan"
},
"total_days_in_period": {
"type": "integer",
"description": "Total days in the billing period"
},
"credit_description": {
"type": "string",
"description": "Credit description"
}
}
},
"SwitchType": {
"type": "string",
"enum": [
"UPGRADE",
"DOWNGRADE",
"PERIOD_CHANGE",
"CROSSGRADE"
],
"description": "Switch type:\n- `UPGRADE`: to a higher-priced plan\n- `DOWNGRADE`: to a lower-priced plan\n- `PERIOD_CHANGE`: change the billing period, for example monthly to yearly\n- `CROSSGRADE`: to a different plan at the same price\n"
}
}
}
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.
Call it yourself
curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/recur-tw-switch-preview-response"
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. 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.