Skip to content

feat: Add typed response models and improve operation envelope handling#112

Merged
jfrench9 merged 4 commits into
mainfrom
feature/ops-docs
May 7, 2026
Merged

feat: Add typed response models and improve operation envelope handling#112
jfrench9 merged 4 commits into
mainfrom
feature/ops-docs

Conversation

@jfrench9
Copy link
Copy Markdown
Member

@jfrench9 jfrench9 commented May 7, 2026

Summary

Large-scale enhancement of the robosystems_client SDK to introduce strongly-typed response models across all API operations, refactor OperationEnvelope handling in both InvestorClient and LedgerClient, and add new domain models for taxonomy blocks, security response terms, statement mechanics, and legacy/schedule operations.

Key Accomplishments

Typed Response Models

  • Updated InvestorClient and LedgerClient to return typed response models instead of raw/untyped responses, improving developer experience and type safety across the entire client surface area.
  • Added new response models including: ArtifactResponse, AssociationResponse, ClosePeriodResponse, DeleteInformationBlockResponse, DeletePortfolioBlockResponse, DeleteTaxonomyBlockResponse, DeleteResult, EntityTaxonomyResponse, EvaluateRulesResponse, EventBlockEnvelope, EventHandlerResponse, and more.

New Domain Models

  • Taxonomy block structure: ClassificationLite, ConnectionLite, ElementLite, EntityLite and related entities for lightweight taxonomy representations.
  • Security response terms & statement mechanics: EntryTemplateRequest, EntryTemplateRequestEntryType, EvaluateRulesResponseSummary, and supporting models.
  • Legacy & schedule operations: CreateLegacyArm, DeleteLegacyArm, CreateScheduleArm, DeleteScheduleArm, CreateScheduleRequest, DeleteScheduleRequest with associated payload and block type models.

Refactored Operation Envelope Handling

  • Improved OperationEnvelope processing in both InvestorClient and LedgerClient for more consistent and robust response parsing.
  • Renamed OperationEnvelopeResultType0ArtifactResponseTemplateType0 to better reflect its purpose.

API Operation Updates

  • All 40+ operation modules across extensions_robo_investor, extensions_robo_ledger, graph_operations, and subscriptions have been updated to align with the new typed response patterns and envelope handling.
  • Updated existing request models (CreateAgentRequest, CreateEventBlockRequest, CreateSecurityRequest, DeleteJournalEntryRequest, etc.) to reflect schema changes.

Breaking Changes

  • Renamed models: OperationEnvelopeResultType0 has been renamed to ArtifactResponseTemplateType0.
  • Removed models: CreateInformationBlockRequest and DeleteInformationBlockRequestPayload have been removed/replaced by restructured models (CreateLegacyArm, DeleteLegacyArm, and their payloads).
  • Renamed/restructured models: UpdateInformationBlockRequest and UpdateInformationBlockRequestPayload have been replaced by DeleteLegacyArm and EventBlockEnvelopeMetadata respectively.
  • Client return types changed: Methods on InvestorClient and LedgerClient now return typed model instances rather than generic responses — callers relying on raw response structures will need to update.
  • Model __init__.py exports expanded significantly: ~382 lines of additions to the models package exports.

Testing Notes

  • Verify all client methods return correctly deserialized typed response models for both success and error cases.
  • Validate that renamed and restructured models serialize/deserialize correctly against the API schema.
  • Test legacy arm and schedule arm CRUD operations end-to-end with the new model structures.
  • Confirm backward compatibility is handled appropriately for consumers migrating from untyped responses.
  • Pay special attention to operations that previously used OperationEnvelopeResultType0 to ensure the rename to ArtifactResponseTemplateType0 is fully propagated.

Infrastructure Considerations

  • The models package has grown substantially (~229 files changed); ensure code generation tooling and CI pipelines accommodate the expanded model surface.
  • Downstream services and SDK consumers should be notified of breaking changes and given migration guidance, particularly around the removed/renamed models and the new typed return values from client methods.

🤖 Generated with Claude Code

Branch Info:

  • Source: feature/ops-docs
  • Target: main
  • Type: feature

Co-Authored-By: Claude noreply@anthropic.com

jfrench9 added 4 commits May 7, 2026 01:43
…, and legacy updates

- Introduced `SecurityResponseTerms` model to handle instrument-specific terms.
- Added `StatementMechanics` model for renderer mechanics related to various statement types.
- Created `UpdateLegacyArm` and `UpdateLegacyArmBlockType` models for handling updates to legacy arms.
- Implemented `UpdateLegacyArmPayload` model for untyped payloads in legacy updates.
- Developed `UpdateScheduleArm` and `UpdateScheduleRequest` models for schedule updates.
- Added `ValidationLite` and `VerificationResultLite` models for validation outcomes and verification results.
- Introduced `ViewProjections` model to manage different view projections at the envelope boundary.
- Introduced StructureSummary model to represent various report structures.
- Added TaxonomyBlockAssociation model for associations within taxonomy blocks.
- Created TaxonomyBlockElement model to represent elements in taxonomy.
- Implemented TaxonomyBlockElementOrigin enum for element provenance.
- Developed TaxonomyBlockEnvelope model to encapsulate taxonomy block data.
- Added TaxonomyBlockEnvelopeVerificationResultsItem model for verification results.
- Created TaxonomyBlockRule model to define rules for taxonomy blocks.
- Implemented TaxonomyBlockStructure model for structure definitions.
- Added TransactionPreview model for planned GL entry lines.
@jfrench9 jfrench9 merged commit fd64a67 into main May 7, 2026
1 check passed
@jfrench9 jfrench9 deleted the feature/ops-docs branch May 7, 2026 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant