<form action-xhr="/add-to-cart" method="POST">
POST /add-to-cart HTTP/2.0 Cookie: session_id=12345
POST /add-to-cart HTTP/2.0
<form action-xhr="/api/add-to-cart" method="POST" <select name="quantity"> <option value="0">0</option> <option value="1" selected>1</option> <option value="2">2</option> </select> <input type="submit" value="Add to Cart"> </form>
POST /api/add-to-cart HTTP/2.0 AMP-Same-Origin: true Cookie: session_id=12345 quantity=2
POST /api/add-to-cart HTTP/2.0 Cookie: session_id=12345 quantity=2
POST /api/add-to-cart HTTP/2.0 quantity=2
if (!request.cookies.session_id && request.headers['amp-same-origin'] !== 'true')
response.setHeader("AMP-Redirect-To", `https://bestclips.com?item=${request.body.itemName}&quantity=${request.body.quantity}`);
AMP-Redirect-To:https://bestclips.com/product?item=superclip&quantity=1