Third-party subscription engine

Accept subscription information from third-party subscription engine

post

Accept Subscription Information (Including Billing Agreements) for supporting third-party subscription engine.

Use ECO billing optimization tool for third-party subscription engine.

Body
Responses
200
Successful response.
application/json
post
POST /v1/shoppers/me/carts/active (subscriptionInfo) HTTP/1.1
Host: api.digitalriver.com
Content-Type: application/json
Accept: */*
Content-Length: 424

{
  "cart": {
    "lineItems": {
      "lineItem": {
        "quantity": "2",
        "product": {
          "id": "1234"
        },
        "subscriptionInfo": {
          "autoRenewal": true,
          "terms": "subscription terms",
          "freeTrial": false,
          "startTime": "2020-08-01T00:00:00.000Z",
          "endTime": "2021-08-01T00:00:00.000Z",
          "billingAgreementId": "6ed70eb4-da79-46f1-9e7d-210c043d3c9e"
        },
        "billingOptimization": {
          "subscriptionId": "555444",
          "segmentId": "12",
          "renewalAttempNumber": 3
        }
      }
    },
    "chargeType": "customer_initiated"
  }
}
{
  "lineItems": {
    "lineItem": [
      {
        "subscriptionInfo": {
          "autoRenewal": true,
          "terms": "subscription term",
          "freeTrial": false,
          "startTime": "2020-08-01T00:00:00.000Z",
          "endTime": "2021-08-01T00:00:00.000Z",
          "billingAgreementId": "6ed70eb4-da79-46f1-9e7d-210c043d3c9e"
        },
        "billingOptimization": {
          "subscriptionId": "555444",
          "segmentId": "12",
          "renewalAttempNumber": 3
        }
      }
    ],
    "customAttributes": {
      "attribute": [
        {
          "name": "hasExternalSubscriptionInfo",
          "type": "Boolean",
          "value": true
        }
      ]
    },
    "chargeType": "customer_initiated"
  }
}

Last updated