subscriptioncharge object

Properties of the subscription charge object

A subscription charge will be created for each billing cycle. The state of the previous subscription charge object will be transferred to the a new "pending" subscription charge. This enables a history of each charge back in time. New IDs are set for each new charge.

{
  /* id of object, set by upodi */
  "id": "guid",
  "amount": "decimal",
  "previousamount": "decimal",
  "nextchargedate": "datetime",
  "previouschargedate": "datetime",
  "subscription": "subscription object",
  "productplancharge": "productplancharge object",
  "customer": "customer object",
  "subscriptionid": "guid",
  /* set by upodi */
  "toggled" : "boolean",
  "productplanchargeid" : "guid",
  "customerid" : "guid",
  /* if set it will overwrite the price found on the Product Plan Charge */
  "unitprice" : "decimal",
  "currencycode" : "string",
  /* only returned on single-object GET calls */
  "discount": "object",
  "description" : "string",
  "invoiceid" : "guid",
  "invoice" : "invoice object",
  /* custom key, example a remote id */
  "refkey": "string", 
  "createdby" : "guid",
  "modifiedby" : "guid",
  /* draft=0,active=1,hold=2 */
  "statecode" : "integer",
  /* draft=0,active=1,inactive=7,deleted=1024 */
  "status" : "integer",
  /* set by upodi. the start of the charge period */
  "chargestartdate": "datetime",
  /* set by upodi. the start of the charge period */
  "chargeenddate": "datetime",
  /* set by upodi. useful when using metered to identify usagedata across recurring subscriptioncharges referring to the same productplancharge */
  "referenceid": "guid",
  /* set by upodi */
  "createddate": "datetime",
  /* set by upodi */
  "modifieddate": "datetime",
  "discount" : "discountsource object"
}