# Capturing the Terms of Sale (TOS) acceptance

Terms of Sale (TOS) outlines the agreed-upon conditions between the buyer and seller regarding purchasing goods or services. This document covers payment terms, delivery conditions, return policies, warranties, and liabilities. Accepting the TOS is often a mandatory step for the customer before finalizing a purchase, ensuring that both parties know their rights and obligations.

## Creating the TOS

To create the TOS, ensure that crucial sections such as payment terms, delivery conditions, return policies, warranties, and liabilities are included. Ensure that the TOS is clear, comprehensive, and easy to understand for customers. Accepting the TOS must be mandatory before the customer can finalize a purchase, ensuring clear agreement on the terms between both parties.

You can use a [DigitalRiver object](https://docs.digitalriver.com/commerce-api/resources/reference/digitalriver-object) provided by [DigitalRiver.js](https://docs.digitalriver.com/commerce-api/payments/payments-solutions/digitalriver.js) to create the TOS required by Digital River and [disclose the TOS through Drop-in payments](https://docs.digitalriver.com/commerce-api/payments/payments-solutions/drop-in/drop-in-integration-guide#show-terms-of-sale-disclosure).

## Setting the TOS acceptance parameter

To set the TOS acceptance parameter, include the `termsOfSalesAcceptance` field when [creating or updating a cart](https://docs.digitalriver.com/commerce-api/shopper-apis/cart/creating-or-updating-a-cart). This ensures that the customer explicitly accepts the Terms of Sale before proceeding. The parameter accepts a boolean value: `true` for acceptance and `false` for non-acceptance.&#x20;

The following cURL example shows how to set the `termsOfSalesAcceptance` when creating a cart:

{% tabs %}
{% tab title="cURL" %}

```http
curl --location --request POST 'https://api.digitalriver.com/v1/shoppers/me/carts/active' \
--header 'Content-Type:  application/json' \
--header 'authorization: Basic {Your_API_Key}\
--data-raw '{
  "cart": {
    "ipAddress": "10.24.2.28"
    "termsOfSalesAcceptance": "true"
  }
}'
```

{% endtab %}

{% tab title="201 Created response" %}
A `201 Created` response returns a Cart object:

```json
{
    "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active",
    "paymentMethods": {},
    "applyPaymentMethod": {},
    "submitCart": {},
    "webCheckout": {},
    "id": "47278010023",
    "lineItems": {},
    "totalItemsInCart": "1",
    "businessEntityCode": "DR_INC-ENTITY",
    "termsOfSalesAcceptance":"true"
    "billingAddress": {},
    "shippingAddress": {},
    "payment": {},
    "shippingOptions": {},
    "pricing": {}
}
```

{% endtab %}
{% endtabs %}

This `termsOfSalesAcceptance` parameter is mandatory for the [cart submission](https://docs.digitalriver.com/commerce-api/shopper-apis/cart/submitting-a-cart) process to confirm that the customer has accepted the TOS. The enumerated values are `true` or `false`.

You [capture when a customer accepts the TOS](https://app.gitbook.com/s/oUderMtztdH7OKDXmYbI/commerce-api-reference-guide/glossary#terms-of-sales-tos-acceptance). The following requests allow a customer to accept the TOS from the cart:

* Submit cart: [`POST /v1/shoppers/me/carts/active/submit-cart`](https://app.gitbook.com/s/X2fWaY1Kp5sXA1fmOL7z/cart/submit-a-cart#v1-shoppers-me-carts-active-submit-cart)
* Update or create cart: [`POST /v1/shoppers/me/carts/active`](https://app.gitbook.com/s/X2fWaY1Kp5sXA1fmOL7z/cart/carts#v1-shoppers-me-carts-active-1)

## How a customer accepts the TOS

How a user accepts the TOS depends on which option you selected when configuring Terms of Sale Acceptance on the [Checkout tab](https://help.digitalriver.com/help/gc/Administration/Site/Configuring-site-settings.htm#CheckoutTab) under Configure Site Settings in [Global Commerce](https://gc.digitalriver.com/gc/ent/login.do).

### The customer passively accepts terms through order submission

If you choose **Shopper passively accepts terms through order submission**, the customer accepts the TOS when they submit the order. Digital River requires this setting when we are the Reseller of Record.

![](https://2721412755-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LzlYMEYC0GeLSgnsft6%2F-M73Llid-l_xPVANIYd8%2F-M73MxYe7HV6y-bdA9sA%2FPassive-Sales-Terms-of-Acceptance-checkbox.png?alt=media\&token=a3a63f05-2efd-47e8-97eb-40009536328a)

### The customer actively accepts the TOS

If you chose **Shopper actively accepts terms before completing the purchase**, the customer must click the checkbox to accept the TOS. Sites based in the EU require this setting.

![](https://2721412755-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LzlYMEYC0GeLSgnsft6%2F-M7CwbUaH0g1YbyRJEPu%2F-M7Cwkd3f2KZnZx5dhBv%2FSales-Terms-of-Acceptance-checkbox.png?alt=media\&token=ca296b6c-3417-4306-86fc-8c76d1da8358)

### No acceptance required

Choose **No Acceptance Required** if your site does not require the customer to accept the TOS.
