Your first API credential

Auth & Keys

An API key is a secret code your program sends with a request so Vidbyte can recognize your account and decide whether that request is allowed.

Credential anatomy

What is an API key?

Think of the key as a private badge for your application: it identifies the Vidbyte account making an API call. It is not a username, and the visible prefix by itself is not a complete key.

A Vidbyte API key

vb_live_your_api_key

Use the complete key. The vb_live_ prefix alone is not a working credential.

It identifies the caller
Your application includes the key so Vidbyte can authenticate the request and apply the account's access and usage rules.
It is a secret
Anyone who gets the full key may be able to make requests as your account. Store it like a password, not in public code or a web page.

Send a request

How your program sends the key

For a public API request, put the full key in the x-api-key HTTP header. A header is a small piece of request information sent alongside the URL and body.

In this example, replace the placeholder with your own key. Do not paste a real secret into shared examples, issue reports, or source code that other people can read.

Authenticate a request

bash
curl https://vidbyte-backend.onrender.com/api/v1/roadmaps/list \ -H "x-api-key: vb_live_your_api_key"
  • Send the complete key as the value of x-api-key.
  • Keep the key in a server-side secret store or environment variable when your application runs.

Key lifecycle

Create and protect your key

You can create a key from your Vidbyte API settings, then add it to the server-side application that will call the API.

  1. 01

    Create a key

    Open API settings and create a key for the application you are connecting. Keep the full value private.

  2. 02

    Connect your application

    Save the key in your hosting provider's secret settings and read it from your server when sending API requests.

  3. 03

    Replace an exposed key

    If a key is accidentally shared or exposed, remove or replace it in API settings and update the application using it.

  • Create or manage keys in Vidbyte API settings.