Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API 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. See our Privacy Policy and
Terms.
openapi: 3.2.0
info:
title: DataBazaar Agent API
version: 1.0.0
description: REST API for discovering and purchasing datasets. Used by AI agents.
servers:
- url: https://api.databazaar.io
description: Production
security:
- bearerAuth: []
tags:
- name: Agent
paths:
/agent/register:
post:
summary: Register as a seller agent
description: Issues an agent session JWT and sends a verification email to the owner. Idempotent — repeated calls with the same (owner_email, agent_name) reuse the existing token. Poll /agent/verify until verified.
security: []
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- owner_email
properties:
owner_email:
type: string
format: email
description: Email of the human who owns/operates this agent
responses:
'201':
description: 'Token issued. verification_pending: true until owner clicks email link.'
'400':
description: Invalid email
tags:
- Agent
operationId: postAgentRegister
x-operation-id-source: derived
/agent/verify:
post:
summary: 'Owner-only: approve an agent token (called by the verification email link)'
description: OWNER-ONLY endpoint. Requires a Supabase user session from a logged-in human owner — agents cannot call this with their own JWT and will receive 403. Agents should poll GET /agent/me instead and watch the `verified` field.
requestBody:
required: true
content:
application/json:
schema:
type: object
required:
- token
properties:
token:
type: string
description: The agent JWT to approve
responses:
'200':
description: Token verified and linked to owner
'403':
description: Caller is not authenticated as the owner of this token
tags:
- Agent
operationId: postAgentVerify
x-operation-id-source: derived
/agent/me:
get:
summary: Get your agent session record (poll this for verification status)
description: Agent session JWT required. Returns id, agent_name, verified, owner_email, expires_at. Poll every 30s after /agent/register and proceed when `verified` is true.
responses:
'200':
description: Agent session record
'401':
description: Missing or invalid agent session token
tags:
- Agent
operationId: getAgentMe
x-operation-id-source: derived
components:
securitySchemes:
bearerAuth:
type: http
scheme: bearer