Skip to content

API Overview

WireBuddy provides a RESTful API for programmatic access to all functionality.

Base URL

https://vpn.example.com/api

Authentication

All API requests require authentication via Bearer token.

See API Authentication for details.

Endpoints

Resource Description
/api/auth/* Authentication and session management
/api/interfaces/* WireGuard interface management
/api/peers/* Peer management
/api/dns/* DNS configuration and query logs
/api/metrics/* Traffic statistics and analytics
/api/users/* User management (admin only)
/api/settings/* Application settings (admin only)

See API Endpoints for complete reference.

Quick Example

# Get all peers
curl -H "Authorization: Bearer YOUR_TOKEN" \
  https://vpn.example.com/api/peers

OpenAPI Documentation

WireBuddy provides interactive API documentation via Swagger UI:

https://vpn.example.com/docs

Note

Swagger UI can be disabled via SWAGGER_ENABLED=false environment variable.

Rate Limiting

API requests are rate-limited:

  • Authenticated: 100 requests/minute
  • Unauthenticated: 10 requests/minute

See Rate Limiting for details.

Next Steps