Scan Code
scan_codeScan one code file before writing, committing, or merging it.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"content": "<content>"
},
"name": "scan_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | File path, e.g. "app.py" — used to pick language-aware rules. | |
| api_key | No | Your paid API key (required — or send it as an X-API-Key header, or set GATE_API_KEY once). Without a key no scan runs. With a key, each scan costs $0.05 after your first 20 free scans; out of credit returns payment instructions (USDC on Base) instead of a scan. | |
| content | Yes | The full file content to scan. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |