LogoLogo
System Status
  • Digital River API
  • Getting started
  • Using our services
    • Local pricing
    • Item classification
    • Subscriptions
    • e-Invoicing
  • Integration options
    • Low-code checkouts
      • Implementing a Prebuilt Checkout
      • Implementing a Components checkout
      • Offering local pricing
      • Using a shipping endpoint
      • Processing subscription acquisitions
      • Adding custom fields
      • Offering store credit
      • Displaying policies and getting consent
      • Collecting e-invoice information
      • Handling completed checkout-sessions
    • Direct integrations
      • Standard flow
      • Building checkouts
        • Checking out guest and registered customers
        • Describing line items
          • Setting the price of an item
          • Managing items with shared SKU identifiers
        • Providing address information
        • Handling shipping choice
        • Tax identifiers
        • Applying a discount
        • Setting the customer type
        • Providing the IP address
        • Selecting a currency
        • Initiating a charge
        • Setting the purchase location
        • Configuring taxes
        • Accessing regulatory fee information
        • Localizing invoices and credit memos
        • Providing an upstream identifier
        • Applying store credit
        • Handling e-invoicing requirements
        • Landed cost
        • Tax calculation inputs
        • Selling entities
        • Payment sessions
        • Applying store credit (legacy)
        • Country specs
      • Building payment workflows
        • Handling redirect payment methods
        • Handling delayed payment methods
      • Subscription acquisitions
        • Handling subscription acquisitions
        • Handling external subscription acquisitions
        • Subscription information
      • Digital River coordinated fulfillments
        • Checking inventory levels
        • Using shipping quotes
        • Reserving inventory items
        • Managing a fulfillment order
        • Cancelling a fulfillment order
    • Connectors
  • Order management
    • Processing orders
    • Handling a rejected order
    • Accessing invoices and credit memos
    • Fulfilling goods and services
    • Capturing and cancelling charges
    • Payment reauthorizations
    • Handling reversals
      • Return basics
        • Digital River coordinated returns
        • Third party coordinated returns
      • Refund basics
        • Issuing refunds
        • Refunding asynchronous payment methods
      • Disputes and chargebacks
    • Customer notifications
    • Responding to events
      • Events
        • Key event types
        • All event types
      • Webhooks
        • Creating a webhook
        • Digital River API safelist
        • Digital River signature
      • Expanding events
      • Preventing webhooks from getting disabled
    • Distributor model
  • Subscription Management
    • Managing a subscription
    • Managing an external subscription
  • Payments
    • Payment solutions
      • Drop-in payments
        • How Drop-in payments work
        • Drop-in payments integration guide
      • DigitalRiver.js with Elements
        • Elements integration guide
        • Configuring payment methods
          • Configuring Afterpay
          • Configuring Alipay+ (cross-border)
          • Configuring Alipay (domestic)
          • Configuring Amazon Pay
          • Configuring Apple Pay
          • Configuring Bancontact
          • Configuring BNP Paribas
          • Configuring BLIK
          • Configuring CCAvenue
          • Configuring Clearpay
          • Configuring Credit Cards
          • Configuring FPX Online Banking
          • Configuring Google Pay
          • Configuring iDEAL
          • Configuring Klarna
          • Configuring Konbini
          • Configuring Online Banking (IBP)
          • Configuring Online Banking (Korea Bank Transfer)
          • Configuring PayCo
          • Configuring PayPal
          • Configuring SEPA Direct Debit
          • Configuring Trustly
          • Configuring Wire Transfer
          • Common payment sources
          • Common payment objects
    • Supported payment methods
      • Afterpay
      • Alipay (domestic)
      • Alipay+ (cross-border)
      • Amazon Pay
      • Apple Pay
      • Bancontact
      • BNP Paribas
      • BLIK
      • CCAvenue
      • Clearpay
      • Credit Cards
      • FPX Online Banking
      • Google Pay
      • iDEAL
      • Klarna
      • Konbini
      • Korea Bank Transfer (Online Banking)
      • Online Banking (IBP)
      • Pay with Installments France
      • PayCo
      • PayPal
      • PayPal Billing Agreement
      • PayPal Credit
      • PayPal Pay in 3
      • PayPal Pay in 4
      • PayPal RatenZahlung (Installment Payment)
      • SEPA Direct Debit
      • Trustly
      • Wire Transfer
    • Source basics
      • Managing sources
      • Handling credit card sources
      • Retrieving sources
    • Authorization declines
    • PSD2 and SCA
      • How to ensure SCA compliance
    • Payment testing scenarios
  • Product management
    • Product basics
    • Managing SKUs
    • Using product details
    • Grouping SKUs
    • SKU-inventory item pairs
    • Managing inventory items
    • Regulatory fees
      • What are regulatory fees?
        • Fees terminology
        • Regulatory fee management
        • European regulatory fees
        • Compliance obligations
        • WEEE directive requirements
        • Copyright directive requirements
        • Compliance challenges
      • Managing regulatory fees
  • Customer management
    • Customer basics
    • Creating and updating customers
    • Setting up tax exemptions
    • Recording a customer's request to be forgotten
  • Financial reporting
    • Financials basics
    • Sales transactions
      • Returning a list of sales transactions
      • Getting a sales transaction by ID
    • Sales summaries
      • Returning a list of sales summaries
      • Getting a sales summary by ID
    • Payouts
      • Returning a list of payouts
      • Getting a payout by ID
      • Get a list of transactions included in payout by ID
  • Developer resources
    • Digital River API reference
    • DigitalRiver.js reference
      • Including DigitalRiver.js
      • Initializing DigitalRiver.js
      • DigitalRiver object
      • Elements
        • Amazon Pay element
        • Apple Pay elements
        • Google Pay elements
        • IBAN element
        • iDEAL element
        • Konbini elements
        • Compliance element
        • Offline Refund elements
        • Online Banking elements
        • Tax Identifier element
        • Invoice attribute element
        • Delayed Payment Instructions element
        • PayPal elements
      • Guidelines for capturing payment details
      • Security
      • Digital River payment objects
      • Error types, codes, and objects
    • DigitalRiverCheckout.js reference
      • Including DigitalRiverCheckout.js
      • Initializing DigitalRiverCheckout.js
        • DigitalRiverCheckout configuration object
      • DigitalRiverCheckout object
        • Configuring Prebuilt Checkout
          • Performing actions
          • Defining experience
        • Components
          • Configuring components
          • Address component
          • Shipping component
          • Tax identifier component
          • Invoice component
          • Wallet component
          • Payment component
          • Compliance component
          • Order summary component
          • Thank you component
        • Rendering a checkout button
          • Performing actions on the checkout button
        • Determining the checkout's status
      • Accessing country and currency
    • DynamicPricing.js reference
    • Postman collection
  • administration
    • Sign in
    • Digital River Dashboard
      • Digital River Dashboard quick start guide
      • Key features
      • Reset your password
      • Test and production environments
      • Account
        • Adding an account
        • Switching accounts
        • Account access
      • Profile settings
        • Viewing your personal information
        • Changing your password
        • Updating your phone number
        • Enabling multi-factor authentication
      • Finance
        • Payouts
          • Viewing your payout details
          • Filtering your payouts
          • Exporting your payouts
        • Sales summaries
          • Viewing your sales summaries details
          • Filtering your sales summaries
          • Exporting your sales summaries
          • Exporting your sales summary details
        • Transactions
          • Viewing your transaction details
          • Filtering your transactions
          • Exporting your transactions
      • Order management
        • Orders
          • Searching for orders
          • Filtering your orders
          • Viewing the order details
          • Cancelling items
          • Fulfilling items
          • Downloading an invoice
          • Downloading a credit memo
          • Creating shipping labels
          • Recording a customer's request to be forgotten
          • Viewing returns and refunds
          • Creating a return
          • Accepting a return
          • Creating a refund
          • Viewing the order's timeline
        • Checkouts
          • Searching for checkouts
          • Filtering your checkouts
          • Viewing the checkout details
        • Prebuilt Checkout links
          • Generate Prebuilt Checkout links
          • View and work with Prebuilt Checkout link details
          • Add a customer during Prebuilt Checkout
          • Add a product during Prebuilt Checkout
      • Customers
        • Viewing customer details
        • Searching for customers
        • Filtering your customers
        • Editing account information
        • Adding a customer
        • Tax IDs and certificates
          • Adding a tax certificate
          • Adding a tax ID
          • Deleting a tax ID
        • Metadata
          • Adding metadata
          • Editing metadata
        • Manage subscriptions from the Customer Details page
        • Disabling a customer
        • Recording a customer's request to be forgotten
        • Deleting a customer
      • Catalog
        • SKUs
          • Viewing the SKU details
          • Searching for SKUs
          • Filtering your SKUs
          • Adding a SKU
          • Editing a SKU
          • Deleting a SKU
          • Adding a fee to a SKU
          • Editing a fee
          • Deleting a fee
          • Viewing product tariff codes
        • Managing customer subscriptions from Digital River Dashboard
      • Developers
        • API keys
          • Updating your API version
          • Getting your API keys
          • Changing the API version for your key
          • Creating a restricted key
          • Editing a restricted key
          • Deleting a restricted key
          • Rotating keys
        • Webhooks
          • Creating a webhook
          • Editing a webhook
          • Deleting a webhook
          • Rotating a webhook's secret
        • API logs
          • Filtering the API log
          • Viewing the API log details
        • Event logs
          • Filtering the events log
          • Viewing the event details
      • Settings
        • Users and roles
          • Roles
          • Searching for a user by name or email
          • Filtering your users and roles
          • Adding a user
          • Editing a user
          • Deleting a user
        • Prebuilt Checkout
        • Payment methods
          • Viewing your payment methods
          • Viewing payment method details
            • Enabling currencies
            • Managing countries
          • Enabling or disabling a payment method
  • General Resources
    • eCompass
    • eCompass documentation
    • Release notes
      • 2024
      • 2023
      • 2022
      • 2021
      • 2020
      • 2019
    • Standards and certifications
      • Certification process
      • Compliance requirements
      • Documentation requirements
      • Integration checklists
        • Admin portal
        • Products and SKUs
        • Customers and tax exemptions
        • Checkouts, payment sources, and orders
        • Disclosures, compliance statements, and emails
        • Fulfillments and cancellations
        • Customer portal
        • Order refund synchronization
        • Reversals
        • Error handling
      • Test and use cases
    • Commerce infrastructure
    • Versioning
    • Glossary
