Services

Create a service order

Create a service order from the customer portal.

Customer authentication only. This endpoint must be called with customer authentication; administrators are not allowed to use it.

The order is created for the authenticated customer or, when sub_id is provided, for one of the customer's own direct sub-accounts (the sub-account must belong to the authenticated customer).

Order types

  • order - place a plain order without any payment.

  • order_with_payment - place an order and pay it through a payment gateway. Field entry_point_id is required and must reference an available payment entry point. The response returns a payment_url to open (for example in a WebView) where the customer completes the payment.

  • order_with_account_balance - place an order and pay it immediately from the customer's account balance.

Services

Field services is the list of services to order. Each item has a type (internet, voice, recurring, bundle or one_time) and an id (the tariff id). Every requested tariff must belong to the customer's orderable set - it must be visible on the customer portal and match the customer's billing type.

Notes

  • A sub-account may place only a plain order for itself and cannot pay.

  • When the partner setting "Accept payment via payment gateway" is enabled, a non-zero order for a main (non-aggregated) account must be paid: use order_with_payment with an entry_point_id, or order_with_account_balance.

  • entry_point_id is used only with order_with_payment and must not be sent with the other order types.

  • For an aggregated sub-account order the response additionally contains is_aggregated, indicating the order is created in the "On main approve" state and awaits the main account's approval.

post/portal/services/order

Request

  • Base URL: https://demo.splynx.com/api/2.0
  • URL: https://demo.splynx.com/api/2.0/portal/services/order
  • Auth: HTTP basic

Request body

type'order' | 'order_with_payment' | 'order_with_account_balance' required

Order type.

sub_idinteger

Optional. A direct sub-account of the authenticated customer to create the order for. When omitted, the order is created for the authenticated customer.

entry_point_idinteger

Payment entry point id. Required and used only for the order_with_payment type; must not be sent for other order types.

notestring

Optional note attached to the order.

Response

Order created.

For the order and order_with_account_balance types the response contains result, the order id and the order price. For the order_with_payment type the response contains order_id and payment_url.

Changes

No recorded changes to this operation across all 1 revision of this API.