Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.alterauth.com/llms.txt

Use this file to discover all available pages before exploring further.

Quick Decision Guide

Do END USERS need to authorize access to THEIR accounts?
├── Yes → Use OAuth Connections
│         (e.g., a user connects their Google Calendar)
└── No  → Use Managed Secrets
          (e.g., storing the Stripe API key)
Both use the same vault.request() method. The only difference is where the grant_id comes from: OAuth returns it when the user completes authorization; Managed Secrets returns it when you store a credential in the Developer Portal.

Comparison

OAuth ConnectionsManaged Secrets
Best forEnd users authorizing access to their accountsDeveloper-owned API keys and service tokens
Who provides the credentialEnd user (via OAuth flow)Developer (via Developer Portal)
Credential is per…Per userPer service
grant_id comes fromonSuccess callback or connect() returnDeveloper Portal
Token refreshAutomaticManual (re-store when rotated)
User consent requiredYesNo
Visible in WalletYes (users can revoke)No (backend-only)
Setup complexityOAuth app + Alter Connect flowPaste credentials in portal

Providers That Support Both

Some providers offer both OAuth (for end-user access) and API keys (for developer/server access). Here’s when to use each, with our recommendation:

GitHub

MethodUse WhenRecommendation
OAuthUsers authorize access to their repos, issues, and PRsPrefer for user-facing features
Managed Secret (PAT)The backend needs server-level access to the org’s reposUse for CI/CD, automation, org-wide access
Recommendation: OAuth for user-facing features. Use a managed secret (Personal Access Token) only when you need org-wide or service-level access that doesn’t belong to a specific user.

Stripe

MethodUse WhenRecommendation
OAuth (Stripe Connect)Users connect their Stripe accounts to the platform (marketplace model)Use for multi-merchant platforms
Managed Secret (API key)The backend processes payments using the organization’s Stripe accountPrefer for most apps
Recommendation: Managed Secret for most applications. Most apps process payments with a single Stripe account, not individual users’ accounts. Use OAuth (Stripe Connect) only for marketplaces or platforms where merchants connect their own Stripe accounts.

Sentry

MethodUse WhenRecommendation
OAuthUsers connect their Sentry accounts for cross-org error monitoringUse for multi-tenant monitoring platforms
Managed Secret (auth token)The backend monitors errors in the organization’s Sentry orgPrefer for most apps
Recommendation: Managed Secret for most applications. Most apps monitor a single Sentry organization. Use OAuth only if users need to connect their own Sentry orgs to the platform.

Discord

MethodUse WhenRecommendation
OAuthUsers authorize the application to access their Discord identity, servers, or post on their behalfPrefer for user-facing features
Managed Secret (bot token)The bot operates server-wide using a bot tokenUse for Discord bots and server automation
Recommendation: OAuth for user identity and user-scoped actions. Use a managed secret (bot token) for server-wide bot operations where no individual user context is needed.

Airtable

MethodUse WhenRecommendation
OAuthUsers connect their Airtable bases to the applicationPrefer for user-facing features
Managed Secret (PAT)The backend accesses the organization’s Airtable basesUse for internal tools and automation
Recommendation: OAuth when users bring their own Airtable data. Use a managed secret (Personal Access Token) for internal dashboards or automation that accesses the organization’s bases.

PagerDuty

MethodUse WhenRecommendation
OAuthUsers connect their PagerDuty accounts for incident managementUse for multi-tenant incident platforms
Managed Secret (API key)The backend manages incidents in the organization’s PagerDuty accountPrefer for most apps
Recommendation: Managed Secret for most applications. Most apps manage incidents in a single PagerDuty account. Use OAuth only if users need to connect their own PagerDuty accounts.

Summary Table

ProviderPreferReason
GitHubOAuthUser-facing: users authorize their own repos
StripeManaged SecretMost apps use their own Stripe account for payments
SentryManaged SecretMost apps monitor their own Sentry org
DiscordOAuth (user) / Managed (bot)Depends: user identity vs server-wide bot
AirtableOAuthUser-facing: users bring their own bases
PagerDutyManaged SecretMost apps manage their own PagerDuty account

Still Unsure?

Ask yourself: “Does my end user need to log in and grant permission?”
  • Yes → OAuth connection
  • No → Managed secret
Both get the same security: encrypted storage, policy enforcement, audit logging, and zero token exposure in application code.

Next Steps

OAuth Connections

How OAuth grants work

Managed Secrets

How managed secrets work

Quickstart

Full integration walkthrough

Architecture

Security model and encryption