OAuth 2.0
Most secure and widely supported
User-delegated authentication with automatic token refresh and granular permissions.
Best for: Google, Microsoft, Slack, GitHub
Compare different authentication methods supported by Agent Auth including OAuth 2.0, API Keys, Bearer Tokens, and Custom JWT to choose the right approach.
Agent Auth supports multiple authentication methods to connect with third-party providers. This guide helps you understand the differences and choose the right authentication method for your use case.
OAuth 2.0
Most secure and widely supported
User-delegated authentication with automatic token refresh and granular permissions.
Best for: Google, Microsoft, Slack, GitHub
API Keys
Simple static credentials
Provider-issued keys for straightforward server-to-server authentication.
Best for: Jira, Asana, Linear, Airtable
Bearer Tokens
User-generated tokens
Personal access tokens with scoped permissions for individual use.
Best for: GitHub PATs, GitLab tokens
Custom JWT
Advanced signed tokens
Cryptographically signed tokens for service accounts and custom protocols.
Best for: Custom integrations, service accounts
| Feature | OAuth 2.0 | API Keys | Bearer Tokens | Custom JWT |
|---|---|---|---|---|
| Security Level | High | Medium | Medium | High |
| User Interaction | Required | Optional | Required | Not required |
| Token Refresh | Automatic | N/A | Manual | Varies |
| Setup Complexity | Moderate | Easy | Easy | Complex |
| Granular Permissions | Yes | Limited | Yes | Limited |
| Provider Support | Widespread | Common | Common | Limited |
Use when:
Example: User connects Gmail to send emails through your app
Use when:
Example: Automated Jira ticket creation for support system
Use when:
Example: Personal GitHub repository automation
Use when:
Example: Enterprise service account integrations