Creates an On/Off component definition under the specified product family. An On/Off component can then be added and “allocated” for a subscription.
On/off components are used for any flat fee, recurring add on (think $99/month for tech support or a flat add on shipping fee).
For more information on components, see our documentation here.
If you have the new Catalog experience enabled, taxable components must include a non-blank tax_code. Sending "tax_code": "" returns 422.
The username is a Maxio Chargify API key and the password is x. Basic authentication works only with the US and EU environments, which connect to chargify.com directly. The Maxio API Gateway environment does not accept Basic authentication.
In: header
Either the product family's id or its handle prefixed with handle:
application/json
TypeScript Definitions
Use the request body type in TypeScript.
application/json
application/json
curl -X POST \ --url 'https://subdomain.chargify.com/product_families/PRODUCT_FAMILY_ID/on_off_components.json' \ -H 'Accept: application/json' \ -H 'Content-Type: application/json' \ -H 'Authorization: Bearer ACCESS_TOKEN' \ --data-raw '{ "on_off_component": { "name": "Annual Support Services", "description": "Prepay for support services", "taxable": true, "unit_price": "100.00", "display_on_hosted_page": true, "public_signup_page_ids": [ 320495 ] }}'