Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
KANKA_TIERNo‘free’ or ‘subscriber’, auto-detected from /profile
KANKA_TOKENNoKanka Personal API token (one of token or OAuth required)
KANKA_BASE_URLNoOverride the API base (for testing)
KANKA_LOG_LEVELNoLog level: trace, debug, info, warn, error, fatal
KANKA_TOKEN_FILENoFallback token file location
KANKA_OAUTH_BASE_URLNoOverride the OAuth host (for testing)
KANKA_OAUTH_CLIENT_IDNoOAuth app client id (register at app.kanka.io/settings/api-apps)
KANKA_OAUTH_TOKEN_FILENoWhere access + refresh tokens are persisted
KANKA_MAX_RESPONSE_BYTESNoHard cap on response body size
KANKA_RATE_LIMIT_PER_MINNoHard override on rate-limit bucket capacity
KANKA_REQUEST_TIMEOUT_MSNoPer-request HTTP timeout in milliseconds
KANKA_OAUTH_CLIENT_SECRETNoOAuth app client secret
KANKA_OAUTH_REDIRECT_PORTNoPin the loopback callback port

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
kanka_auth_statusA

Check whether the server has a usable Kanka credential and where it came from (env var, token file, OAuth, or none). Call this first if other tools return AUTH_REQUIRED — it'll tell you what's missing.

kanka_oauth_loginA

Run the OAuth 2.0 Authorization Code flow with PKCE. Opens a browser to the Kanka authorize page; on approval, persists access + refresh tokens to disk so subsequent tool calls authenticate transparently. Requires an OAuth app registered at https://app.kanka.io/settings/api?clients=1. Provide client_id/client_secret here or via KANKA_OAUTH_CLIENT_ID / KANKA_OAUTH_CLIENT_SECRET env vars.

kanka_auth_logoutA

Clear stored OAuth tokens (access + refresh). Personal API token configured via env or file is unaffected.

kanka_list_campaignsA

Discover which Kanka campaigns the authenticated user can access. Call this first to find the campaign_id you need for entity-level operations. Results are cached for 60 seconds — call again if you suspect campaigns were just created/removed in the Kanka UI.

kanka_get_campaignB

Fetch metadata for a single campaign by id.

kanka_describe_entity_typeA

Return the JSON Schema for the create/update payload of a Kanka entity type. Call this before kanka_create_entity or kanka_update_entity to discover required and optional fields.

kanka_searchA

Find entities by NAME within a campaign — fast, server-side, but matches names only (no entry/body text). Prefer this when you know the entity name. For matching against entry text, use kanka_full_text_search instead. For listing/browsing, use kanka_list_entities.

kanka_full_text_searchA

Search across the body text (entry HTML) of entities by paginating typed list endpoints, stripping HTML, and matching locally. Costs API budget — narrow types and lower max_pages_per_type to keep it cheap. Returns matches with a snippet around the hit.

kanka_list_entitiesA

Browse a campaign's entities. Use this to enumerate, page through, or filter by type / name / tags. For looking up a specific entity by id, prefer kanka_get_entity. For text-content search, use kanka_full_text_search.

Incremental sync: pass since (ISO 8601, e.g. the previous response's sync value) to receive only entities modified after that time. The response includes a sync token to use on the next call.

kanka_get_entityB

Fetch a single entity by either its type-scoped id (requires entity_type) OR its global entity_id. The dual-ID system is resolved transparently: if you only know entity_id, the resolver will discover the type and fetch the typed record.

kanka_create_entityA

Create a new entity. Call kanka_describe_entity_type first to discover the per-type schema for data. Returns the created record including its type-scoped id and global entity_id.

kanka_update_entityA

Partial update (PATCH) on an existing entity. Provide only the fields you want to change. The id is the type-scoped id (e.g. character id), not entity_id.

kanka_delete_entityA

Permanently delete an entity. Requires confirm: true to execute. Note: kanka_get_entity by entity_id may continue to succeed briefly via cache; pass an unknown entity_id to bust the resolver if needed.

kanka_postsA

List, read, create, update, or delete the posts (sub-notes) attached to an entity. Posts hang off the GLOBAL entity_id, not the type-scoped id. Provide action plus the relevant fields: list (page), get (id), create (data), update (id, data), delete (id, confirm: true).

kanka_relationsA

List, read, create, update, or delete relations between entities. Relations hang off the GLOBAL entity_id of the source. The target_id in data is the global entity_id of the destination. Set two_way: true to create reciprocal relations.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/torinvdb/kanka-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server