# {{ package_name }}

{{ display_name }} MCP (Model Context Protocol) server, generated by [mcpify](https://github.com/guercheLE/mcpify).

Exposes exactly 3 tools — `search`, `get`, `call` — backed by an embedded semantic database (`mcp_store.db`), so an LLM never needs the full API surface in context.

## Install

```bash
cargo build --release
```

## Setup

```bash
cargo run -- setup
```

Interactively collects the API URL and the credentials your chosen auth method needs, then lets you persist them as a `.env` file, a `config.json` file, or a ready-to-run CLI invocation.

## Usage

### Terminal Client (default)

```bash
{{ project_name }} search "create an issue"
{{ project_name }} get <operationId>
{{ project_name }} call <operationId> --some-arg value
```

### Harness Server

```bash
{{ project_name }} start                              # stdio transport (default)
{{ project_name }} http --host 127.0.0.1 --port 3000  # HTTP transport
```

## Testing

```bash
cargo test
```

## Coverage

```bash
bash scripts/coverage.sh   # writes target/coverage/html/index.html (requires cargo-llvm-cov)
```

## Profiling

```bash
bash scripts/profile.sh   # CPU profiling via samply, writes profile/bottleneck-report.md
cargo run --release --features profiling -- search "test query"   # heap profiling via dhat-rs, writes dhat-heap.json
```

`profile/bottleneck-report.md` combines coverage gaps with the hottest CPU functions in one small text file — paste it into an LLM (or hand it to another tool) to find and fix bottlenecks. Requires [samply](https://github.com/mstange/samply) (`cargo install samply`).

---

Generated by mcpify — do not hand-edit generated files; re-run mcpify against an updated OpenAPI spec instead.
