AlliDesk API
For any platform a store uses — its website, an app, an ERP or CRM, an automation — to use the store's AlliDesk features: sign-in with a one-time code, reviews, loyalty points and rewards, the wishlist and referrals, for the same customers and the same data as the store's website.
How it fits together
The store makes an API key in AlliDesk under Settings → Integrations → API keys, choosing Your own platform, and gives it to you. Your server calls AlliDesk with it. Call /store first to see which features the store has on; sign the customer in with /auth and send their token with every call about them.
GET https://app.allidesk.com/api/v1/store Authorization: Bearer ald_live_… X-Customer-Token: <token from /auth/verify> (calls about a customer)
Rules
- Call from your server only. The key belongs to the store; it must never be put in an app or a web page, where anyone could read it.
- Every call sends Authorization: Bearer <key>. Calls about a customer also send X-Customer-Token: <token> from /auth/verify.
- A platform with its own sign-in (Shopify customer accounts) can send X-Customer-Id: <Shopify customer ID> instead, with a key the store gave the customers scope.
- Every answer is JSON. Errors look like { "error": { "code": "…", "message": "…" } }.
- Features the store has switched off answer 409 module_off; read /store first and show only what is on.
Scopes
loyaltyRead a customer's points and rewards, and spend them reviewsRead product reviews and questions, and post new ones loginSign customers in with a one-time code to their phone or email wishlistRead and change a signed-in customer's wishlist referralsRead a signed-in customer's referral code, link and invites customersAct for any customer by their Shopify customer ID — only for a platform that signs customers in itself Store
Which AlliDesk features the store has switched on, so your platform shows only those.
GET /api/v1/store · The store and its features
When your platform starts, and when the merchant connects AlliDesk.
Answer{ "store": { "name": "Adynic", "shop": "adynic.myshopify.com", "domain": "adynic.in", "currency": "INR" }, "modules": { "login": true, "reviews": true, "loyalty": true, "referrals": true, "wishlist": true, "reels": false }, "key": { "scopes": [ "login", "reviews", "loyalty", "wishlist", "referrals" ] } }Sign-in
The store's one-time-code sign-in, by email or Indian mobile number: the same account as on its website. The token it gives is sent as X-Customer-Token on every call about that customer.
POST /api/v1/auth/send · Send a code
The customer typed their email or mobile number. Scope
login.identifierrequiredAn email, or a 10-digit Indian mobile number (with or without +91). Request{ "identifier": "+91 98765 43210" }Answer{ "ok": true, "channel": "phone" }POST /api/v1/auth/verify · Check the code
The customer typed the code they received. Codes last 10 minutes; five tries. Scope
login.identifierrequiredThe same identifier as for send. coderequiredThe 6-digit code. Request{ "identifier": "+91 98765 43210", "code": "482913" }Answer{ "ok": true, "token": "cmh….1767225600.q2…", "customer_id": "7201928374650", "via": "shopify" }POST /api/v1/auth/logout · Sign out
The customer signs out on your platform. The token stops working at once. Scope
login. X-Customer-Token required.Answer{ "ok": true }GET /api/v1/customer · Who is signed in
To greet the customer and fill forms. X-Customer-Token required.
Answer{ "customer": { "id": "7201928374650", "email": "riya@example.com", "phone": "+919876543210", "first_name": "Riya", "last_name": "Sharma", "points": 1200, "tier": "Gold" } }Reviews
Product reviews with photos, star summaries for product lists, helpful votes and questions.
GET /api/v1/reviews?product=<id>&page=1&per_page=10&sort=recent · A product's reviews
On the product page. sort is recent, helpful, rating_high, rating_low or pictures; rating=1…5 and photos=1 filter. Scope
reviews.Answer{ "product_id": "8123456789", "summary": { "count": 23, "average": 4.6, "buckets": { "1": 0, "2": 1, "3": 1, "4": 4, "5": 17 } }, "total": 23, "page": 1, "pages": 3, "reviews": [ { "id": "cr1", "rating": 5, "title": "Loved the fit", "body": "Great quality…", "photos": [ "https://…" ], "author": "Riya S", "verified": true, "date": "2026-09-20T10:00:00.000Z", "reply": null, "helpful": 4 } ], "photos": [ "https://…" ], "questions": [], "rules": { "can_write": true, "verified_only": true, "photos": true, "questions": true, "star_color": "#f5a524" } }GET /api/v1/reviews/summary?products=<id>,<id> · Stars for many products
On product lists: up to 100 products a call. Products without reviews are left out. Scope
reviews.Answer{ "ratings": { "8123456789": { "average": 4.6, "count": 23 } } }POST /api/v1/reviews · Write a review
The customer sends a review. With the store's “verified buyers only” rule on, it needs X-Customer-Token of a customer who bought the product. Scope
reviews. X-Customer-Token optional.product_idrequiredThe Shopify product ID. product_titlerequiredShown to the merchant. ratingrequired1 to 5. bodyrequiredThe review. titleA headline. photosUp to 6 https image URLs, already uploaded. name, emailFor a customer who isn't signed in. Request{ "product_id": "8123456789", "product_title": "Blue Kurta", "rating": 5, "title": "Loved it", "body": "Great quality and fit." }Answer{ "ok": true, "status": "pending", "message": "Thank you. Your review will show once the store has read it." }POST /api/v1/reviews/<id>/vote · Was this helpful?
The shopper taps helpful or not. visitor is any stable ID for them. Scope
reviews.Request{ "helpful": true, "visitor": "device-7f3a" }Answer{ "ok": true, "yes": 5, "no": 0 }POST /api/v1/questions · Ask a question
A shopper asks about a product; the store answers in AlliDesk. Scope
reviews. X-Customer-Token optional.Request{ "product_id": "8123456789", "product_title": "Blue Kurta", "body": "Is this cotton?", "name": "Arjun", "email": "arjun@example.com" }Answer{ "ok": true, "message": "Thanks. The store will answer this shortly." }Loyalty
The points programme, the customer's balance and tier, rewards, and points off an order. (Checkouts naming the customer by phone or email use the separate Loyalty API for checkouts.)
GET /api/v1/loyalty/program · The programme
For a guest: how points are earned and what they buy. Scope
loyalty.Answer{ "enabled": true, "signedIn": false, "pointsName": "Coins", "currency": "INR", "earnPerAmount": 100, "redeemRate": 0.25, "minRedeemPoints": 100, "waysToEarn": [], "rewards": [ { "id": "rw1", "name": "₹100 off", "pointsCost": 400 } ], "tiers": [] }GET /api/v1/loyalty/account · The customer's points
On the account screen. Scope
loyalty. X-Customer-Token required.Answer{ "enabled": true, "signedIn": true, "balance": 1200, "pending": 150, "lifetime": 3400, "tier": { "name": "Gold" }, "nextTier": { "name": "Platinum", "pointsAway": 600 }, "rewards": [ { "id": "rw1", "name": "₹100 off", "pointsCost": 400, "canRedeem": true } ], "history": [], "codes": [] }POST /api/v1/loyalty/reward · Redeem a reward
The customer spends points on a reward; the answer is a Shopify discount code. Scope
loyalty. X-Customer-Token required.Request{ "reward_id": "rw1" }Answer{ "ok": true, "code": "ALD-7KQ2M" }GET /api/v1/loyalty/checkout?subtotal=1499 · Points this cart can take
On the cart, to offer “Use 500 points”. Scope
loyalty. X-Customer-Token required.Answer{ "mode": "code", "points_name": "Coins", "balance": 1200, "max": 599, "max_value": 149.75, "rate": 0.25, "min_points": 100, "min_order": 499, "max_percent": 10, "applied": { "code": "POINTS-8K3F2Q", "points": 500, "amount": 125, "minSubtotal": 1250 } }POST /api/v1/loyalty/points · Use points on the cart
The customer applies points. In code mode (the default) apply the returned code to the Shopify cart (Storefront API cartDiscountCodesUpdate, or /cart/update.js with discount); it is for this customer only, works once and lasts three days, and any earlier unused spend is given back first. In automatic mode, put note on the cart as the allidesk_points attribute instead. Scope
loyalty. X-Customer-Token required.Request{ "points": 500, "subtotal": 1499 }Answer{ "ok": true, "mode": "code", "code": "POINTS-8K3F2Q", "amount": 125, "points": 500 }POST /api/v1/loyalty/unpoints · Take points off the cart
The customer removes points before paying; they go back to their balance and the code stops working. Send code (code mode) or note (automatic mode). Scope
loyalty. X-Customer-Token required.Request{ "code": "POINTS-8K3F2Q" }Answer{ "ok": true, "message": null }Wishlist
The same wishlist as the store's website: saved on your platform, seen on the web, and the other way round.
GET /api/v1/wishlist · Saved products
The wishlist screen, and to fill the hearts. Scope
wishlist. X-Customer-Token required.Answer{ "items": [ { "product_id": "8123456789", "variant_id": null, "title": "Blue Kurta", "handle": "blue-kurta", "image": "https://…", "price": 799, "list": "My wishlist" } ] }POST /api/v1/wishlist · Save a product
The customer taps the heart. Scope
wishlist. X-Customer-Token required.Request{ "product": { "id": "8123456789", "title": "Blue Kurta", "handle": "blue-kurta", "price": 799, "image": "https://…" } }Answer{ "ok": true }DELETE /api/v1/wishlist?product=<id> · Remove a product
The customer taps the heart again. Scope
wishlist. X-Customer-Token required.Answer{ "ok": true }Referrals
Invite-a-friend: the customer's own link, and the friend's discount when they arrive through it.
GET /api/v1/referrals · The customer's link and invites
The invite screen. locked is set when the store lets customers share only after a first order. Scope
referrals. X-Customer-Token required.Answer{ "locked": null, "code": "RIYA20", "link": "https://adynic.in/?ref=RIYA20", "share_message": "Get ₹100 off at Adynic: https://…", "friend_reward": "₹100 off their first order", "your_reward": "500 coins", "stats": { "clicks": 12, "joined": 3, "rewarded": 2, "pending": 1, "earned": "1,000 coins" }, "referrals": [] }POST /api/v1/referrals/click · A friend arrived
Your platform was opened through a ?ref=CODE link. Counts the visit once per visitor and gives the friend's discount code. Scope
referrals.Request{ "code": "RIYA20", "visitor": "device-7f3a", "channel": "app" }Answer{ "ok": true, "code": "ALD-FRIEND-2K9" }Errors
400invalid_json · invalid_product · invalid_rating · invalid_identifier · …A field is missing or not in the shape shown.401unauthorized · store_uninstalled · customer_required · customer_token_invalidNo key or a revoked one, the store removed AlliDesk, or the call needs a signed-in customer.403forbiddenThe key doesn't have the scope this call needs.409module_offThe store has that feature switched off in AlliDesk. Hide it on your platform.422review_refused · reward_refused · points_refused · referral_refusedThe store's rules said no; the message says why and can be shown to the customer.429rate_limitedMore than 600 calls a minute on one key.Testing
Ask the store for a key on their development store and sign in with an email address of your own: /auth/send emails the code to it. For anything else, write to hello@allidesk.com.
Write to hello@allidesk.com. A person replies, usually within one business day.