LogoLogo
  • About
  • Quick Start
  • API reference
    • Workspace
      • Dependencies
      • Copy
      • Property definitions
        • Reorder
      • Property instances
        • Reorder
        • Lock
        • Unlock
      • Blocks
      • Comments
        • Parent
      • Data Sinks
    • Webhooks
      • Rotate secret
    • Cloud storage
      • Redirect
      • Thumbnail
      • Upload complete
      • Retry conversion
      • Download
      • Upload link
      • Version list
      • Metadata
Powered by GitBook
On this page
  • Authenticating with the Rollup API
  • Using API Keys
  • Hello World Example with API Key

Was this helpful?

Quick Start

This is a quick overview to getting started with the Rollup API using standard API Key authentication.

PreviousAboutNextAPI reference

Last updated 1 year ago

Was this helpful?

Authenticating with the Rollup API

Using API Keys

Create a new API key

  1. Go to Settings -> Developer Settings -> API keys

  2. Click on Add API key

  3. Add a label, then select the permissions for the key

  4. Click on Create

How to use the API key in requests

The API key should be sent as x-api-key header.

Hello World Example with API Key

curl --location 'https://api.rollup.ai/v1/workspace' \
--header 'x-api-key: <YOUR-API-KEY>'
const apiKey = "<YOUR-API-KEY>";
const myHeaders = new Headers();
myHeaders.append("x-api-key", apiKey);

const requestOptions = {
  method: "GET",
  headers: myHeaders,
  redirect: "follow"
};

fetch("https://api.rollup.ai/v1/workspace", requestOptions)
  .then((response) => response.text())
  .then((result) => console.log(result))
  .catch((error) => console.error(error));
import http.client

conn = http.client.HTTPSConnection("api.rollup.ai")
payload = ''
headers = {
  'x-api-key': '<YOUR_API_KEY>',
}
conn.request("GET", "/v1/workspace", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
Create an API key with custom permissions