VAP AI Authentication API
OAuth login and session management
OAuth login and session management
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/vapagent-com:vapagent-com-authentication-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: VAP - Execution Control Layer for AI Agents Authentication…
description: '## Execution Control Layer for AI Agents
VAP enforces cost control, retry limits, and execution ownership between AI agents and paid external APIs.
*"VAP is where nondeterminism stops."*
### The Problem
If your agents call paid APIs directly, you don''t have:
- **Cost control** - No budget limits, no spending caps
- **Retry limits** - Failed calls can loop indefinitely
- **Failure ownership** - No clear accountability when things go wrong
### The Solution: Reserve → Burn → Refund
1. **Reserve**: Budget is locked before task execution
2. **Execute**: Task runs with reserved funds
3. **Burn/Refund**: Pay actual cost on success, full refund on failure
### Pricing
| Type | Price |
|------|-------|
| Image | $0.18 |
| Video | $1.96 |
| Music | $0.68 |
| AI Edit | $0.15 |
### Integration Options
- **REST API**: Direct HTTP integration
- **MCP**: Model Context Protocol for Claude Desktop
- **A2A**: Agent-to-Agent Protocol for inter-agent communication
### Quick Links
- Developer Hub - API docs, keys, and usage guidance
- API Keys - How to get your API key
- Error Codes - Complete error reference
- Rate Limits - Understand tier limits
- Webhooks - Real-time task notifications
- Agent Card - A2A Protocol discovery
### Authentication
All endpoints require Bearer token authentication:
```bash
curl -H "Authorization: Bearer vap_xxxx" \
https://api.vapagent.com/v3/agents/me
```
Get your API key by registering an agent: `POST /v3/agents`
**Important**: API keys are shown only once during registration. Save it securely!
### Base URL
```
https://api.vapagent.com
```
### Versioning
Current API version: **v1.20.6**
All endpoints are under the `/v3/` namespace.'
contact:
name: VAP Support
url: https://vapagent.com/
email: support@vapagent.com
license:
name: Proprietary
url: https://vapagent.com/
version: 1.20.6
servers:
- url: https://api.vapagent.com
description: Production server
tags:
- name: Authentication
description: OAuth login and session management
paths:
/auth/google:
get:
tags:
- Authentication
summary: Google Login
description: 'Initiate Google OAuth flow.
Redirects user to Google''s OAuth consent screen.
All callbacks go through /auth/callback.html (D#051 centralized handler).
Params:
destination: dashboard | deposit | studio (default: dashboard)
from: studio (optional, for return-to-studio flow)
regenerate: true to force new API key generation (D#052)'
operationId: google_login_auth_google_get
parameters:
- name: redirect_uri
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: 'DEPRECATED: Use destination instead'
title: Redirect Uri
description: 'DEPRECATED: Use destination instead'
- name: destination
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: 'Where to redirect: dashboard, deposit, studio'
title: Destination
description: 'Where to redirect: dashboard, deposit, studio'
- name: from
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: 'Source: ''studio'' for Studio flow'
title: From
description: 'Source: ''studio'' for Studio flow'
- name: regenerate
in: query
required: false
schema:
type: boolean
description: 'D#052: Force API key regeneration for existing users'
default: false
title: Regenerate
description: 'D#052: Force API key regeneration for existing users'
- name: origin
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
description: 'D#149: Frontend origin for multi-domain redirect'
title: Origin
description: 'D#149: Frontend origin for multi-domain redirect'
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/auth/google/callback:
get:
tags:
- Authentication
summary: Google Callback
description: 'Handle Google OAuth callback.
Exchanges code for tokens, creates/finds agent, redirects to frontend.'
operationId: google_callback_auth_google_callback_get
parameters:
- name: code
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Code
- name: state
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: State
- name: error
in: query
required: false
schema:
anyOf:
- type: string
- type: 'null'
title: Error
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
/auth/status:
get:
tags:
- Authentication
summary: Auth Status
description: Check OAuth configuration status.
operationId: auth_status_auth_status_get
responses:
'200':
description: Successful Response
content:
application/json:
schema: {}
/auth/session:
get:
tags:
- Authentication
summary: Get Session
description: 'Check current session status.
Returns session info if authenticated, otherwise authenticated=false.
Auto-refreshes token if < 6h remaining.
Cookie: vap_session (httpOnly)'
operationId: get_session_auth_session_get
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/SessionStatus'
delete:
tags:
- Authentication
summary: Logout
description: 'Logout - clear session cookie.
Returns success even if no session existed.'
operationId: logout_auth_session_delete
responses:
'200':
description: Successful Response
content:
application/json:
schema:
additionalProperties: true
type: object
title: Response Logout Auth Session Delete
/auth/session/refresh:
post:
tags:
- Authentication
summary: Refresh Session
description: 'Force refresh current session token.
Returns new session status with fresh token.'
operationId: refresh_session_auth_session_refresh_post
responses:
'200':
description: Successful Response
content:
application/json:
schema:
$ref: '#/components/schemas/SessionStatus'
components:
schemas:
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
SessionStatus:
properties:
authenticated:
type: boolean
title: Authenticated
agent_id:
anyOf:
- type: string
- type: 'null'
title: Agent Id
agent_name:
anyOf:
- type: string
- type: 'null'
title: Agent Name
email:
anyOf:
- type: string
- type: 'null'
title: Email
oauth_provider:
anyOf:
- type: string
- type: 'null'
title: Oauth Provider
expires_in_hours:
anyOf:
- type: number
- type: 'null'
title: Expires In Hours
type: object
required:
- authenticated
title: SessionStatus
description: Session status response.
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
type: object
required:
- loc
- msg
- type
title: ValidationError