Powered by GitBook
On this page
  • Sending product data in checkouts
  • Send basic and compliance data in SKUs
  • Send basic data in SKUs and compliance data in SKU groups
  • Send basic data in product details and compliance data in SKU groups
  • How Digital River returns product data
  • Setting price and quantity
  • Providing subscription information
  • Discounting a product
  • Setting a ship from location
  • Updating items
  1. Integration options
  2. Direct integrations
  3. Building checkouts

Describing line items

Understand how to describe a checkout's products or services

PreviousChecking out guest and registered customersNextSetting the price of an item

Last updated 2 months ago

You use a items[] array to pass data on in a customer's cart. The elements of items[] allow you to:

After you , we return an that uniquely identifies each of a checkout's line items. This identifier is needed to in an .

Since update checkout requests only allow you to modify subscription, ship from and meta data, your create checkout request must include a line item's product data, price, and quantity.

For more information, refer to the section on the page.

Sending product data in checkouts

In a , you must provide Digital River with on the products in a customer's cart. You have three options for passing this data. You can:

Whichever option you select, .

Digital River also assigns each of a checkout's items[] a unique id.

Send basic and compliance data in SKUs

POST/checkouts
curl --location --request POST 'https://api.digitalriver.com/checkouts' \
...
--data-raw '{
    ...
    "items": [
        {
            "skuId": "d0c6c536-1a5b-4c1d-be86-92e3363a1e1f",
            "quantity": 2,
            "price": 10
        }
    ]
}'

