to navigate · to open See all results
PUT /api/v1/subscriptions/{record}/billing

Update subscription billing

Update billing values and record a billing-change event.

Last updated

Request

PUT /api/v1/subscriptions/{record}/billing

Requires subscriptions:update. See token permissions. Every listed permission is required for this endpoint.

Send Authorization: Bearer YOUR_API_TOKEN and Accept: application/json. Send request bodies as JSON with Content-Type: application/json. This workflow write requires Idempotency-Key. Reuse the same key only when retrying the same action.

record is the numeric subscription ID in your token’s organization.

Request body

Field Type Usage
event_date string Optional. ISO 8601 timestamp with seconds and an explicit offset, such as 2026-09-01T10:30:00-07:00. Defaults to now.
description string or null Optional. Plain text, up to 10,000 characters.
price_model string Required. lump_sum or per_license.
cost number Required. 0–999,999,999.99.
billing_frequency string Required. Recurring: monthly, Quarterly, or yearly. Purchase: upfront.
license_count integer or null Required for per-license pricing; otherwise optional and nullable. 1–100,000,000.

Fetch available values before choosing IDs. IDs and required fields vary by organization.

Example

Set ASSETCENTER_API_TOKEN as described in the quick start. Replace example record and option IDs with values from your organization. Set IDEMPOTENCY_KEY to a new UUID for this action; keep it for retries.

cURL / Bash
curl --request PUT "https://my.assetcenter.app/api/v1/subscriptions/123/billing" \
  --header "Authorization: Bearer $ASSETCENTER_API_TOKEN" \
  --header "Accept: application/json" \
  --header "Content-Type: application/json" \
  --header "Idempotency-Key: $IDEMPOTENCY_KEY" \
  --data '{"price_model":"per_license","cost":12,"billing_frequency":"monthly","license_count":10}'

Response

200 OK. Illustrative response structure. Event arrays, to-do/space values, and current state depend on the action and the record.

JSON
{
  "data": {
    "subscription_id": 123,
    "subscription_event_ids": [
      901
    ],
    "todo": null,
    "state": {
      "status": "available",
      "billing_type": "subscription",
      "license_count": 10,
      "billing_frequency": "monthly",
      "price_model": "per_license",
      "cost": "12.00",
      "contract_term": null,
      "contract_start_date": null,
      "contract_end_date": null
    }
  }
}

Behavior and constraints

State changes reject future timestamps (422) and dates preceding newer relevant state changes (409). Omit event_date to use now. Free subscriptions have no billing and return 409. Restore final subscriptions before changing billing. The billing type cannot be changed. Each accepted billing action records history; retries with the same key replay it.

Errors

401 means the token is missing, expired, revoked, or not a customer API token. 403 means a required permission or administrator access is missing. 404 means the record or child record is unavailable in this organization. 422 identifies invalid or unsupported input; inspect the errors object when present. 409 indicates a conflicting state or concurrent change; inspect the message and refresh the record before deciding how to proceed. Reusing an idempotency key with a different method, path, or body also returns 409. 429 means a rate limit was reached. See error handling and rate limits.