Base URL
Every API endpoint is rooted at:http://localhost:3000/api/v1.
Authentication
All API requests require anAuthorization header. Bkmark supports two methods:
- OAuth2 Bearer Token — the recommended choice for third-party integrations. You obtain a token by completing the OAuth2 Authorization Code flow on behalf of a user.
- API Key — the right choice for personal scripts and automation. You generate a key in Settings → Security → API Keys and use it directly.
Request Format
Send request bodies as JSON and include the appropriateContent-Type header:
Responses
Successful responses return HTTP200 OK or 201 Created. Endpoints that return a list of resources wrap them in an envelope:
Pagination
List endpoints use cursor-based pagination. To retrieve the next page of results, pass thenextCursor value from the previous response as the cursor query parameter:
nextCursor is null, you have reached the last page and there are no more results.
Error Format
All error responses share a consistent JSON structure:error for programmatic error handling and message for displaying context to users or logging.
HTTP Status Codes
| Status | Meaning |
|---|---|
200 OK | The request succeeded and the response body contains the result. |
201 Created | A new resource was successfully created. |
400 Bad Request | The request was malformed or failed validation. Check the message field. |
401 Unauthorized | No valid credentials were provided. Check your Authorization header. |
403 Forbidden | Your credentials are valid but do not have permission for this action. |
404 Not Found | The requested resource does not exist or is not accessible to you. |
409 Conflict | The request conflicts with existing data (for example, a duplicate resource). |
429 Too Many Requests | You have exceeded the rate limit for this endpoint. |
Sample Request and Response
The following example retrieves your first page of bookmarks using a Bearer token:?cursor=01J2K8M4N5P6Q7R8S9T0U1V2W4 to the URL.
Quick Links
Authentication
Learn how to obtain and use OAuth2 Bearer tokens and API keys to authorize requests.
API Keys
Create, list, update, and revoke API keys for personal automation workflows.
Rate Limits
Understand per-endpoint rate limits and how to handle 429 responses gracefully.
OAuth2 Authorization
Walk through the full OAuth2 Authorization Code flow with PKCE step by step.