Skip to content

release: 0.7.8#23

Merged
ktanishqk merged 24 commits into
mainfrom
release-please--branches--main--changes--next
Apr 8, 2026
Merged

release: 0.7.8#23
ktanishqk merged 24 commits into
mainfrom
release-please--branches--main--changes--next

Conversation

@stainless-app
Copy link
Copy Markdown
Contributor

@stainless-app stainless-app Bot commented Apr 8, 2026

Automated Release PR

0.7.8 (2026-04-08)

Full Changelog: v0.7.7...v0.7.8

Features

  • allow - as value representing stdin to binary-only file parameters in CLIs (4fb771a)
  • api: api update (89f41fe)
  • api: api update (606036f)
  • api: api update (5620db5)
  • api: api update (7d1c53a)
  • api: api update (8a097fc)
  • api: manual updates (e70a1d2)
  • api: manual updates (35c4f7d)
  • api: manual updates (990b138)
  • better error message if scheme forgotten in CLI *_BASE_URL/--base-url (57e1a52)
  • binary-only parameters become CLI flags that take filenames only (1b23d84)

Bug Fixes

  • fall back to main branch if linking fails in CI (eb15535)
  • fix quoting typo (6d8d3f4)
  • handle empty data set using --format explore (2852394)
  • use RawJSON when iterating items with --format explore in the CLI (13259ac)
  • use RELEASE_PAT to approve and auto-merge release PRs (dacdd81)

Chores

  • internal: codegen related update (792c2ce)
  • mark all CLI-related tests in Go with t.Parallel() (132e0f5)
  • modify CLI tests to inject stdout so mutating os.Stdout isn't necessary (f488623)
  • switch some CLI Go tests from os.Chdir to t.Chdir (6f4709d)
  • update SDK settings (628d088)

This pull request is managed by Stainless's GitHub App.

The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.

For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.

🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions


Summary by cubic

Release 0.7.8 expands the CLI with new list and API key management commands, improves file and JSON handling, and adds stricter base URL validation. It also fixes edge cases in the explore viewer and improves CI reliability.

  • New Features

    • Added list management: lists, inboxes:lists, and pods:lists (create/retrieve/list/delete).
    • Added API key commands: inboxes:api-keys and pods:api-keys (create/retrieve/list/delete).
    • Added pods:metrics query, domain updates (domains update, pods:domains retrieve/update), draft attachment download (drafts get-attachment, inboxes:drafts get-attachment, pods:drafts get-attachment), and thread deletion (threads delete, pods:threads delete).
    • Binary-only params are now filename flags; support - to read from stdin.
    • Base URL validation for --base-url and AGENTMAIL_BASE_URL with clear errors if scheme is missing.
    • --format explore improved with better table rendering and raw JSON handling.
    • Bumped SDK to github.com/agentmail-to/agentmail-go v0.6.0.
  • Bug Fixes

    • --format explore now handles empty datasets and iterates items via RawJSON.
    • CI falls back to main branch when linking fails; minor quoting fix.
    • Release PRs approved/merged via dedicated token.

Written for commit 559d9c4. Summary will update on new commits.

@stainless-app stainless-app Bot force-pushed the release-please--branches--main--changes--next branch from 559d9c4 to 11b16d2 Compare April 8, 2026 04:59
@stainless-app
Copy link
Copy Markdown
Contributor Author

stainless-app Bot commented Apr 8, 2026

🧪 Testing

To try out this version of the SDK:

Download and unzip: 'https://pkg.stainless.com/s/agentmail-cli/628d088add60a690cc24e460ad02fa375b82e651/dist.zip'. On macOS, run 'xattr -d com.apple.quarantine {executable name}'.

Expires at: Fri, 08 May 2026 05:00:59 GMT
Updated at: Wed, 08 Apr 2026 05:00:59 GMT

@ktanishqk ktanishqk merged commit f266b9d into main Apr 8, 2026
7 checks passed
@ktanishqk ktanishqk deleted the release-please--branches--main--changes--next branch April 8, 2026 05:04
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

5 issues found across 59 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="pkg/cmd/flagoptions.go">

<violation number="1" location="pkg/cmd/flagoptions.go:145">
P1: `FilePathValue` ignores `EmbedIOReader` and coerces files to strings, causing multipart file inputs to be encoded as text fields instead of file parts.</violation>
</file>

<file name="pkg/cmd/flagoptions_test.go">

<violation number="1" location="pkg/cmd/flagoptions_test.go:16">
P2: Parallel subtests in this range loop capture the reused `tt` variable, which can cause subtests to read the wrong inputs. Capture `tt` inside the loop before launching parallel subtests.</violation>
</file>

<file name="pkg/cmd/cmdutil.go">

<violation number="1" location="pkg/cmd/cmdutil.go:211">
P2: Terminal detection still uses `os.Stdout` instead of the injected `stdout`, so output behavior can diverge when a custom writer is passed.</violation>
</file>

<file name="pkg/cmd/podthread.go">

<violation number="1" location="pkg/cmd/podthread.go:20">
P3: The command usage string is a placeholder (`"**CLI:**"`) instead of an actionable description, which degrades `--help` output for this command.</violation>
</file>

<file name="pkg/cmd/podmetric_test.go">

<violation number="1" location="pkg/cmd/podmetric_test.go:12">
P2: This test is unconditionally skipped, so the rest of the test is unreachable and will never run. If you only want to skip in specific cases, gate the skip behind a condition (e.g., short tests) or remove it so coverage isn’t silently lost.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review, or fix all with cubic.

