# New Order API

### Glossary <a href="#neworderapi-glossary" id="neworderapi-glossary"></a>

***

**cart** — new cart. Each client has one shopping cart for each provider. For example, a client belongs to one provider, therefore it has one shopping cart and all items the client orders go into that cart.

**lineitem.id** — new cart item.

**order** — one or more items from the cart, for which a payment is created.

### Adding an item to cart <a href="#neworderapi-addinganitemtocart" id="neworderapi-addinganitemtocart"></a>

***

The API of a new order is similar to the API of the old order, so the values of addons and parameters are passed in the same way, whereas additional and differing parameters are described in the table below.

![](https://docs.ispsystem.com/b6c/_/52CAAA2D0185156271C3945E71D8B19F/1713408684252/images/common/info-macro-icon.svg)

For SSL and Domain product types, use functions like **"{ITEMTYPE}.order.param".** To add these services to the cart via API using quick order, use the old order API with parameters **"clicked\_button=quickbasket"** and **"force\_use\_new\_cart=on".**

| Name                          | Description                                                                                               | Meaning                                                                                                                                                                                                                                                                                                                                                                        | Example                                                                                       |
| ----------------------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------- |
| func \*                       | Order function                                                                                            | <p>v2.{ITEMTYPE}.order.param</p><p>{ITEMTYPE} — internal product type name</p>                                                                                                                                                                                                                                                                                                 | <p>func=v2.soft.order.param</p><p>func=v2.vds.order.param</p><p>func=v2.dedic.order.param</p> |
| order\_period \*              | Order period                                                                                              | <p>Assumes one of the following values:</p><ul><li>1 — month</li><li>3 — 3 months</li><li>6 — 6 months</li><li>12 — year</li><li>24 — 2 years</li><li>36 — 3 years</li></ul>                                                                                                                                                                                                   | order\_period=1                                                                               |
| pricelist \*                  | Tariff ID                                                                                                 | Integer                                                                                                                                                                                                                                                                                                                                                                        | pricelist=111                                                                                 |
| sok \*                        | Confirm the operation                                                                                     | ok                                                                                                                                                                                                                                                                                                                                                                             | sok=ok                                                                                        |
| clicked\_button \*            | Operation subtype                                                                                         | order                                                                                                                                                                                                                                                                                                                                                                          | clicked\_button=order                                                                         |
| autoprolong                   | <p>Enable auto-renewal</p><p>Flag</p>                                                                     | <p>Assumes one of the following values:</p><ul><li>on</li><li>off</li></ul>                                                                                                                                                                                                                                                                                                    | autoprolong=on                                                                                |
| datacenter                    | ID of the data center where the service will be opened                                                    | Integer                                                                                                                                                                                                                                                                                                                                                                        | datacenter=2                                                                                  |
| force\_use\_new\_cart         | <p>Enable use of the new shopping cart</p><p>Flag</p>                                                     | <p>Assumes one of the following values:</p><ul><li>on</li><li>off</li></ul>                                                                                                                                                                                                                                                                                                    | force\_use\_new\_cart=on                                                                      |
| out                           | Response format                                                                                           | <p>Assumes one of the following values:</p><ul><li>xml</li><li>xjson</li><li>devel</li><li>text</li></ul>                                                                                                                                                                                                                                                                      | out=xml                                                                                       |
| addon\_{ADDON\_PRICELIST\_ID} | Addon value                                                                                               | <p>The value depends on the setting of the addon in the tariff plan</p><p>Tariff addons are passed through the API via the addon\_ parameter. For example, addon\_5=10, where</p><ul><li>5 is the addon code,</li><li>10 - value.</li></ul><p>To find the addon code, enter <strong>Products</strong> → <strong>Tariff plan → Options →</strong> <strong>Id</strong> field</p> | addon\_12=126                                                                                 |
| skipbasket                    | <p>Enable payment for the service from the personal account without placing it in the cart</p><p>Flag</p> | <p>Assumes one of the following values:</p><ul><li>on</li><li>off</li></ul>                                                                                                                                                                                                                                                                                                    | skipbasket=on                                                                                 |

\* — mandatory parameter

Пример запроса добавления позиции в корзину:

```
curl -X POST -k https://billing.sclad.us/billmgr \
	-d 'authinfo=admin_login:admin_password' \
	-d 'su=client_login' \
	-d 'out=xml' \
	-d 'sok=ok' \
	-d 'force_use_new_cart=on' \
	-d 'func=v2.{ITEMTYPE}.order.param' \
	-d 'datacenter={DATACENTER_ID}' \
	-d 'pricelist={PRICELIST_ID}' \
	-d 'addon_{ADDON_PRICELIST_ID}={ADDON_VALUE}' \
	-d 'order_period={PERIOD}' \
	-d 'clicked_button=order'
```

Copy Example with values

```
curl -X POST -k https://billing.sclad.us/billmgr \
	-d 'authinfo=admin_login:admin_password' \
	-d 'su=client_login' \
	-d 'out=xml' \
	-d 'sok=ok' \
	-d 'force_use_new_cart=on' \
	-d 'func=v2.vds.order.param' \
	-d 'datacenter=1' \
	-d 'pricelist=2' \
	-d 'addon_2=10' \
	-d 'order_period=1' \
	-d 'clicked_button=order'
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://wiki.sclad.us/api-personal-cabinet/new-order-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
