API Overview & Auth

API Reference

Integrate Relink directly with your own tools using the REST API.

Base URL

All API requests should be made to the base URL of your Relink instance. If you are running locally, this is usually http://localhost:3000/api.

Authentication

The Relink API uses Bearer token authentication. You can generate an API token from the Account page in the dashboard.

Include your token in the Authorization header of every request:

HTTP Header
Authorization: Bearer nlk_YOUR_API_TOKEN

Security Warning: Never expose your API token in client-side code (like generic frontend React applications without a backend proxy). It has full read/write access to your Relink account.

Error Handling

Relink uses standard HTTP status codes to indicate the success or failure of an API request. Failed requests will always return a JSON object with a single error property containing a human-readable message.

StatusMeaning
2xxSuccess. Request completed successfully.
400Bad request (e.g., missing required parameters).
401Unauthorized. Invalid or missing API token.
404Not found. The requested resource does not exist.
500Internal server error. Something went wrong on our end.