# `SnakeBridge.CallbackRegistry`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L1)

Registry for Elixir callbacks passed to Python.

Manages callback lifecycle and provides invocation support.

# `child_spec`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L8)

Returns a specification to start this module under a supervisor.

See `Supervisor`.

# `ensure_tool_registered`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L60)

```elixir
@spec ensure_tool_registered(String.t() | nil) :: :ok
```

Ensures the callback tool is registered for the session.

# `handle_tool`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L86)

```elixir
@spec handle_tool(map()) :: map()
```

Handles callback tool invocations from Python.

# `invoke`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L44)

```elixir
@spec invoke(String.t(), list()) :: {:ok, term()} | {:error, term()}
```

Invokes a registered callback with arguments.

# `register`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L35)

```elixir
@spec register(function(), pid()) :: {:ok, String.t()}
```

Registers an Elixir function as a callback.

# `start_link`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L27)

# `unregister`
[🔗](https://github.com/nshkrdotcom/snakebridge/blob/v0.14.0/lib/snakebridge/callback_registry.ex#L52)

```elixir
@spec unregister(String.t()) :: :ok
```

Unregisters a callback.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
