Skip to content
  • Auto
  • Light
  • Dark
Talk to an expert

Contracts

Contracts

Contracts

Add a manual balance entry
v1.contracts.add_manual_balance_entry(ContractAddManualBalanceEntryParams**kwargs)
post/v1/contracts/addManualBalanceLedgerEntry
Amend a contract
v1.contracts.amend(ContractAmendParams**kwargs) -> dataIDContractAmendResponse
post/v1/contracts/amend
Archive a contract
v1.contracts.archive(ContractArchiveParams**kwargs) -> dataIDContractArchiveResponse
post/v1/contracts/archive
Create a contract
v1.contracts.create(ContractCreateParams**kwargs) -> dataIDContractCreateResponse
post/v1/contracts/create
Create historical invoices
v1.contracts.create_historical_invoices(ContractCreateHistoricalInvoicesParams**kwargs) -> datalistContractCreateHistoricalInvoicesResponse
post/v1/contracts/createHistoricalInvoices
List customer contracts (v1)
v1.contracts.list(ContractListParams**kwargs) -> datalistContractListResponse
post/v1/contracts/list
List balances
v1.contracts.list_balances(ContractListBalancesParams**kwargs) -> datalistnext_pagestrContractListBalancesResponse
post/v1/contracts/customerBalances/list
Get a contract (v1)
v1.contracts.retrieve(ContractRetrieveParams**kwargs) -> dataDataContractRetrieveResponse
post/v1/contracts/get
Get the rate schedule for a contract
v1.contracts.retrieve_rate_schedule(ContractRetrieveRateScheduleParams**kwargs) -> datalistnext_pagestrContractRetrieveRateScheduleResponse
post/v1/contracts/getContractRateSchedule
Get subscription quantity history
post/v1/contracts/getSubscriptionQuantityHistory
Schedule ProService invoice
v1.contracts.schedule_pro_services_invoice(ContractScheduleProServicesInvoiceParams**kwargs) -> datalistContractScheduleProServicesInvoiceResponse
post/v1/contracts/scheduleProServicesInvoice
Set a contract usage filter
v1.contracts.set_usage_filter(ContractSetUsageFilterParams**kwargs)
post/v1/contracts/setUsageFilter
Update the contract end date
v1.contracts.update_end_date(ContractUpdateEndDateParams**kwargs) -> dataIDContractUpdateEndDateResponse
post/v1/contracts/updateEndDate

ContractsNamed Schedules

Get a rate card's named schedule
v1.contracts.named_schedules.retrieve(NamedScheduleRetrieveParams**kwargs) -> datalistNamedScheduleRetrieveResponse
post/v1/contract-pricing/rate-cards/getNamedSchedule
Update a rate card's named schedule
v1.contracts.named_schedules.update(NamedScheduleUpdateParams**kwargs)
post/v1/contract-pricing/rate-cards/updateNamedSchedule

ContractsProducts

Archive a product
v1.contracts.products.archive(ProductArchiveParams**kwargs) -> dataIDProductArchiveResponse
post/v1/contract-pricing/products/archive
Create a product
v1.contracts.products.create(ProductCreateParams**kwargs) -> dataIDProductCreateResponse
post/v1/contract-pricing/products/create
List products
v1.contracts.products.list(ProductListParams**kwargs) -> SyncCursorPage[idstrcurrentProductListItemStateinitialProductListItemStatetypeliteralupdateslistarchived_atdatetimecustom_fieldsDict[str, str]ProductListResponse]
post/v1/contract-pricing/products/list
Get a product
v1.contracts.products.retrieve(ProductRetrieveParams**kwargs) -> dataDataProductRetrieveResponse
post/v1/contract-pricing/products/get
Update a product
v1.contracts.products.update(ProductUpdateParams**kwargs) -> dataIDProductUpdateResponse
post/v1/contract-pricing/products/update
Product List Item State
ProductListItemStateclass
ShowShow
created_atdatetime
formatdate-time
created_bystr
namestr
billable_metric_idstr
optional
composite_product_idslist
optional
Optional[List[str]]
composite_tagslist
optional
Optional[List[str]]
exclude_free_usagebool
optional
is_refundablebool
optional

This field's availability is dependent on your client's configuration.

netsuite_internal_item_idstr
optional

This field's availability is dependent on your client's configuration.

netsuite_overage_item_idstr
optional

This field's availability is dependent on your client's configuration.

presentation_group_keylist
optional
Optional[List[str]]

For USAGE products only. Groups usage line items on invoices. The superset of values in the pricing group key and presentation group key must be set as one compound group key on the billable metric.

pricing_group_keylist
optional
Optional[List[str]]

For USAGE products only. If set, pricing for this product will be determined for each pricing_group_key value, as opposed to the product as a whole. The superset of values in the pricing group key and presentation group key must be set as one compound group key on the billable metric.

quantity_conversionQuantityConversion
optional

Optional. Only valid for USAGE products. If provided, the quantity will be converted using the provided conversion factor and operation. For example, if the operation is "multiply" and the conversion factor is 100, then the quantity will be multiplied by 100. This can be used in cases where data is sent in one unit and priced in another. For example, data could be sent in MB and priced in GB. In this case, the conversion factor would be 1024 and the operation would be "divide".

