Betalink Docs
API Reference

API Reference

Complete reference for all Betalink API endpoints

Base URL

All API requests should be made to:

https://betalink.dev/api

Authentication

All endpoints (except health check) require authentication via the X-API-Key header:

X-API-Key: your-api-key

Endpoints

Common Response Codes

Status CodeDescription
200Success
400Bad Request - Invalid parameters
401Unauthorized - Invalid or missing API key
404Not Found - Resource doesn't exist
422Validation Error - Request/response validation failed
429Too Many Requests - Rate limit exceeded
500Internal Server Error

Error Response Format

All errors follow a consistent format:

{
  "error": {
    "code": "ERROR_CODE",
    "message": "Human-readable error message"
  }
}

Pagination

List endpoints support cursor-based pagination with these parameters:

ParameterTypeDefaultDescription
limitinteger50Items per page (1-100)
afterstring-Cursor for next page
beforestring-Cursor for previous page

Paginated responses include:

{
  "data": [...],
  "meta": {
    "total": 150,
    "limit": 50,
    "hasMore": true
  },
  "_links": {
    "self": "/api/v1/companies?limit=50",
    "next": "/api/v1/companies?limit=50&after=cursor",
    "prev": null
  }
}

On this page