Authentication
In this guide, we’ll look at how authentication works. DevRIFT allows only one ways to authenticate requests; using API keys.
You can grab your API keys from the dashboard. You can find it under Application Settings » API Keys.
API Keys
The DevRIFT API uses API keys to authenticate requests. You can view and manage your API keys in the DevRIFT Dashboard.
Test mode secret keys have the prefix sk_test_
and live mode secret keys have the prefix sk_live_
. Alternatively, you can use restricted API keys for granular permissions.
All API requests must be made over HTTPS. Calls made over plain HTTP will fail. API requests without authentication will also fail.
Your Secret Keys carry many privileges, so be sure to keep them secure! Do not share your Secret Keys in publicly accessible areas such as GitHub, client-side code, and so forth.
Example request using API Keys
curl -G https://api.devrift.co/v1/hello \
-H "Authorization: Bearer {sk_test_foobar...}" \
-d limit=1
Do not share your secret API keys in publicly accessible areas such as GitHub, client-side code, and so forth.
Using an SDK
When you use one of our official SDKs, you can just fetch your API Keys from the DevRIFT dashboard, and the client library will take care of the rest.