Extract AliExpress Product Details and SKU Options

Site aliexpress.comTask extract-aliexpress-product-detailsVersion v2Updated Aug 22, 2026Category shopping

Open an AliExpress item by numeric item ID and extract its rendered product text plus structured SKU options. This skill was captured from a live agent session on aliexpress.com and publishes here verbatim, exactly as an agent receives it.

NoteSelectors and URL schemes drift as sites change. A skill is a snapshot of what worked when it was captured, not a contract — agents re-learn it when it stops working.

Purpose

Retrieve the rendered details of an AliExpress product page, including the page title, visible product text, and SKU/variant options exposed in the page DOM.

When to Use

Use when the caller provides an AliExpress numeric item ID or an item URL — on any AliExpress locale — and needs product information or available variants. This recipe is intended for one or more known item IDs; it does not guess opaque IDs from product names.

Workflow

  1. Build the direct URL https://{locale-domain}/item/{item-id}.html, where {locale-domain} is the AliExpress host implied by the caller's URL or locale (www.aliexpress.com by default; regional hosts such as ar.aliexpress.com, es.aliexpress.com, or pt.aliexpress.com) and {item-id} is the numeric ID from the caller's item URL or input. Preserve a regional gateway parameter when the caller's URL carries one — the Arabic site, for example, uses ?gatewayAdapt=glo2ara.
  2. In one browser call, navigate directly to the URL with waitUntil: "domcontentloaded", allow the client-rendered product content to hydrate briefly, then run this evaluator on the loaded page:
(() => {
  const body = document.body?.innerText || '';
  const rows = [...document.querySelectorAll('[data-sku-row]')].map(row =>
    [...row.children].map(option => ({
      sku: option.getAttribute('data-sku-col'),
      alt: option.querySelector('img')?.alt || null,
      text: (option.textContent || '').trim(),
      selected: option.classList.contains('selected')
    }))
  );
  return {
    url: location.href,
    title: document.title,
    visibleText: body,
    skuOptions: rows
  };
})()
  1. For multiple supplied item IDs, repeat the same direct navigation and evaluator per ID and return one result object per product. Preserve skuOptions as an array of rows because products may expose multiple SKU dimensions.

Site-Specific Gotchas

  • AliExpress product pages use opaque numeric IDs in /item/{id}.html; do not invent an ID. If only a product name is supplied, resolve it through AliExpress search first and read the numeric item ID from the selected result URL before using this workflow.
  • Product content and SKU controls are client-rendered, so a successful domcontentloaded can precede hydration; allow a short post-navigation wait before evaluating.
  • SKU options are represented by [data-sku-row] containers and child elements carrying data-sku-col. Preserve both the option text and image alt, and use the selected class to identify the currently selected option.
  • document.body.innerText may contain localization, shipping, promotional, and seller text in addition to core product details; interpret visibleText as the complete rendered text rather than a narrowly normalized field set.
  • Redirects between www.aliexpress.com and regional hosts such as ar.aliexpress.com can occur. Use the final location.href returned by the evaluator as the canonical loaded URL.

Expected Output

Return, for each item, an object with:

  • url: final loaded product URL;
  • title: document title;
  • visibleText: rendered page text;
  • skuOptions: nested arrays of {sku, alt, text, selected} option objects, one array per SKU dimension.

Call it

GET https://production-sfo.browserless.io/skills?token=TOKEN-HERE&domain=aliexpress.com&task=extract-aliexpress-product-details