Once you submit this request, Digital River retrieves all the product data we need from the referenced SKU.

This option requires you to keep the product catalog in your system synchronized with your SKUs in our system.

Send basic data in SKUs and compliance data in SKU groups

For more information, refer to:

POST/checkouts
curl --location --request POST 'https://api.digitalriver.com/checkouts' \
...
--data-raw '{
    ...
    "items": [
        {
            "skuId": "d0c6c536-1a5b-4c1d-be86-92e3363a1e1f",
            "quantity": 2,
            "price": 10
        }
    ]
}'

Once you submit this request, Digital River retrieves basic product data from the referenced SKU and compliance product data from the SKU's SKU group.

This option requires that you keep the product catalog in your system synchronized with your SKUs in our system.

Common attributes and data priority in SKUs and SKU groups

  • Harmonized system code

  • Export control classification number

  • Tax code

Send basic data in product details and compliance data in SKU groups

Digital River then accesses basic product data from productDetails and compliance data from the referenced SKU group.

POST/checkouts
curl --location --request POST 'https://api.digitalriver.com/checkouts' \
...
--data-raw '{
    ...
    "items": [
        {
            "productDetails": {
                "id": "2837a981-9e41-408b-a1b2-ffa3223bc505",
                "skuGroupId": "wireless-keyboards",
                "name": "Basic wireless keyboard",
                "description": "A simple, basic wireless keyboard",
                "url": "https://www.company.com/basic-wireless-keyboard",
                "countryOfOrigin": "US",
                "image": "https://www.company.com/basic-wireless-keyboard/image",
                "weight": 1,
                "weightUnit": "kg",
                "partNumber": "ce1fd95d-b211-47e8-a9b7-9941a4ce9d7a"
            }
            "quantity": 2,
            "price": 10
        }
    ]
}'

