> For the complete documentation index, see [llms.txt](https://docs.digitalriver.com/commerce-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.digitalriver.com/commerce-api/events/event-types/subscription-event-types/subscription-created-event.md).

# Subscription created event

The `subscription.created` event is triggered when a customer completes the purchase or signs up for a trial of a subscription product on a platform that uses Digital River's services. This event marks a crucial point in the customer journey, indicating the initiation of a new subscription. It enables businesses to track the start of new subscriptions in real time by sending a JSON payload with detailed subscription information to the specified endpoint URL. This data includes the subscription ID, creation and activation dates, renewal details, and product and shopper information. Responding to this event can assist businesses in various operations, including inventory management, customer service, and targeted marketing activities.

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

```json
{
  "type": "subscription.created",
  "data": {
    "object": {
      "id": "8457000397",
      "creationDate": "2021-07-01T05:04:47.493Z",
      "activationDate": "2021-06-30T18:30:00.000Z",
      "nextRenewalDate": "2022-06-30T18:30:00.000Z",
      "expirationDate": "2022-06-30T18:30:00.000Z",
      "graceDate": "2022-07-30T18:30:00.000Z",
      "currentQuantity": 1,
      "renewalQuantity": 1,
      "autoRenewal": true,
      "locale": "en_US",
      "state": "Subscribed",
      "duration": 365,
      "frequency": 365,
      "siteId": "sub2test",
      "shopper": {
        "id": "35504010397"
      },
      "renewalPrice": {
        "unitPrice": 95,
        "locked": false,
        "currency": "USD"
      },
      "term": {
        "termUnit": "YEARS",
        "termLength": 1
      },
      "product": {
        "id": "9964801100",
        "displayName": "Annual Auto Renewal Subscription",
        "sku": "12"
      },
      "shipToAddress": {
        "id": "76213030397",
        "firstName": "Mona",
        "lastName": "Yadav",
        "companyName": "ABC",
        "line1": "Kalyani Nagar",
        "city": "Pune",
        "postalCode": "411014",
        "countrySubdivision": "AA",
        "country": "IN",
        "countryName": "India",
        "phoneNumber": "09503796942",
        "emailAddress": "test@dr1.com"
      },
      "paymentOption": {
        "nickName": "Default",
        "id": "6631000397",
        "isDefault": "true",
        "type": "CreditCardMethod",
        "creditCard": {
          "expirationMonth": "8",
          "expirationYear": "2023",
          "displayableNumber": "************1111",
          "type": "visa",
          "displayName": "Visa"
        },
        "address": {
          "id": "66287380397",
          "firstName": "Mona",
          "lastName": "Yadav",
          "companyName": "ABC",
          "line1": "Kalyani Nagar",
          "city": "Pune",
          "postalCode": "411014",
          "countrySubdivision": "AA",
          "country": "IN",
          "countryName": "India",
          "phoneNumber": "09503796942",
          "emailAddress": "test@dr1.com"
        }
      },
      "addOns": []
    }
  },
  "clientIds": {
    "site_id": "sub2test"
  },
  "searchableData": {
    "subscriptionId": "8457000397"
  }
}
```

{% endtab %}

{% tab title="Response" %}

<pre class="language-json"><code class="lang-json">{
    "id": "0d14d343-a81f-44d4-9545-7b80d3d1ff77",
    "type": "subscription.created",
<strong>    "data": {
</strong>        "object": {
      "id": "8457000397",
      "creationDate": "2021-07-01T05:04:47.493Z",
      "activationDate": "2021-06-30T18:30:00.000Z",
      "nextRenewalDate": "2022-06-30T18:30:00.000Z",
      "expirationDate": "2022-06-30T18:30:00.000Z",
      "graceDate": "2022-07-30T18:30:00.000Z",
      "currentQuantity": 1,
      "renewalQuantity": 1,
      "autoRenewal": true,
      "locale": "en_US",
      "state": "Subscribed",
      "duration": 365,
      "frequency": 365,
      "siteId": "sub2test",
      "shopper": {
        "id": "35504010397"
      },
      "renewalPrice": {
        "unitPrice": 95.0,
        "locked": false,
        "currency": "USD"
      },
      "term": {
        "termUnit": "YEARS",
        "termLength": 1
      },
      "product": {
        "id": "9964801100",
        "displayName": "Annual Auto Renewal Subscription",
        "sku": "12"
      },
      "shipToAddress": {
        "id": "76213030397",
        "firstName": "Mona",
        "lastName": "Yadav",
        "companyName": "ABC",
        "line1": "Kalyani Nagar",
        "city": "Pune",
        "postalCode": "411014",
        "countrySubdivision": "AA",
        "country": "IN",
        "countryName": "India",
        "phoneNumber": "09503796942",
        "emailAddress": "test@dr1.com"
      },
      "paymentOption": {
        "nickName": "Default",
        "id": "6631000397",
        "isDefault": "true",
        "type": "CreditCardMethod",
        "creditCard": {
          "expirationMonth": "8",
          "expirationYear": "2023",
          "displayableNumber": "************1111",
          "type": "visa",
          "displayName": "Visa"
        },
        "address": {
          "id": "66287380397",
          "firstName": "Mona",
          "lastName": "Yadav",
          "companyName": "ABC",
          "line1": "Kalyani Nagar",
          "city": "Pune",
          "postalCode": "411014",
          "countrySubdivision": "AA",
          "country": "IN",
          "countryName": "India",
          "phoneNumber": "09503796942",
          "emailAddress": "test@dr1.com"
        }
      },
      "addOns": []
    }
  },
  "clientIds": {
    "site_id": "sub2test"
  },
  "searchableData": {
    "subscriptionId": "8457000397"
  }
}
</code></pre>

{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://docs.digitalriver.com/commerce-api/events/event-types/subscription-event-types/subscription-created-event.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.
