data
Directus MCP Integration for OpenAI Agents SDK
Connect Directus to OpenAI Agents SDK through the local KosmoKrator MCP gateway with scoped tools, credentials, and write policy.
Connect Directus to OpenAI Agents SDK
Attach KosmoKrator integration tools to OpenAI Agents SDK workflows through a local MCP gateway.
Start the KosmoKrator MCP gateway locally and point the OpenAI Agents SDK MCP tool at that process or wrapper. The gateway is local, scoped to this integration, and starts with
--write=deny so OpenAI Agents can inspect read-capable tools without receiving write access by default.
Directus MCP Config for OpenAI Agents SDK
Use headless JSON commands for CI-style execution and MCP for agent tool discovery.
{
"mcpServers": {
"kosmokrator-directus": {
"type": "stdio",
"command": "kosmo",
"args": [
"mcp:serve",
"--integration=directus",
"--write=deny"
]
}
}
} Run the Gateway Manually
kosmokrator mcp:serve --integration=directus --write=deny Why Use KosmoKrator Here
Expose only Directus instead of a broad multi-service tool list.
Reuse credentials already configured for the KosmoKrator CLI and Lua runtime.
Start read-only, then opt into ask or allow for trusted workspaces.
Directus Tools Visible to OpenAI Agents
OpenAI Agents sees stable MCP tool names generated from the Directus integration catalog.
| MCP tool | Source function | Type | Description |
|---|---|---|---|
integration__directus__directus_list_items | directus.directus_list_items | Read | List items in a Directus collection with optional filtering, sorting, and pagination. Returns an array of items from the specified collection. |
integration__directus__directus_get_item | directus.directus_get_item | Read | Retrieve a single item from a Directus collection by its primary key ID. |
integration__directus__directus_create_item | directus.directus_create_item | Write | Create a new item in a Directus collection with the provided field values. |
integration__directus__directus_update_item | directus.directus_update_item | Write | Update an existing item in a Directus collection by its primary key ID. |
integration__directus__directus_delete_item | directus.directus_delete_item | Write | Delete an item from a Directus collection by its primary key ID. This action cannot be undone. |
integration__directus__directus_list_collections | directus.directus_list_collections | Read | List all available collections (tables) in the Directus instance. Returns collection names and metadata. |
integration__directus__directus_get_current_user | directus.directus_get_current_user | Read | Get the profile of the currently authenticated Directus user. Useful for verifying the connection and understanding user permissions. |