Spiral gives your agent every tool with one account. Browse the tools →

VS Code · E-commerce

How to Use Amazon product option attributes in VS Code

Returns the product options and attributes linked to an Amazon.com listing. Use it to map size, color, or style choices to ASINs; checking availability requires a separate lookup.

Prompts to try with Amazon product option attributes in VS Code

Copy an example into VS Code, or ask in your own words.

Use Amazon product option attributes for B09B8V1LZ3 and create a CSV in this project with one row per returned ASIN and its option attributes.

Amazon product option attributesVS Code
Try asking
  • Use Amazon product option attributes for B07FZ8S74R and compare the returned ASINs and attributes with any matching records in this project's catalog files.

  • Use Amazon product option attributes for B09B8V1LZ3 and B07FZ8S74R, then write a Markdown table comparing their returned option dimensions.

  • Use Amazon product option attributes to look this up and give me the result as a table. Save the result in ./assets.

  • Pull the latest numbers from Amazon product option attributes and tell me what changed since last week.

How to set up Amazon product option attributes in VS Code

Pick the way that suits you. Each takes about two minutes.

Use Spiral's MCP server

  1. Add the hosted server

    Use Add to VS Code on the console's Agents & MCP page, or run:

    code --add-mcp '{"name":"spiral","type":"http","url":"https://api.spiral.ai/mcp"}'
  2. Sign in

    VS Code asks you to sign in when it first starts the server: sign in to Spiral and click Authorize. No API key. Run MCP: List Servers from the Command Palette to check that Spiral is running.

Use the Spiral skill

  1. Send VS Code this message

    Your agent reads Spiral's skill and sets itself up.

    set up https://spiral.ai/SKILL.md
  2. Sign in or paste a key

    Approve Spiral in the browser, or give the agent a key from the console.

Use the Spiral CLI

  1. Install and sign in

    Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run Amazon product option attributes

    One request; the result comes back by polling or a webhook.

    curl https://api.spiral.ai/v1/runs \
      -H "Authorization: Bearer $SPIRAL_API_KEY" \
      -H "Content-Type: application/json" \
      -H "Idempotency-Key: $(uuidgen)" \
      -d '{
        "provider": "alexandria",
        "model": "amazon-com/products/variations",
        "input": {
          "asin": "<asin>"
        }
      }'

Then paste one of the prompts above: VS Code finds Amazon product option attributes on Spiral, shows the price and runs it.

Amazon product option attributes providers and prices

Spiral runs Amazon product option attributes through Alexandria. Open a card for today's price, with every fee included.

AlexandriaE-commerce
Amazon US · Variations
amazon-com/products/variations

What can you do with Amazon product option attributes in VS Code?

Build an ASIN-to-option table that your project's catalog code can use to distinguish Amazon sizes, colors, and styles. Compare returned attributes with existing records to find mapping errors before updating a product selector.

Build a product option table

Turn the returned ASINs and attributes into a table showing which size, color, or style belongs to each listed choice.

Check catalog mappings

Compare a retailer's existing product records with Amazon's linked ASINs and attributes. Flag records assigned to a different size or color for review.

Monitor assortment changes

Compare successive results for a known product and report newly returned ASINs, removed ASINs, and changed option labels.

Compare competitor option breadth

Count the returned color, size, or style choices for selected public listings. Use the comparison to identify differences in the displayed assortment.

Prepare an exact-option shortlist

Find the returned ASINs matching a buyer's requested attributes, such as a particular color and size, before checking purchase details.

Review listing relationships

Inspect the attributes attached to linked ASINs and flag unexpected labels or combinations for a catalog team's review.

Questions about Amazon product option attributes in VS Code

Can VS Code use Amazon product option attributes?

Yes. Add Spiral to VS Code as an MCP server, and VS Code can find and run Amazon product option attributes like any built-in tool.

How much does Amazon product option attributes cost in VS Code?

$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your VS Code plan is separate.

Do I need an Alexandria account to use Amazon product option attributes in VS Code?

No. Spiral runs Amazon product option attributes on its own Alexandria account. You sign in to Spiral once and never paste a key.

How long does it take to set up Amazon product option attributes in VS Code?

About two minutes: add the hosted server, then sign in.

Does VS Code wait while Amazon product option attributes runs?

Amazon product option attributes runs in the background. VS Code starts the run, checks on it and gives you the json when it's ready.

Does every Amazon product have size or color options?

No. Amazon says some categories do not allow variation listings, while others support only selected types of differences. A listing's linked options therefore depend on its category.

Can I purchase the parent product?

Amazon defines the parent product as non-buyable. It connects the child products, so use the ASIN for the specific option when identifying an item to purchase.

How quickly do changes to product options appear?

Amazon's seller guidance says updates can take up to two hours to appear on the product page. Removing a child ASIN can take up to 24 hours.

Does the brand alone control the displayed product options?

No. Amazon combines product data from multiple sellers on a shared detail page. Its guidance says other sellers can change the linked product options.

What identifies a specific Amazon product option?

Amazon uses ASINs, its 10-character alphanumeric product identifiers. Keep the returned ASIN alongside each option's attributes so similarly named choices remain distinguishable.

Get started

Start using Amazon product option attributes in VS Code

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into VS Code:

Set up VS Code

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options