Getting Started

Learn the basics to start using the Drock API in your projects.

Base URL

Public content endpoints live under the v1 base URL.

bash
https://api.getdrock.com/api/v1

Your First Request

Use this discovery endpoint to verify connectivity and see available resources.

bash
curl -X GET "https://api.getdrock.com/api/v1"
This particular endpoint is public and does not require an authentication token.

First Authenticated Request

Once you have an API key, start with blogs. This confirms that the Authorization header is accepted and that your key scope is valid.

bash
curl -X GET "https://api.getdrock.com/api/v1/blogs" \
  -H "Authorization: Bearer YOUR_API_KEY"

Browser And CORS Notes

Drock accepts browser preflight requests on public v1 endpoints and allows the Authorization header. If your browser still reports a missing header, inspect any proxy or CDN layer that might strip it.

Frontend token exposure
Only use a NEXT_PUBLIC_ token when that key is intentionally public and tightly scoped. Sensitive keys should stay server-side.

Next Steps

Now that you're ready, you should: