Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
59921d0
chore: sync repo
stainless-app[bot] Feb 25, 2026
7879944
chore: update SDK settings
stainless-app[bot] Feb 25, 2026
c8f18fb
feat(api): fix(cli): allow plain string for --system flag in CLI
stainless-app[bot] Feb 25, 2026
387bc97
chore: zip READMEs as part of build artifact
stainless-app[bot] Feb 26, 2026
fdd332c
chore(internal): codegen related update
stainless-app[bot] Feb 26, 2026
c9e4450
chore(internal): codegen related update
stainless-app[bot] Feb 27, 2026
9099f84
chore(internal): codegen related update
stainless-app[bot] Mar 2, 2026
5f28d76
feat(tests): update mock server
stainless-app[bot] Mar 3, 2026
17fd9ac
codegen metadata
stainless-app[bot] Mar 4, 2026
f27a15a
chore(tests): unskip tests that are now supported in steady
stainless-app[bot] Mar 4, 2026
51d6aea
chore(internal): codegen related update
stainless-app[bot] Mar 5, 2026
5324c86
fix: fix for encoding arrays with `any` type items
stainless-app[bot] Mar 5, 2026
874b72d
fix(format): run go format
dtmeadows Mar 5, 2026
964b642
chore(internal): codegen related update
stainless-app[bot] Mar 7, 2026
4333cef
codegen metadata
stainless-app[bot] Mar 9, 2026
0275df0
fix: fix for test cases with newlines in YAML and better error reporting
stainless-app[bot] Mar 11, 2026
11ac26c
fix: only set client options when the corresponding CLI flag or env v…
stainless-app[bot] Mar 13, 2026
d11462b
fix: improved workflow for developing on branches
stainless-app[bot] Mar 16, 2026
bd11386
feat(api): GA thinking-display-setting
stainless-app[bot] Mar 16, 2026
0628e7c
chore(internal): codegen related update
stainless-app[bot] Mar 16, 2026
3983a85
fix: better support passing client args in any position
stainless-app[bot] Mar 16, 2026
efd44d0
fix: no longer require an API key when building on production repos
stainless-app[bot] Mar 16, 2026
109ba91
chore(internal): tweak CI branches
stainless-app[bot] Mar 16, 2026
dcb5ae2
fix: avoid reading from stdin unless request body is form encoded or …
stainless-app[bot] Mar 17, 2026
755a56f
codegen metadata
stainless-app[bot] Mar 18, 2026
913c2ac
chore(internal): regenerate SDK with no functional changes
stainless-app[bot] Mar 18, 2026
ea78613
fix: improve linking behavior when developing on a branch not in the …
stainless-app[bot] Mar 18, 2026
eedbcb0
chore(tests): bump steady to v0.19.4
stainless-app[bot] Mar 20, 2026
b037e4b
feat: add default description for enum CLI flags without an explicit …
stainless-app[bot] Mar 20, 2026
85f4306
chore(tests): bump steady to v0.19.5
stainless-app[bot] Mar 20, 2026
389d78b
chore(internal): update gitignore
stainless-app[bot] Mar 23, 2026
adc7010
chore(tests): bump steady to v0.19.6
stainless-app[bot] Mar 23, 2026
40af100
fix: cli no longer hangs when stdin is attached to a pipe with empty …
stainless-app[bot] Mar 23, 2026
4916eef
chore(ci): skip lint on metadata-only changes
stainless-app[bot] Mar 24, 2026
91c5fb6
chore(tests): bump steady to v0.19.7
stainless-app[bot] Mar 24, 2026
f83004b
codegen metadata
stainless-app[bot] Mar 26, 2026
a3861cf
feat: set CLI flag constant values automatically where `x-stainless-c…
stainless-app[bot] Mar 26, 2026
e357ef3
chore: omit full usage information when missing required CLI parameters
stainless-app[bot] Mar 26, 2026
2196f64
chore(internal): update multipart form array serialization
stainless-app[bot] Mar 26, 2026
1944a1d
fix: fix for off-by-one error in pagination logic
stainless-app[bot] Mar 27, 2026
62117e9
chore(ci): run builds on CI even if only spec metadata changed
stainless-app[bot] Mar 27, 2026
c7943b8
codegen metadata
stainless-app[bot] Mar 30, 2026
158978f
chore(tests): bump steady to v0.20.1
stainless-app[bot] Mar 31, 2026
fc343ef
chore(tests): bump steady to v0.20.2
stainless-app[bot] Mar 31, 2026
f3a3f4e
chore(internal): codegen related update
stainless-app[bot] Mar 31, 2026
a8c535e
fix: handle empty data set using `--format explore`
stainless-app[bot] Apr 1, 2026
1a48e03
fix: use `RawJSON` when iterating items with `--format explore` in th…
stainless-app[bot] Apr 1, 2026
0557352
codegen metadata
stainless-app[bot] Apr 1, 2026
2162128
chore(internal): codegen related update
stainless-app[bot] Apr 1, 2026
34be728
chore(cli): Claude Developer Platform -> Claude Platform
stainless-app[bot] Apr 1, 2026
50f35d4
release: 0.1.0-alpha.1
stainless-app[bot] Apr 1, 2026
c06d796
feat: full GitHub Actions to Dagger migration
Apr 1, 2026
3185350
feat: Dagger implementation following official SDK patterns
Apr 2, 2026
0bfd822
fix: Dagger module source resolution and QA fixes
Apr 2, 2026
4b7bd99
feat: add Dagger CI/CD module with conformance tests
Apr 2, 2026
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
4 changes: 4 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# This file is used to automatically assign reviewers to PRs
# For more information see: https://help.github.com/en/github/creating-cloning-and-archiving-repositories/about-code-owners

* @anthropics/sdk
29 changes: 29 additions & 0 deletions .github/actions/setup-go/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Setup Go
description: 'Sets up Go environment with private modules'
inputs:
stainless-api-key:
required: false
description: the value of the STAINLESS_API_KEY secret
runs:
using: composite
steps:
- uses: stainless-api/retrieve-github-access-token@v1
if: github.repository == 'stainless-sdks/anthropic-cli'
id: get_token
with:
repo: stainless-sdks/anthropic-go
stainless-api-key: ${{ inputs.stainless-api-key }}

- name: Configure Git for access to the Go SDK's staging repo
if: github.repository == 'stainless-sdks/anthropic-cli'
shell: bash
run: git config --global url."https://x-access-token:${{ steps.get_token.outputs.github_access_token }}@github.com/stainless-sdks/anthropic-go".insteadOf "https://github.com/stainless-sdks/anthropic-go"

- name: Setup go
uses: actions/setup-go@v5
with:
go-version-file: ./go.mod

- name: Bootstrap
shell: bash
run: ./scripts/bootstrap
164 changes: 164 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
name: CI
on:
push:
branches:
- '**'
- '!integrated/**'
- '!stl-preview-head/**'
- '!stl-preview-base/**'
- '!generated'
- '!codegen/**'
- 'codegen/stl/**'
pull_request:
branches-ignore:
- 'stl-preview-head/**'
- 'stl-preview-base/**'

env:
GOPRIVATE: github.com/anthropics/anthropic-sdk-go,github.com/stainless-sdks/anthropic-go

jobs:
lint:
timeout-minutes: 10
name: lint
runs-on: ${{ github.repository == 'stainless-sdks/anthropic-cli' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork)

steps:
- uses: actions/checkout@v6

- uses: ./.github/actions/setup-go
with:
stainless-api-key: ${{ secrets.STAINLESS_API_KEY }}

- name: Link staging branch
if: github.repository == 'stainless-sdks/anthropic-cli'
run: |
./scripts/link 'github.com/stainless-sdks/anthropic-go@${{ github.ref_name }}' || true

- name: Bootstrap
run: ./scripts/bootstrap

- name: Run lints
run: ./scripts/lint

build:
timeout-minutes: 10
name: build
permissions:
contents: read
id-token: write
runs-on: ${{ github.repository == 'stainless-sdks/anthropic-cli' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork)
steps:
- uses: actions/checkout@v6

- uses: ./.github/actions/setup-go
with:
stainless-api-key: ${{ secrets.STAINLESS_API_KEY }}

- name: Link staging branch
if: github.repository == 'stainless-sdks/anthropic-cli'
run: |
./scripts/link 'github.com/stainless-sdks/anthropic-go@${{ github.ref_name }}' || true

- name: Bootstrap
run: ./scripts/bootstrap

- name: Run goreleaser
uses: goreleaser/goreleaser-action@v6.1.0
with:
version: latest
args: release --snapshot --clean --skip=publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Get GitHub OIDC Token
if: |-
github.repository == 'stainless-sdks/anthropic-cli' &&
!startsWith(github.ref, 'refs/heads/stl/')
id: github-oidc
uses: actions/github-script@v8
with:
script: core.setOutput('github_token', await core.getIDToken());

- name: Upload tarball
if: |-
github.repository == 'stainless-sdks/anthropic-cli' &&
!startsWith(github.ref, 'refs/heads/stl/')
env:
URL: https://pkg.stainless.com/s
AUTH: ${{ steps.github-oidc.outputs.github_token }}
SHA: ${{ github.sha }}
run: ./scripts/utils/upload-artifact.sh

- name: Upload cdp-darwin-arm64
uses: actions/upload-artifact@v4
with:
name: cdp-darwin-arm64
path: dist/macos_darwin_arm64*/cdp
retention-days: 90
if-no-files-found: ignore

- name: Upload cdp-darwin-amd64
uses: actions/upload-artifact@v4
with:
name: cdp-darwin-amd64
path: dist/macos_darwin_amd64*/cdp
retention-days: 90
if-no-files-found: ignore

- name: Upload cdp-linux-amd64
uses: actions/upload-artifact@v4
with:
name: cdp-linux-amd64
path: dist/linux_linux_amd64*/cdp
retention-days: 90
if-no-files-found: ignore

- name: Upload cdp-linux-arm64
uses: actions/upload-artifact@v4
with:
name: cdp-linux-arm64
path: dist/linux_linux_arm64*/cdp
retention-days: 90
if-no-files-found: ignore

- name: Upload cdp-windows-amd64
uses: actions/upload-artifact@v4
with:
name: cdp-windows-amd64
path: dist/windows_windows_amd64*/cdp.exe
retention-days: 90
if-no-files-found: ignore

- name: Upload cdp-windows-arm64
uses: actions/upload-artifact@v4
with:
name: cdp-windows-arm64
path: dist/windows_windows_arm64*/cdp.exe
retention-days: 90
if-no-files-found: ignore

test:
timeout-minutes: 20
name: test
runs-on: ${{ github.repository == 'stainless-sdks/anthropic-cli' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
steps:
- uses: actions/checkout@v6

- uses: ./.github/actions/setup-go
with:
stainless-api-key: ${{ secrets.STAINLESS_API_KEY }}

- name: Link staging branch
if: github.repository == 'stainless-sdks/anthropic-cli'
run: |
./scripts/link 'github.com/stainless-sdks/anthropic-go@${{ github.ref_name }}' || true

- name: Bootstrap
run: ./scripts/bootstrap

- name: Run tests
run: ./scripts/test
57 changes: 57 additions & 0 deletions .github/workflows/claude-code-review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Claude Code Review

on:
pull_request:
types: [opened, synchronize]
# Optional: Only run on specific file changes
# paths:
# - "src/**/*.ts"
# - "src/**/*.tsx"
# - "src/**/*.js"
# - "src/**/*.jsx"

jobs:
claude-review:
# Optional: Filter by PR author
# if: |
# github.event.pull_request.user.login == 'external-contributor' ||
# github.event.pull_request.user.login == 'new-developer' ||
# github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR'

runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
issues: read
id-token: write

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Run Claude Code Review
id: claude-review
uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
REPO: ${{ github.repository }}
PR NUMBER: ${{ github.event.pull_request.number }}

Please review this pull request and provide feedback on:
- Code quality and best practices
- Potential bugs or issues
- Performance considerations
- Security concerns
- Test coverage

Use the repository's CLAUDE.md for guidance on style and conventions. Be constructive and helpful in your feedback.

Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR.

# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
# or https://code.claude.com/docs/en/cli-reference for available options
claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"'

50 changes: 50 additions & 0 deletions .github/workflows/claude.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Claude Code

on:
issue_comment:
types: [created]
pull_request_review_comment:
types: [created]
issues:
types: [opened, assigned]
pull_request_review:
types: [submitted]

jobs:
claude:
if: |
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude')) ||
(github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude')) ||
(github.event_name == 'issues' && (contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude')))
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: read
issues: read
id-token: write
actions: read # Required for Claude to read CI results on PRs
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Run Claude Code
id: claude
uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}

# This is an optional setting that allows Claude to read CI results on PRs
additional_permissions: |
actions: read

# Optional: Give a custom prompt to Claude. If this is not specified, Claude will perform the instructions specified in the comment that tagged it.
# prompt: 'Update the pull request description to include a summary of changes.'

# Optional: Add claude_args to customize behavior and configuration
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
# or https://code.claude.com/docs/en/cli-reference for available options
# claude_args: '--allowed-tools Bash(gh pr:*)'

38 changes: 38 additions & 0 deletions .github/workflows/create-releases.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Create releases
on:
schedule:
- cron: '0 5 * * *' # every day at 5am UTC
push:
branches:
- main

jobs:
release:
name: release
if: github.ref == 'refs/heads/main' && github.repository == 'anthropics/anthropic-cli'
runs-on: ubuntu-latest
environment: production-release
permissions:
contents: write

steps:
- uses: actions/checkout@v6

- uses: stainless-api/trigger-release-please@v1
id: release
with:
repo: ${{ github.event.repository.full_name }}
stainless-api-key: ${{ secrets.STAINLESS_API_KEY }}

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: "go.mod"
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6.1.0
with:
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
HOMEBREW_TAP_GITHUB_TOKEN: ${{ secrets.HOMEBREW_TAP_GITHUB_TOKEN }}
45 changes: 45 additions & 0 deletions .github/workflows/dagger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Dagger CI

on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:

env:
DAGGER_CLOUD_TOKEN: ${{ secrets.DAGGER_CLOUD_TOKEN }}

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Lint
uses: dagger/dagger-for-github@v8.4.0
with:
version: "latest"
call: lint --source=.
cloud-token: ${{ secrets.DAGGER_CLOUD_TOKEN }}

test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Test
uses: dagger/dagger-for-github@v8.4.0
with:
version: "latest"
call: test --source=.
cloud-token: ${{ secrets.DAGGER_CLOUD_TOKEN }}

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build All
uses: dagger/dagger-for-github@v8.4.0
with:
version: "latest"
call: build-all --source=.
cloud-token: ${{ secrets.DAGGER_CLOUD_TOKEN }}
Loading