Common attributes in productDetails and SKUs

How Digital River returns product data

If you pass productDetails, we give you back that same data.

curl --location --request POST 'https://api.digitalriver.com/checkouts' \
...
--data-raw '{
    ...
    "items": [
        {
            "skuId": "b0fd7334-8f7d-424e-b535-308fae972461",
            "quantity": 2,
            "price": 10
        }
    ],
    ...
}'
{
    "id": "08720898-5998-4501-aee6-f35d58de5e0a",
    ...
    "items": [
        {
            "id": "9f8bf171-8612-46c3-8d26-c37a4c710beb",
            "skuId": "b0fd7334-8f7d-424e-b535-308fae972461",
            "productDetails": {
                "id": "b0fd7334-8f7d-424e-b535-308fae972461",
                "name": "Widget",
                "description": "A small gadget or mechanical device",
                "countryOfOrigin": "US",
                "weight": 10,
                "weightUnit": "g",
                "partNumber": "b0fd7334-8f7d-424e-b535-308fae972461"
            },
            ...
        }
    ],
    ...
}
{
    "id": "231388420336",
    ...
    "items": [
        {
            "id": "158140150336",
            "skuId": "b0fd7334-8f7d-424e-b535-308fae972461",
            "productDetails": {
                "id": "b0fd7334-8f7d-424e-b535-308fae972461",
                "name": "Widget",
                "description": "A small gadget or mechanical device",
                "countryOfOrigin": "US",
                "weight": 10,
                "weightUnit": "g",
                "partNumber": "b0fd7334-8f7d-424e-b535-308fae972461"
            },
            ...
        }
    ],
    ...
    "checkoutId": "08720898-5998-4501-aee6-f35d58de5e0a"
}

Setting price and quantity

You must also set the line item's price or aggregatePrice.

Providing subscription information

Discounting a product

Setting a ship from location

Updating items

If you attempt to update any other line item data, you receive a 400 Bad Request:

{
    "type": "bad_request",
    "errors": [
        {
            "code": "unknown_parameter",
            "parameter": "price",
            "message": "'price' is an unknown parameter."
        }
    ]
}

In this option, before , you must define and create a for each of the product's in your catalog. Each SKU needs to contain both on that product.

For more information, refer to the and pages.

In this option, each items[] in a must contain a skuId.

