Suggestions

Use the Suggestions API to get the billing or shipping address suggestions for a cart. This feature provides address suggestions and corrections for real-time address validation. Real-time address validation must be enabled for your site before you can use the Suggestions API. Contact your Digital River representative for assistance.

Resource URIs

All methods in this API require a full access token.

Methods


					Host: api.digitalriver.com
Accept: application/json
Authorization: bearer your_access_token
User-Agent: Apache-HttpClient/4.5.2 (Java/1.8.0_102)
			
					The request body should be empty.
			
					HTTP/1.1 200 OK
			
					{
  "suggestions": {
    "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/billing-address/suggestions",
    "address": [
      {
        "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/billing-address/suggestions/1",
        "id": 1,
        "firstName": "John",
        "lastName": "Doe",
        "line1": "PO Box 3940",
        "line2": 123,
        "city": "Waconia",
        "countrySubdivision": "MN",
        "postalCode": "55387",
        "country": "US",
        "countryName": null,
        "phoneNumber": "555-555-5555"
      }
    ]
  }
}
			
					Host: api.digitalriver.com
Accept: application/json
Authorization: bearer your_access_token
User-Agent: Apache-HttpClient/4.5.2 (Java/1.8.0_102)
			
					The request body should be empty.
			
					HTTP/1.1 200 OK
			
					{
  "address": {
    "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/billing-address/suggestions/suggestion_ID",
    "id": 1,
    "firstName": "John",
    "lastName": "Doe",
    "line1": "PO BOX 3940",
    "line2": null,
    "city": "Waconia",
    "countrySubdivision": "MN",
    "postalCode": "55387",
    "country": "US",
    "countryName": null,
    "phoneNumber": "555-555-555"
  }
}
			
					Host: api.digitalriver.com
Accept: application/json
Authorization: bearer your_access_token
User-Agent: Apache-HttpClient/4.5.2 (Java/1.8.0_102)
			
					The request body should be empty.
			
					HTTP/1.1 200 OK
			
					{
  "suggestions": {
    "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/shipping-address/suggestions",
    "address": [
      {
        "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/shipping-address/suggestions/suggestion_ID",
        "id": suggestion_ID,
        "firstName": "John",
        "lastName": "Doe",
        "line1": "PO Box 3940",
        "line2": null,
        "city": "Waconia",
        "countrySubdivision": "MN",
        "postalCode": "55387",
        "country": "US",
        "phoneNumber": "555-555-5555"
      }
    ]
  }
}
			
					Host: api.digitalriver.com
Accept: application/json
Authorization: bearer your_access_token
User-Agent: Apache-HttpClient/4.5.2 (Java/1.8.0_102)
			
					The request body should be empty.
			
					HTTP/1.1 200 OK
			
					{
  "address": {
    "uri": "https://api.digitalriver.com/v1/shoppers/me/carts/active/shipping-address/suggestions/1",
    "id": 1,
    "firstName": "John",
    "lastName": "Doe",
    "line1": "PO Box 3940",
    "line2": null,
    "city": "Waconia",
    "countrySubdivision": "MN",
    "postalCode": "55387",
    "country": "US",
    "phoneNumber": "555-555-5555"
  }
}
			

Response Body Parameters

Fields
Data Type
Visibility
Description
address link default The billing address for the order. See the Addresses API and Fields Used as Keys for more information.