create_instance_contract_m
Summary
| API Name | create_instance_contract_m |
|---|---|
| Class | account_services_m |
| Update Version | 60 |
Description
Creates an instance contract that binds one or more specific plan instances on an account to a contractual commitment. Unlike universal contracts (which apply account-wide), instance contracts are tied to specific master (subscriptions) and/or supplemental (add-ons) plan instances. They define a minimum commitment term, early termination fees, and renewal behavior for just those plan instances.Use instance contracts when the commitment terms vary by subscription — for example, a customer might have a 12-month contract on their Enterprise plan but no contract on their add-on services. To create an account-wide contract instead, use create_acct_universal_contract_m. To cancel an instance contract, use cancel_instance_contract_m. To view all contracts on an account, use get_all_acct_contracts_m or get_instance_contract_m.
Inputs
| Name | Type | Length | Required | Description | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| client_no | long | 22 | Yes |
Aria-assigned unique identifier indicating the Aria client providing service to this account. |
||||||||||||||
| auth_key | string | 32 | Yes |
Aria-assigned unique key for authenticating the validity of the requestor. This key is passed with each method call. |
||||||||||||||
| acct_no | long | 22 | Yes |
Aria-assigned account identifier. This value is unique across all Aria-managed accounts. Alternative required field: client_acct_id |
||||||||||||||
| client_acct_id | string | 50 | Yes |
Client-defined account identifier. Alternative required field: acct_no |
||||||||||||||
| client_contract_id | string | 100 | No |
Client assigned unique contract identifier.. |
||||||||||||||
| type_no | long | 8 | Yes |
The type of contract end action to be enforced by this contract. Allowed values:
|
||||||||||||||
| length_months | long | 8 | Yes |
Note: This field is deprecated. Aria no longer supports length_months. |
||||||||||||||
| cancel_fee | double | 12 | No |
Fee to be charged if the plan instance is cancelled by the account holder. For a multi-plan contract, this will be applicable only when the last remaining plan instance is cancelled prior to the contract's end date. |
||||||||||||||
| create_comments | string | 300 | No |
CSR or API-provided comments provided at time of contract creation. |
||||||||||||||
| start_date | string | 10 | No |
Contract start date in yyyy-mm-dd format. Defaults to the current date if not specified. This field is required for a plan or contract with a future start date. |
||||||||||||||
| end_date | string | 10 | Yes |
End date of the date range covered by this line item in yyyy-mm-dd format. Alternative required field: duration_length or length_months |
||||||||||||||
| do_auto_discard | string | 5 | No |
Whether, upon creation of this contract, the system automatically discards any existing contracts in effect that cover the same plan or set of plans. Allowed values:
|
||||||||||||||
| cascade_action | string | 5 | No |
An indicator on the plan_instance associated to the contract should indicate if the cascade option was selected when the plan_instance was assigned to the contract. Allowed values:
|
||||||||||||||
| contract_plan_instances | object | Yes | ||||||||||||||||
| contract_rollover_custom_rates | object | No | ||||||||||||||||
| duration_type | long | 1 | No |
Indicator which determines whether the contract duration in length is based on months, weeks or days. Allowed values:
|
||||||||||||||
| duration_length | long | Yes |
The contract duration in length that the given contract will be in effect from the start date. Alternative required field: end_date or length_months |
|||||||||||||||
| renewal_duration_type | long | 1 | No |
Indicator which determines whether the contract renewal duration in length is based on months, weeks or days. Allowed values:
|
||||||||||||||
| renewal_duration_length | long | No |
The contract renewal duration in length that the given contract will be in effect from the renewal start date. Alternative field: renewal_end_date |
|||||||||||||||
| renewal_end_date | string | No |
Date on which the renewal contract ends. Date format is YYYY-MM-DD. For the new contract type '9-Renew contract with different duration', it is mandatory to pass the either the renewal_end_date or the renewal_duration_type and renewal_duration_length. If both are passed, renewal_duration_length will take the precedence over the renewal_end_date. Alternative field: renewal_duration_length |
contract_plan_instances fields
| Name | Type | Length | Required | Description |
|---|---|---|---|---|
| plan_instance_no | long | 22 | Yes |
The Master Subscription plan instance number. Alternative required field: client_plan_instance_id |
| client_plan_instance_id | string | 100 | Yes |
Unique client-defined identifier for the master plan instance. Alternative required field: plan_instance_no |
| rollover_plan_no | long | 22 | No |
Note that if the target rollover plan has a surcharge that has already been associated with this account, when the plan rollover occurs at the completion of this contract, the surcharge for this plan may be ignored (depending on the client parameter determining whether duplicate surcharges are permitted). The surcharge at the account level will remain in effect. Alternative field: rollover_client_plan_id |
| rollover_client_plan_id | string | 100 | No |
Note that if the target rollover plan has a surcharge that has already been associated with this account, when the plan rollover occurs at the completion of this contract, the surcharge for this plan may be ignored (depending on the client parameter determining whether duplicate surcharges are permitted). The surcharge at the account level will remain in effect. Alternative field: rollover_plan_no |
| rollover_rate_sched_no | long | 22 | No |
Pre-defined rate schedule to be used as the rollover rate schedule at the completion of the contract. Alternative field: rollover_client_rate_sched_id |
| rollover_client_rate_sched_id | string | 100 | No |
Client-defined ID of the pre-defined rate schedule to be used as the rollover rate schedule at the completion of the contract. Alternative field: rollover_rate_sched_no |
contract_rollover_custom_rates fields
| Name | Type | Length | Required | Description |
|---|---|---|---|---|
| custom_rate_plan_instance_no | long | 22 | No |
Plan instance for the new custom rate schedule to be used as rollover custom rate at the completion of the contract. Alternative field: custom_rate_client_plan_instance_id |
| custom_rate_client_plan_instance_id | string | 100 | No |
Unique client-defined identifier for the master plan instance. Alternative field: custom_rate_plan_instance_no |
| custom_rate_service_no | long | No |
Service number for the new custom rate Alternative field: custom_rate_client_service_id |
|
| custom_rate_client_service_id | string | 32 | No |
The client-defined service ID for the new custom rate. Alternative field: custom_rate_service_no |
| custom_rate_seq_no | long | 22 | No |
Sequence number for this line of the rate schedule |
| custom_rate_from_unit | double | 22 | No |
Tiered pricing, "FROM" unit |
| custom_rate_to_unit | double | 22 | No |
Tiered pricing, "TO" unit |
| custom_rate_per_unit | double | 12 | No |
Rate to charge per unit on this tier |
Outputs
| Name | Type | Length | Required | Description |
|---|---|---|---|---|
| error_code | long | No |
Aria-assigned error identifier. 0 indicates no error. |
|
| error_msg | string | No |
Description of any error that occurred. "OK" if there was no error. |
|
| contract_no | long | No |
Aria-assigned unique contract identifier |