Conversation
Persist server URL and default_org in GlobalConfig during identity registration Parse direct ApiError bodies and centralize HTTP status → RemoteError mapping Add serde aliases for renamed fields and switch teams endpoints to org-scoped paths. Generate org slugs client-side (slugify) and update tests for visibility and field name casing
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.
This pull request makes several improvements and breaking changes to how organizations and teams are handled, focusing on org-scoped base URLs/subdomains, API request/response consistency, and error handling. The most important changes include switching team and team member routes to be org-scoped via the client’s base URL, updating serialization to use
snake_casefor project requests, improving error parsing, and adding slug handling for organizations.Organization and Team Routing (org-scoped base URLs)
Organization Creation and Slug Handling
slugifyfunction to ensure consistent slugs. TheCreateOrgRequeststruct and related tests were updated to require and verify the slug field. [1] [2] [3]API Request/Response Consistency
CreateProjectRequestandUpdateProjectRequestto usesnake_caseinstead ofcamelCase, and updated tests to match. [1] [2] [3] [4]serdealiases to struct fields inResponseMetadata,WorkspaceInfo, andProjectInfoto support both camelCase and snake_case field names in API responses, improving compatibility. [1] [2] [3]Error Handling Improvements
StorageClientto handle bothApiResponseand directApiErrorbodies, with a newstatus_errorhelper for consistent error mapping.Miscellaneous
snake_casefield names in JSON serialization for team members and org members. [1] [2]These changes are breaking for any consumer relying on the previous team and team member path structure or camelCase project request fields. Be sure to update clients and integrations accordingly.Persist server URL and default_org in GlobalConfig during identity registration
Parse direct ApiError bodies and centralize HTTP status → RemoteError mapping
Add serde aliases for renamed fields and switch teams endpoints to org-scoped
paths. Generate org slugs client-side (slugify) and update tests for visibility and
field name casing