vtex-io-auth-tokens-and-context

Select and propagate VTEX IO authentication tokens for backend requests.

39|9|Updated Mar 16, 2026
One-click install
npx skills add https://github.com/vtex/ai-skills --skill vtex-io-auth-tokens-and-context
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vtex-io-auth-tokens-and-context
Source: https://github.com/vtex/ai-skills/tree/main/tracks/vtex-io/skills/vtex-io-auth-tokens-and-context
Command: npx skills add https://github.com/vtex/ai-skills --skill vtex-io-auth-tokens-and-context

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Decide and apply the correct VTEX IO authentication identity for backend requests to VTEX services, ensuring the requester context drives the token selection and propagation.

Core Features & Use Cases

  • Decide between AUTH_TOKEN, STORE_TOKEN, and ADMIN_TOKEN based on storefront, Admin, or background app contexts.
  • Propagate the selected token through VTEX IO clients to enforce the proper permission scope without leaking credentials.
  • Use explicit authMethod when passing tokens to clients to guarantee the correct identity is used for each call.

Quick Start

In a backend request, determine the requester type and specify the corresponding token to attach to VTEX IO client calls.

Frequently Asked Questions about vtex-io-auth-tokens-and-context

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I choose the correct VTEX IO auth token for a backend request?

To choose the correct VTEX IO auth token, identify the requester context (storefront, Admin, or background app) and select AUTH_TOKEN, STORE_TOKEN, or ADMIN_TOKEN to match the required permissions. This ensures proper token propagation through IO clients.

What is the difference between AUTH_TOKEN, STORE_TOKEN, and ADMIN_TOKEN in VTEX IO?

AUTH_TOKEN, STORE_TOKEN, and ADMIN_TOKEN represent different VTEX IO authentication identities. STORE_TOKEN applies to storefront contexts, ADMIN_TOKEN to Admin environments, and AUTH_TOKEN generally handles background app workflows, ensuring the identity matches the requester's permissions.

How do I propagate VTEX IO tokens through IO clients without leaking credentials?

Propagate VTEX IO tokens by explicitly using the authMethod when passing tokens to IO clients. This guarantees the correct identity is attached to each call without exposing credentials in client-side code.

When should I use an explicit authMethod with VTEX IO client calls?

You should use an explicit authMethod with VTEX IO client calls when you need to guarantee the correct token identity is applied for each specific call. This enforces the proper permission scope consistently across backend requests.

Does VTEX IO token selection differ for background app workflows versus storefront requests?

Yes, VTEX IO token selection differs by context. Background app workflows typically require AUTH_TOKEN, while storefront requests use STORE_TOKEN. Selecting the token based on the requester context ensures the correct permission scope is enforced.

Why do my VTEX IO client calls fail with permission errors across different contexts?

VTEX IO client calls fail with permission errors when the selected token identity does not match the requester context. Applying token selection consistently between AUTH_TOKEN, STORE_TOKEN, and ADMIN_TOKEN resolves these permission scope mismatches.