Create billing structures for an SKU object

A SKU's price schedule is an array of price objects. Each object defines a single charge: when it fires, how much it costs, and whether it repeats. By combining multiple price objects in one array, you can model any billing structure: one-time sales, free trials, introductory pricing, recurring subscriptions, and bundles.


Price object fields

Parameter

Description

title

Contains product/service name

offset
offset = 0d
offset = Xd

Defines by how long the transaction will be delayed.
0d - transaction will be concluded right away.
offset = Xd- transaction will be delayed by X days

amount

Charge amount

currency

Currency code in ISO 4217 format (e.g. "USD", "EUR")

repeat
repeat = true
repeat = false

Defines if the transaction will be repeated and if yes, defines the number of repeats.
repeat = true - defines recurring payments (transaction will be repeated indefinitely).
repeat = numeric_value - defines the number of times the transaction will be repeated, then stops.
repeat = false - defines non-recurring payments (transaction won't be repeated)

beforeTaxes

Amount before taxes are applied

afterTaxes

Amount including taxes

taxes

Tax amount

taxRate

Tax rate as a decimal (e.g. 0.2 for 20%)

taxName

Tax name (e.g. "VAT")

Examples

One-time 1 USD sale

{
    "sku": {
      "siteId": "12345",
      "title": "One-time 1 USD sale",
      "price": [
        {
          "offset": "0d",
          "amount": 1,
          "currency": "USD",
          "repeat": false
        }
      ]
    }
  }

Recurring charge of 1 USD every 30 days

The first entry charges immediately on sign-up. The second entry starts the recurring cycle 30 days later.

{
    "sku": {
      "siteId": "12345",
      "title": "Recurring 1 USD every 30 days",
      "price": [
        {
          "offset": "0d",
          "amount": 1,
          "currency": "USD",
          "repeat": false
        },
        {
          "offset": "30d",
          "amount": 1,
          "currency": "USD",
          "repeat": true
        }
      ]
    }
  }

Bundle purchase: recurring payment every month + one-time sale

Pass an array of SKU objects to charge for multiple products in a single request. Each SKU can have its own siteId and price schedule.

{
    "sku": [
        {
            "siteId": "12345",
            "title": "Recurring 1 USD every 30 days",
            "price": [
                {
                    "amount": 1,
                    "currency": "USD",
                    "offset": "0d",
                    "repeat": false
                },
                {
                    "amount": 1,
                    "currency": "USD",
                    "offset": "30d",
                    "repeat": true
                }
            ],
            
        },
        {
           "siteId": "67890",
            "title": "One-time 5 USD sale",
            "price": [
                {
                    "amount": 5,
                    "currency": "USD",
                    "offset": "0d",
                    "repeat": false
                }
            ],
        }
    ]
}

One-time 1 USD authorization (delayed captured after 3 days)

The charge fires 3 days after sign-up. Use this pattern when you want to authorise the card immediately but delay the actual capture.

{
    "sku": {
      "siteId": "12345",
      "title": "One-time 1 USD authorize (captured after 3 days)",
      "price": [
        {
          "offset": "3d",
          "amount": 1,
          "currency": "USD",
          "repeat": false
        }
      ]
    }
  }

Free trial for 3 days + recurring 1 USD every month

The first charge fires after 3 days (the trial period). The recurring charge starts 30 days after that.

{
    "sku": {
      "siteId": "12345",
      "title": "Free trial for 3 days, then recurring 1 USD every 30 days",
      "price": [
        {
          "offset": "3d",
          "amount": 1,
          "currency": "USD",
          "repeat": false
        },
        {
          "offset": "30d",
          "amount": 1,
          "currency": "USD",
          "repeat": true
        }
      ]
    }
  }

One-time 10 USD sale with 20% VAT

 {
    "sku": {
      "siteId": "12345",
      "title": "One-time 10 USD sale with 20% VAT",
      "price": [
        {
          "offset": "0d",
          "beforeTaxes": 10,
          "afterTaxes": 12,
          "taxes": 2,
          "taxRate": 0.2,
          "taxName": "VAT",
          "currency": "USD",
          "repeat": false
        }
      ]
    }
  }

Fixed number of billing cycles

Use a numeric value for repeat to charge a fixed number of times. This example charges $22 per month for 12 months, then stops.

{
  "sku": {
    "siteId": "12345",
    "title": "$22 per month for 12 months",
    "price": [
      {
        "offset": "0d",
        "amount": 22,
        "currency": "USD",
        "repeat": false
      },
      {
        "offset": "30d",
        "amount": 22,
        "currency": "USD",
        "repeat": 12
      }
    ]
  }
}

Note: Centrobill counts billing cycles in days only. There is no separate max_cycles parameter. A finite-term subscription is defined entirely through the price schedule: set repeat to the number of charges you want, and size the offset to match your billing interval.

Card verification (zero amount transaction)

Use a zero-amount charge to verify a card without capturing any funds.

 {
    "sku": {
      "siteId": "12345",
      "title": "Card verification",
      "price": [
        {
          "offset": "0d",
          "amount": 0,
          "currency": "USD",
          "repeat": false
        }
      ]
    }
  }