In this option, before , you must define and create a for each product in your catalog. The SKUs only need to contain .

Before , you must also by setting the skuGroupId. The holds the .

In this option, each items[] in a must contain a skuId.

If you decide to use this option, you should be aware that the following attributes are common to both and :

In , a SKU group's data precedes a SKU's data. If a common attribute is defined in a SKU but not the SKU group it belongs to, then we use the SKU's data in the checkout.

For more details, refer to on the page.

In this option, you don't store in Digital River's system.

Instead, you retrieve this data from your system and, for each items[] in a , use it to define .

The in productDetails should be the same as the identifier of the product in your system.

The object must also contain a skuGroupId that references the that holds the .

Since you're not persisting any basic product data in Digital River's system, you're not required to keep the product catalog in your system synchronized with in our system.

However, prior to deployment, you need to work with Digital River to . Once defined, Digital River is responsible for managing the data in this resource.

For more information, refer to the page.

If your integration currently uses , and you're considering a migration to this option, you should be aware that the attributes in SKUs and are nearly identical.

The key exceptions are taxCode, eccn, and hsCode. These attributes exist in SKUs but not in productDetails. This is because all of these attributes contain saved in the associated .

SKUs also have a and this attribute is not in productDetails.

In , manufacturerId is used to set up products in warehouses. That process however is handled prior to deployment. So there's no need to set manufacturerId in checkouts.

Whether you send productDetails or skuId in , the 201 Created response always contains productDetails.

But if your integration sends skuId, Digital River retrieves from the referenced (along with that object's identifier) and uses it to populate the productDetails. If you , productDetails is also passed through to that object.

As a result, in both and , as well as their associated , such as checkout.updated, , and , you can easily access product data without making another .

This feature is especially useful if you employ a third-party service that sends emails and other notifications to customers. These services can to listen for such as , , and , and then handle these events by retrieving data from productDetails and passing it in the notification.

For each element in a items[] array, you must specify quantity. This represents the number of items selected by the customer. If you don't specify quantity, then its value defaults to 1.

For more information on how to do this, refer to the page.

In , you set subscriptionInfo at the line-item level. For more information, refer to:

For each element in a items[] array, you can set a product-level discount.

For more information, refer to the section on the page.

If a products are shipping from multiple locations, you can specify each location using items[].shipFrom.

For more information, refer to the section on the page.

When updating products or services in a request, you must provide the returned in the .

For each line item in the update checkout request, you're restricted to updating , a product's , and metadata.

Product basics
Managing SKUs
Product basics
Managing SKUs
Grouping SKUs
Grouping SKUs
Setting the price of an item
Subscription information
Digital River's subscription service
Third-party subscription services
products and/or services
Building checkouts
Send product data
Set a product's price and quantity
Provide a product's subscription details
Discount a product
Identify a product's ship from location
modify the line item
Send basic and compliance data in SKUs
Send basic data in SKUs and compliance data in SKU groups
Send basic data in productDetails and compliance data in SKU groups
Digital River always returns productDetails
checking out customers
checking out customers
SKU's
Grouping SKUs
productDetails
productDetails
SKU group
productDetails
SKU group
events
events
Applying a discount
Providing address information
basic product data
product's compliance data
compliance data
id
Migrating to SKU groups
define your SKU groups
basic and compliance data
basic and compliance data
basic product data
product's compliance data
associate a SKU group with each of your SKUs
basic product data
Digital River coordinated fulfillments
configure a webhook
manufacturerId
subscription.reminder
order.complete
order.fulfilled
order.complete
subscription information
SKU
SKU
POST /checkouts
creating checkouts
SKU group
POST /checkouts
SKUs
SKU groups
checkouts
POST /checkouts
SKUs
SKUs
POST /checkouts
checkouts
orders
call to retrieve the SKU
checkout's
checkouts
checkout's
checkout's
checkout's
create a checkout
update checkout request
create checkout request
SKU
checkout's
POST /checkouts/{id}
checkout
convert the checkout to an order
order.cancelled
ship from address
ship from address
items[].id
sending the create checkout request
line item identifier
product discounts