# AJAX API

> The Shopify theme AJAX endpoints Smootify 2.0 answers on a Webflow page.

Status: Ready (Smootify 2.0)  
URL: https://www.smootify.io/docs/reference/ajax-api  
Updated: 2026-10-13

Apps written for Shopify themes call these endpoints; Smootify answers them on the page with the response Shopify would give. `ajaxApi: false` in [`SmootifyUserOptions`](https://www.smootify.io/docs/reference/options) turns them off.

## Supported

### `GET /cart.js`, `GET /cart.json`

The same cart the page shows.

### `POST /cart/add.js`, `POST /cart/add`, `POST /cart/add.json`

Form-encoded or JSON, `items[]`, `properties`, `selling_plan`; `sections` ignored.

### `POST /cart/update.js`, `POST /cart/update.json`

`updates` by id / key / index, `note`, `attributes`.

### `POST /cart/change.js`

`id` / `line`, `quantity`, `properties`.

### `POST /cart/clear.js`

### `GET /products/{handle}.js`, `GET /products/{handle}.json`

From Smootify’s product cache when it already has the product, else from Shopify.

### `GET /recommendations/products.json?product_id=&limit=&intent=`

`related` (default) or `complementary`.

### `GET /variants/{id}.json`

REST shape `{ product_variant }` (decimal string prices, grams, `product_id`, `position`), as the Online Store answers.

### `GET /search/suggest.json?q=&resources[type]=&resources[limit]=`

Products, collections, pages, articles and query suggestions.

### `POST /localization`

`country_code` / `language_code` change the market; no redirect (answers `{}`)

### `POST /api/unstable/graphql.json`

The customer privacy (consent) requests go to Shopify, as in 1.x.

## Partly supported

### `GET /products.json?limit=`

First page only (`page>1` → `[]`, the Storefront API paginates by cursor)

### `GET /collections/{handle}/products.json?limit=`

First page only.

## Not supported

### `GET /cart/shipping_rates.json`, `POST /cart/prepare_shipping_rates.json`

`422` with Shopify’s error shape (no shipping rates outside checkout)

### `/apps/*`, `/a/*`, `/community/*`, `/tools/*` (GET)

Shopify app proxies need the Online Store: on a Webflow site they reach the network and Webflow answers 404 (the debugger names them); only Shopify Inbox’s `/apps/ba-rev` gets an empty `{}`, as 1.x.
