AliExpress API — Parse an AliExpress URL
Documentation menu
FetchLayer FetchLayer API

Parse an AliExpress URL

Turn any AliExpress URL into the fields the other routes take: kind — product, search, category, store or short-link — plus whatever the URL carries: productId and skuId, the search query, page and filters, the categoryId, or the storeId. Works for regional hosts (de.aliexpress.com) and the US storefront. Short share links (a.aliexpress.com) do not carry the product; open one and pass the page it leads to. It makes no request to AliExpress and does not consume a credit.

POST /resolve-url Utility
https://api.fetchlayer.dev/aliexpress/resolve-url
OpenAPI JSON

Headers

Authorization string required

Bearer token — your FetchLayer API key.

Parameters

url string required

Any AliExpress URL, to be parsed into structured request input.

format string optional

json, or markdown to get the result rendered as text. (default: json)

timeoutMs number optional

Per-request time limit in milliseconds (max 600000).

Response Fields

resolve-url

Parse an AliExpress URL

kind string

What the URL points at: product, search, category, store, or short-link.

productId string

Present when kind is product — the global id.

skuId string

Present when a product URL selects a variant.

query string

Present when kind is search.

page number

Present when a search or category URL names a page.

filters object

Filters a search or category URL encodes.

categoryId string

Present when kind is category.

storeId string

Present when kind is store.

url string

The URL as parsed.

Request

curl -X POST "https://api.fetchlayer.dev/aliexpress/resolve-url" \
  -H "Authorization: Bearer ss-your-key" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://www.aliexpress.com/w/wholesale-mechanical-keyboard.html?sortType=total_tranpro_desc"}'

Response

{
  "kind": "search",
  "query": "mechanical keyboard",
  "page": 1,
  "filters": {
    "sort": "orders"
  },
  "url": "https://www.aliexpress.com/w/wholesale-mechanical-keyboard.html?sortType=total_tranpro_desc"
}