KosmoKrator

marketing

Bitly MCP Integration for OpenAI Agents SDK

Connect Bitly to OpenAI Agents SDK through the local KosmoKrator MCP gateway with scoped tools, credentials, and write policy.

8 functions 5 read 3 write Bearer token auth

Connect Bitly 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.

Bitly MCP Config for OpenAI Agents SDK

Use headless JSON commands for CI-style execution and MCP for agent tool discovery.

{
  "mcpServers": {
    "kosmokrator-bitly": {
      "type": "stdio",
      "command": "kosmo",
      "args": [
        "mcp:serve",
        "--integration=bitly",
        "--write=deny"
      ]
    }
  }
}

Run the Gateway Manually

kosmokrator mcp:serve --integration=bitly --write=deny

Why Use KosmoKrator Here

Scoped tools

Expose only Bitly instead of a broad multi-service tool list.

Local credentials

Reuse credentials already configured for the KosmoKrator CLI and Lua runtime.

Write policy

Start read-only, then opt into ask or allow for trusted workspaces.

Bitly Tools Visible to OpenAI Agents

OpenAI Agents sees stable MCP tool names generated from the Bitly integration catalog.

MCP toolSource functionTypeDescription
integration__bitly__bitly_shorten_link bitly.bitly_shorten_link Write Shorten a long URL into a Bitlink. Returns the shortened URL and link details.
integration__bitly__bitly_get_link bitly.bitly_get_link Read Retrieve details for a Bitlink, including the long URL, title, tags, and timestamps.
integration__bitly__bitly_update_link bitly.bitly_update_link Write Update a Bitlink's metadata — set the title, archive/unarchive, or update tags.
integration__bitly__bitly_get_clicks bitly.bitly_get_clicks Read Get click metrics for a Bitlink. Returns click counts by time unit (minute, hour, day, week, month).
integration__bitly__bitly_list_groups bitly.bitly_list_groups Read List all groups in the Bitly account. Groups organize links and are used when creating new Bitlinks.
integration__bitly__bitly_get_group bitly.bitly_get_group Read Retrieve details for a specific Bitly group by its GUID.
integration__bitly__bitly_create_bitlink bitly.bitly_create_bitlink Write Create a new Bitlink with title, tags, and optional custom domain. More full-featured than shorten — use this when you need metadata.
integration__bitly__bitly_get_current_user bitly.bitly_get_current_user Read Get the authenticated Bitly user's profile. Use this to verify the connection and see account info.

Related Bitly Pages