Comment thread pkg/cmd/flagoptions.go
Comment on lines +145 to +156
if isStdinPath(s) {
content, err := stdin.readAll()
if err != nil {
return v, err
}
return reflect.ValueOf(string(content)), nil
}
content, err := os.ReadFile(s)
if err != nil {
return v, err
}
return reflect.ValueOf(string(content)), nil
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: FilePathValue ignores EmbedIOReader and coerces files to strings, causing multipart file inputs to be encoded as text fields instead of file parts.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At pkg/cmd/flagoptions.go, line 145:

<comment>`FilePathValue` ignores `EmbedIOReader` and coerces files to strings, causing multipart file inputs to be encoded as text fields instead of file parts.</comment>

<file context>
@@ -98,6 +134,28 @@ func embedFilesValue(v reflect.Value, embedStyle FileEmbedStyle) (reflect.Value,
+			if s == "" {
+				return v, nil
+			}
+			if isStdinPath(s) {
+				content, err := stdin.readAll()
+				if err != nil {
</file context>
Suggested change
if isStdinPath(s) {
content, err := stdin.readAll()
if err != nil {
return v, err
}
return reflect.ValueOf(string(content)), nil
}
content, err := os.ReadFile(s)
if err != nil {
return v, err
}
return reflect.ValueOf(string(content)), nil
if isStdinPath(s) {
content, err := stdin.readAll()
if err != nil {
return v, err
}
if embedStyle == EmbedIOReader {
return reflect.ValueOf(io.NopCloser(bytes.NewReader(content))), nil
}
return reflect.ValueOf(string(content)), nil
}
if embedStyle == EmbedIOReader {
file, err := os.Open(s)
if err != nil {
return v, err
}
return reflect.ValueOf(file), nil
}
content, err := os.ReadFile(s)
if err != nil {
return v, err
}
return reflect.ValueOf(string(content)), nil
Fix with Cubic

)

func TestIsUTF8TextFile(t *testing.T) {
t.Parallel()
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Parallel subtests in this range loop capture the reused tt variable, which can cause subtests to read the wrong inputs. Capture tt inside the loop before launching parallel subtests.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At pkg/cmd/flagoptions_test.go, line 16:

<comment>Parallel subtests in this range loop capture the reused `tt` variable, which can cause subtests to read the wrong inputs. Capture `tt` inside the loop before launching parallel subtests.</comment>

<file context>
@@ -2,15 +2,19 @@ package cmd
 )
 
 func TestIsUTF8TextFile(t *testing.T) {
+	t.Parallel()
+
 	tests := []struct {
</file context>
Fix with Cubic

Comment thread pkg/cmd/cmdutil.go
// writeBinaryResponse writes a binary response to stdout or a file.
//
// Takes in a stdout reference so we can test this function without overriding os.Stdout in tests.
func writeBinaryResponse(response *http.Response, stdout io.Writer, outfile string) (string, error) {
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: Terminal detection still uses os.Stdout instead of the injected stdout, so output behavior can diverge when a custom writer is passed.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At pkg/cmd/cmdutil.go, line 211:

<comment>Terminal detection still uses `os.Stdout` instead of the injected `stdout`, so output behavior can diverge when a custom writer is passed.</comment>

<file context>
@@ -196,21 +205,24 @@ func streamToStdout(generateOutput func(w *os.File) error) error {
+// writeBinaryResponse writes a binary response to stdout or a file.
+//
+// Takes in a stdout reference so we can test this function without overriding os.Stdout in tests.
+func writeBinaryResponse(response *http.Response, stdout io.Writer, outfile string) (string, error) {
 	defer response.Body.Close()
 	body, err := io.ReadAll(response.Body)
</file context>
Fix with Cubic

Comment thread pkg/cmd/podmetric_test.go
)

func TestPodsMetricsQuery(t *testing.T) {
t.Skip("Mock server tests are disabled")
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This test is unconditionally skipped, so the rest of the test is unreachable and will never run. If you only want to skip in specific cases, gate the skip behind a condition (e.g., short tests) or remove it so coverage isn’t silently lost.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At pkg/cmd/podmetric_test.go, line 12:

<comment>This test is unconditionally skipped, so the rest of the test is unreachable and will never run. If you only want to skip in specific cases, gate the skip behind a condition (e.g., short tests) or remove it so coverage isn’t silently lost.</comment>

<file context>
@@ -0,0 +1,27 @@
+)
+
+func TestPodsMetricsQuery(t *testing.T) {
+	t.Skip("Mock server tests are disabled")
+	t.Run("regular flags", func(t *testing.T) {
+		mocktest.TestRunMockTestWithFlags(
</file context>
Fix with Cubic

Comment thread pkg/cmd/podthread.go
var podsThreadsRetrieve = cli.Command{
Name: "retrieve",
Usage: "Get Thread",
Usage: "**CLI:**",
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: The command usage string is a placeholder ("**CLI:**") instead of an actionable description, which degrades --help output for this command.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At pkg/cmd/podthread.go, line 20:

<comment>The command usage string is a placeholder (`"**CLI:**"`) instead of an actionable description, which degrades `--help` output for this command.</comment>

<file context>
@@ -17,7 +17,7 @@ import (
 var podsThreadsRetrieve = cli.Command{
 	Name:    "retrieve",
-	Usage:   "Get Thread",
+	Usage:   "**CLI:**",
 	Suggest: true,
 	Flags: []cli.Flag{
</file context>
Suggested change
Usage: "**CLI:**",
Usage: "Get Thread",
Fix with Cubic

@stainless-app
Copy link
Copy Markdown
Contributor Author

stainless-app Bot commented Apr 8, 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant