fix(sdk): include display_name field in Project type generation#1508
Closed
fix(sdk): include display_name field in Project type generation#1508
Conversation
The TypeScript and Python SDK Project types were stale and missing the display_name field that was already defined in the OpenAPI spec. Regenerated the Project type files for all three SDKs (Go already had the field from a prior regeneration). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
✅ Deploy Preview for cheerful-kitten-f556a0 canceled.
|
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
5 tasks
Contributor
Author
|
Superseded by #1513 (consolidated SDK PR with full regeneration) |
markturansky
pushed a commit
that referenced
this pull request
May 7, 2026
…fields (#1513) ## Summary Consolidates #1508 and #1509 into a single PR with full SDK regeneration. - **TS SDK templates**: Make `token` and `project` optional in `AmbientClientConfig` (browser support) - **TS SDK templates**: Accept relative `baseUrl` (e.g. `/api/proxy`), reject protocol-relative URLs (`//`) - **TS SDK templates**: Sub-resource APIs throw clear error when `project` is needed but absent - **Go SDK**: Alphabetize `ScheduledSessionPatch` fields, add `AgentID` validation in builder - **All SDKs**: Full regeneration needed to pick up `display_name` on Project and latest spec changes Supersedes #1508 and #1509. ## Test plan - [x] TS SDK tests updated (browser mode, relative URL, protocol-relative rejection) - [ ] `make build-generator && make generate-sdk` completes - [ ] `make verify-sdk` passes (no drift) - [ ] Go SDK compiles with CLI - [ ] TS SDK tests pass (45 tests) ## Post-merge After regeneration, watch for Go extension file conflicts (`agent_extensions.go`, `session_messages.go`) that depend on client methods. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: jsell-rh <bot@ambient-code.local> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
display_namefield that was defined in the OpenAPI spec but missing from generated outputdisplay_namefrom a prior regeneration; its file is updated with the current spec hash/timestamp onlyextractFields()function ingenerator/parser.gocorrectly handlesallOfcomposition; the TS/Python outputs were simply staleRoot Cause
The TS and Python SDK outputs were last generated on 2026-03-21 (spec SHA
9a8e623...), while the Go SDK was regenerated on 2026-04-18 (spec SHA97773951...). Thedisplay_namefield has been inopenapi.projects.yamlsince its initial commit, but the TS/Python type files were never regenerated to pick it up.Changes
ts-sdk/src/project.tsdisplay_nametoProject,ProjectCreateRequest,ProjectPatchRequest,ProjectBuilder,ProjectPatchBuilderpython-sdk/ambient_platform/project.pydisplay_nametoProjectdataclass,from_dict(),ProjectBuilder,ProjectPatchgo-sdk/types/project.goTest plan
go build ./types/...)from ambient_platform.project import Project)Project.from_dict({'display_name': 'test'})returns correct valuegofmtpasses on modified Go filesdisplay_nameappears in all three SDK Project type files🤖 Generated with Claude Code