quantity_roundingQuantityRounding
optional

Optional. Only valid for USAGE products. If provided, the quantity will be rounded using the provided rounding method and decimal places. For example, if the method is "round up" and the decimal places is 0, then the quantity will be rounded up to the nearest integer.

starting_atdatetime
optional
formatdate-time
tagslist
optional
Optional[List[str]]
Quantity Conversion
QuantityConversionclass

Optional. Only valid for USAGE products. If provided, the quantity will be converted using the provided conversion factor and operation. For example, if the operation is "multiply" and the conversion factor is 100, then the quantity will be multiplied by 100. This can be used in cases where data is sent in one unit and priced in another. For example, data could be sent in MB and priced in GB. In this case, the conversion factor would be 1024 and the operation would be "divide".

ShowShow
conversion_factorfloat

The factor to multiply or divide the quantity by.

operationliteral
Literal["MULTIPLY", "DIVIDE"]

The operation to perform on the quantity

Hide ParametersShow Parameters
"MULTIPLY"
"DIVIDE"
namestr
optional

Optional name for this conversion.

Quantity Rounding
QuantityRoundingclass

Optional. Only valid for USAGE products. If provided, the quantity will be rounded using the provided rounding method and decimal places. For example, if the method is "round up" and the decimal places is 0, then the quantity will be rounded up to the nearest integer.

ShowShow
decimal_placesfloat
minimum0
rounding_methodliteral
Literal["ROUND_UP", "ROUND_DOWN", "ROUND_HALF_UP"]
Hide ParametersShow Parameters
"ROUND_UP"
"ROUND_DOWN"
"ROUND_HALF_UP"

ContractsRate Cards

Archive a rate card
v1.contracts.rate_cards.archive(RateCardArchiveParams**kwargs) -> dataIDRateCardArchiveResponse
post/v1/contract-pricing/rate-cards/archive
Create a rate card
v1.contracts.rate_cards.create(RateCardCreateParams**kwargs) -> dataIDRateCardCreateResponse
post/v1/contract-pricing/rate-cards/create
List rate cards
v1.contracts.rate_cards.list(RateCardListParams**kwargs) -> SyncCursorPage[idstrcreated_atdatetimecreated_bystrnamestraliaseslistcredit_type_conversionslistcustom_fieldsDict[str, str]descriptionstrfiat_credit_typeCreditTypeDataRateCardListResponse]
post/v1/contract-pricing/rate-cards/list
Get a rate card
v1.contracts.rate_cards.retrieve(RateCardRetrieveParams**kwargs) -> dataDataRateCardRetrieveResponse
post/v1/contract-pricing/rate-cards/get
Get a rate schedule
v1.contracts.rate_cards.retrieve_rate_schedule(RateCardRetrieveRateScheduleParams**kwargs) -> datalistnext_pagestrRateCardRetrieveRateScheduleResponse
post/v1/contract-pricing/rate-cards/getRateSchedule
Update a rate card
v1.contracts.rate_cards.update(RateCardUpdateParams**kwargs) -> dataIDRateCardUpdateResponse
post/v1/contract-pricing/rate-cards/update

ContractsRate CardsNamed Schedules

Get a contract's named schedule
v1.contracts.rate_cards.named_schedules.retrieve(NamedScheduleRetrieveParams**kwargs) -> datalistNamedScheduleRetrieveResponse
post/v1/contracts/getNamedSchedule
Update a contract's named schedule
v1.contracts.rate_cards.named_schedules.update(NamedScheduleUpdateParams**kwargs)
post/v1/contracts/updateNamedSchedule

ContractsRate CardsProduct Orders

Set the rate card products order
v1.contracts.rate_cards.product_orders.set(ProductOrderSetParams**kwargs) -> dataIDProductOrderSetResponse
post/v1/contract-pricing/rate-cards/setRateCardProductsOrder
Update the rate card products order
v1.contracts.rate_cards.product_orders.update(ProductOrderUpdateParams**kwargs) -> dataIDProductOrderUpdateResponse
post/v1/contract-pricing/rate-cards/moveRateCardProducts

ContractsRate CardsRates

Add a rate
v1.contracts.rate_cards.rates.add(RateAddParams**kwargs) -> dataDataRateAddResponse
post/v1/contract-pricing/rate-cards/addRate
Add rates
v1.contracts.rate_cards.rates.add_many(RateAddManyParams**kwargs) -> dataIDRateAddManyResponse
post/v1/contract-pricing/rate-cards/addRates
Get rates
v1.contracts.rate_cards.rates.list(RateListParams**kwargs) -> SyncCursorPage[entitledboolproduct_custom_fieldsDict[str, str]product_idstrproduct_namestrproduct_tagslistrateRatestarting_atdatetimebilling_frequencyliteralcommit_rateCommitRateending_beforedatetimepricing_group_valuesDict[str, str]RateListResponse]
post/v1/contract-pricing/rate-cards/getRates