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
}
}
`,
})
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
org— Organizationsmember— Organization membersorg_file— Organization filesorg_subscription— Organization subscriptions
Circles & Roles
circle— Organizational circlescircle_leader— Circle leadership assignmentscircle_link— Links between circlescircle_member— Circle membershipscircle_participant— Circle participants (view)role— Roles within circles
Meetings
meeting— Meetingsmeeting_attendee— Meeting attendeesmeeting_recurring— Recurring meeting configurationsmeeting_step— Meeting steps and agenda itemsmeeting_template— Meeting templates