gateway-token-doctor

Diagnose and fix gateway token mismatches causing 401 errors across config, service, and CLI surfaces.

3|Updated Feb 28, 2026
One-click install
npx skills add https://github.com/Dalomeve/bot-output --skill gateway-token-doctor
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gateway-token-doctor
Source: https://github.com/Dalomeve/bot-output/tree/main/skills/gateway-token-doctor
Command: npx skills add https://github.com/Dalomeve/bot-output --skill gateway-token-doctor

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Gateway token mismatches across config, service, and CLI surfaces cause 401 Unauthorized errors, authentication failures, and degraded gateway reliability.

Core Features & Use Cases

  • Token surface audit across auth, remote, and service tokens to identify mismatches.
  • Alignment and propagation of a single token across config files, startup scripts, and CLI surfaces.
  • Verification and safe recovery workflows to restore valid access without exposing credentials.

Quick Start

Audit gateway token surfaces and align the tokens across config, service, and CLI to restore access.

Frequently Asked Questions about gateway-token-doctor

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

FAQPage Schema
Why does my gateway return 401 Unauthorized errors on startup?

Gateway 401 Unauthorized errors typically happen when authentication tokens are mismatched across config files, service scripts, and CLI surfaces. Auditing these token surfaces identifies the specific misalignment causing the authentication failures.

How do I align gateway tokens across config files and CLI surfaces?

To align gateway tokens, audit all authentication token surfaces, propagate a single valid token across config files and startup scripts, and run post-change validation steps to verify authentication success. This ensures consistent access across deployment surfaces.

What is a gateway token surface audit?

A gateway token surface audit inspects auth, remote, and service tokens across config, service, and CLI environments to identify mismatches. It specifies which token surfaces require inspection to diagnose authentication failures and restore valid access.

Can I safely recover gateway access without exposing credentials?

Yes, safe recovery workflows restore gateway access without exposing credentials by applying alignment and verification steps. These workflows propagate a single token across config and scripts while validating authentication success without printing sensitive values.

How do I verify gateway authentication after updating a token?

Verify gateway authentication after a token update by running post-change validation steps to confirm authentication success. This involves checking the service startup sequence and CLI surfaces to ensure the newly propagated token resolves previous 401 errors.

When should I diagnose gateway token mismatches instead of restarting the service?

Diagnose gateway token mismatches when persistent 401 errors survive service restarts across typical deployment scenarios. If authentication failures stem from config and CLI token misalignment, targeted token surface alignment is required to restore reliable access.