You can test storefronts using either a global alias or an alias on your local system to access a specific on-demand sandbox.
When considering the use of an alias, keep the following in mind:
To use a global alias, assign a CNAME to the DNS that maps the alias to the IP address of the sandbox. To test on your local system, you can use the Sandbox API to assign a local alias to a sandbox using the following procedure.
www.merchant.com
, in your site’s alias configuration under
‘Merchant Tools > SEO > Aliases’.Define an on-demand sandbox Alias using the POST
/sandboxes/{sandboxId}/aliases
method.
What if I Don’t Use a Browser?
When testing REST APIs, you typically don’t use default browser access to a site.
When using tools like Curl or Postman, you must define a cookie header manually
using the hostname and information you obtain from the GET/system
API response.
For example,
curl -X GET -k -H 'Cookies:
b2codds_df69b6df-a4fb-3e8b-ada3-d0ded26e9fe0=83f05593-6272-382f-be1c-bc8e5021a243'
'https://www.merchant.com/dw/shop/v20_1/products/foo'