Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.2.0"
".": "0.2.1"
}
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

## 0.2.1 (2026-05-08)

Full Changelog: [v0.2.0...v0.2.1](https://github.com/matrices/cerca-cli/compare/v0.2.0...v0.2.1)

### Chores

* redact api-key headers in debug logs ([e64047f](https://github.com/matrices/cerca-cli/commit/e64047f3895aee6c901a0e949410de72fc62484b))
* **test:** scope body requests to a single variant ([ae7d57b](https://github.com/matrices/cerca-cli/commit/ae7d57bf224a53df2f7231b806361c4ba86033a2))

## 0.2.0 (2026-05-07)

Full Changelog: [v0.1.0...v0.2.0](https://github.com/matrices/cerca-cli/compare/v0.1.0...v0.2.0)
Expand Down
7 changes: 6 additions & 1 deletion internal/debugmiddleware/debug_middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ const redactedPlaceholder = "<REDACTED>"

// Headers known to contain sensitive information like an API key. Note that this exclude `Authorization`,
// which is handled specially in `redactRequest` below.
var sensitiveHeaders = []string{}
var sensitiveHeaders = []string{
"api-key",
"x-api-key",
"cookie",
"set-cookie",
}

// RequestLogger is a middleware that logs HTTP requests and responses.
type RequestLogger struct {
Expand Down
4 changes: 0 additions & 4 deletions pkg/cmd/tool.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ var toolsCreate = requestflag.WithInnerFlags(cli.Command{
},
&requestflag.Flag[[]map[string]any]{
Name: "tool",
Required: true,
BodyPath: "tools",
},
&requestflag.Flag[string]{
Expand All @@ -63,7 +62,6 @@ var toolsCreate = requestflag.WithInnerFlags(cli.Command{
},
&requestflag.Flag[string]{
Name: "url",
Required: true,
BodyPath: "url",
},
},
Expand Down Expand Up @@ -174,7 +172,6 @@ var toolsUpdate = requestflag.WithInnerFlags(cli.Command{
},
&requestflag.Flag[[]map[string]any]{
Name: "tool",
Required: true,
BodyPath: "tools",
},
&requestflag.Flag[string]{
Expand All @@ -200,7 +197,6 @@ var toolsUpdate = requestflag.WithInnerFlags(cli.Command{
},
&requestflag.Flag[string]{
Name: "url",
Required: true,
BodyPath: "url",
},
},
Expand Down
10 changes: 2 additions & 8 deletions pkg/cmd/tool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ func TestToolsCreate(t *testing.T) {
"--approval", "always",
"--enabled=true",
"--execution", "{idempotencyKeyHeader: idempotencyKeyHeader, maxAttempts: 3, retryMode: safe_only, timeoutMs: 10000}",
"--url", "https://mcp.example.com",
)
})

Expand Down Expand Up @@ -53,7 +52,6 @@ func TestToolsCreate(t *testing.T) {
"--execution.max-attempts", "3",
"--execution.retry-mode", "safe_only",
"--execution.timeout-ms", "10000",
"--url", "https://mcp.example.com",
)
})

Expand Down Expand Up @@ -93,8 +91,7 @@ func TestToolsCreate(t *testing.T) {
" idempotencyKeyHeader: idempotencyKeyHeader\n" +
" maxAttempts: 3\n" +
" retryMode: safe_only\n" +
" timeoutMs: 10000\n" +
"url: https://mcp.example.com\n")
" timeoutMs: 10000\n")
mocktest.TestRunMockTestWithPipeAndFlags(
t, pipeData,
"--api-key", "string",
Expand Down Expand Up @@ -131,7 +128,6 @@ func TestToolsUpdate(t *testing.T) {
"--approval", "always",
"--enabled=true",
"--execution", "{idempotencyKeyHeader: idempotencyKeyHeader, maxAttempts: 3, retryMode: safe_only, timeoutMs: 10000}",
"--url", "https://mcp.example.com",
)
})

Expand Down Expand Up @@ -162,7 +158,6 @@ func TestToolsUpdate(t *testing.T) {
"--execution.max-attempts", "3",
"--execution.retry-mode", "safe_only",
"--execution.timeout-ms", "10000",
"--url", "https://mcp.example.com",
)
})

Expand Down Expand Up @@ -202,8 +197,7 @@ func TestToolsUpdate(t *testing.T) {
" idempotencyKeyHeader: idempotencyKeyHeader\n" +
" maxAttempts: 3\n" +
" retryMode: safe_only\n" +
" timeoutMs: 10000\n" +
"url: https://mcp.example.com\n")
" timeoutMs: 10000\n")
mocktest.TestRunMockTestWithPipeAndFlags(
t, pipeData,
"--api-key", "string",
Expand Down
2 changes: 1 addition & 1 deletion pkg/cmd/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

package cmd

const Version = "0.2.0" // x-release-please-version
const Version = "0.2.1" // x-release-please-version
Loading