Agent skill · marketing growth · aiskillstore
authorizing-api-requests
Use when authenticating or authorizing requests to any Mailtrap API (Email Send, Email Testing/Sandbox, Templates, Contacts, Sending Domains, Suppressions). Use when picking the auth header, choosing token scope, storing tokens safely, or resolving the Mailtrap account_id. Use before writing or generating any Mailtrap API call.
Why this skill is useful
Provides specific guidelines for securely managing Mailtrap API tokens and account IDs that the AI wouldn't reliably generate on its own.
What it needs
Requires mailtrap account access. About 4k tokens when loaded. Last updated 2026-08-07. 405 stars on the source repository.
What this skill does
Authorizing Mailtrap API requests Overview Every Mailtrap API request needs two things: 1. An API token in an auth header — proves identity and carries the scope. 2. For account-scoped endpoints (most of them outside of the send hosts), an accountid in the URL path. This skill is the single source of truth for both. Other skills (sending-emails, testing-with-sandbox, using-email-templates, managing-contacts, setting-up-sending-domain) reference these conventions instead of duplicating them. When to use Before writing any Mailtrap API call from code, scripts, CI, IaC, or an AI agent Picking which token scope and stream to provision Deciding where to store a token (env, secret manager, CI) Resolving the accountid for an account-scoped endpoint Debugging 401 Unauthorized / 403 Forbidden responses API tokens Create tokens at Settings > API Tokens with the smallest scope that works: Email Sending API — for send.api.mailtrap.io and bulk.api.mailtrap.io. Scope per stream (transactional, bulk) when possible. Email Testing API — for the Sandbox (sandbox.api.mailtrap.io). Always separate from live sending tokens. Account-level API — for Contacts, Templates, Sending Domains, Suppressions, and other endpoints under https://mailtrap.io/api/accounts/{accountid}/.... A single token can cover several scopes if the user has the right plan; prefer narrower tokens (one stream / one project / one product surface) so a leak has limited blast radius. Reference: API tokens documentation. Auth headers (two equivalent forms) Mailtrap accepts either header. Use Bearer in examples — it's the more common HTTP convention and matches most generated SDK code. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills aiskillstore/authorizing-api-requests