Rolebase Developers

API Reference

Access and manage your Rolebase organizations programmatically through the GraphQL API.

API Keys

Generate API keys for your organization at /apps. These keys authenticate all requests to the API.

GraphQL Endpoint

Production: https://api.rolebase.io/graphql

Local development: http://localhost:8888/graphql

The API is powered by Hasura, so you can refer to the Hasura documentation for advanced query capabilities.

Quick Start

Using curl

curl -X POST https://api.rolebase.io/graphql \
  -H "x-api-key: YOUR_API_KEY_HERE" \
  -H "Content-Type: application/json" \
  -d '{"query": "{ org { id, name } }"}'

Using Apollo Client

import {
  ApolloClient,
  InMemoryCache,
  createHttpLink,
  gql,
} from '@apollo/client'

// Create the client with auth headers
const client = new ApolloClient({
  link: createHttpLink({
    uri: 'https://api.rolebase.io/graphql',
    headers: {
      'x-api-key': 'YOUR_API_KEY_HERE',
    },
  }),
  cache: new InMemoryCache(),
})

// Example query
const { data } = await client.query({
  query: gql`
    query GetOrganization {
      org {
        id
        name
      }
    }
  `,
})
Lamp On Authentication

Include the x-api-key header in every request. Your API key determines which organization data you can access and what operations are permitted.

Entities

Each entity supports standard GraphQL operations (query, mutation) depending on your API key permissions.

Organization & Members

Circles & Roles

Meetings