Skip to content

feat: regenerate API schemas to add Robinhood Chain network#28

Open
jiyuu-jin wants to merge 1 commit into
stakekit:mainfrom
jiyuu-jin:feat/robinhood-network
Open

feat: regenerate API schemas to add Robinhood Chain network#28
jiyuu-jin wants to merge 1 commit into
stakekit:mainfrom
jiyuu-jin:feat/robinhood-network

Conversation

@jiyuu-jin

@jiyuu-jin jiyuu-jin commented Jul 15, 2026

Copy link
Copy Markdown

Summary

Robinhood Chain (network identifier robinhood, EVM chain ID 4663, an Arbitrum Orbit L2) is live in the yield.xyz API with vaults from Steakhouse (Morpho V2), Midas, and Spark — see https://docs.yield.xyz/docs/robinhood. The SDK's generated network enums predate the launch, so consumers currently get a type error passing network: 'robinhood' to getYields() even though the API accepts it.

This PR is a pure pnpm generate-api regeneration against the published OpenAPI spec (clean: true, per orval.config.ts) — no hand-written code. The only manual addition is the changeset (patch, matching past schema-regeneration changesets like #24).

robinhood and robinhood-testnet now appear in all network enums: Networks, NetworkDtoId, YieldsControllerGetYieldsNetwork, YieldQueryDtoNetwork, YieldDtoNetwork, TokenDtoNetwork, TransactionDtoNetwork, AllocationDtoNetwork, ActionsControllerGetActionsNetwork, ActionsQueryDtoNetwork, ActionArgumentsDtoInputTokenNetwork, ActionArgumentsDtoOutputTokenNetwork.

⚠️ Breaking changes pulled in from the live spec

Because the spec is live, the regeneration pulls in every upstream change since 0.0.7. Most are additive, but these are breaking for existing consumers:

  • getYieldRisk response type changed: RiskParameterDto[]YieldRiskDto (array of parameters → single ratings object). The RiskParameterDto* types are removed from the package exports.
  • YieldDto.risk changed type: YieldRiskDtoYieldRiskSummaryDto.
  • YieldRiskDto.exponentialFi removed (Exponential.fi provider dropped), replaced by stakingRewards?: YieldRiskStakingRewardsDto. All YieldRiskExponentialDto* types are removed from the package exports.
  • RewardDtoYieldSource enum value renamed: lending_interestlending (and liquid_staking added).
  • ValidatorDto flattened subnet fields removed: pricePerShare, subnetId, subnetName, marketCap, tokenSymbol → nested subnet?: ValidatorSubnetDto.
  • YieldRequirementsDto.kycUrl removed, replaced by structured kyc?: KycMetadataDto.

Given the above, maintainers may prefer a minor/major bump over the patch in the changeset — happy to adjust (repo history has shipped schema changes as patch, so I matched that).

Other spec changes pulled in (additive)

  • New networks besides robinhood: tempo, pharos.
  • New endpoints: GET /v1/yields/{yieldId}/campaigns (getYieldCampaigns), GET /v1/tokens (tokensGetTokens), GET /v1/kyc/status (kycGetStatus), with their supporting YieldCampaignDto / campaign enums / KYC DTO schemas.
  • YieldDto: new prime: boolean, feeConfigurations?: YieldFeeConfigurationDto[], investmentSchedule?: InvestmentScheduleDto (fund-style RWA subscription/redemption schedules), executionContracts?: ExecutionContractsDto.
  • getYields / YieldQueryDto: new prime?: boolean filter.
  • YieldType: new liquid_staking value; yieldTypes filter params added on actions/tokens queries.
  • YieldEntryLimitsDto: new subsequentMinimum field. YieldMetadataDto: new supportsCampaigns: boolean.
  • BalanceHistorySnapshotDto: new periodDelta? field. ArgumentFieldDtoName: new shareAmount, shareAmountRaw, useAutoClaim values.
  • Doc-comment updates throughout (e.g. YieldStatisticsDto scope clarifications).

Verification

  • pnpm lint (biome check . && tsc -b) passes.
  • pnpm build succeeds.
  • Verified robinhood: "robinhood" and "robinhood-testnet" present in all 12 network enum schema files listed above.

🤖 Generated with Claude Code

Notes for maintainers

  • The CI startup_failure on this PR is pre-existing, not caused by these changes. main's ci.yml fails at workflow startup (0s, "workflow file issue") for any new PR — every green CI run in history predates May 2026, and open PR feat: schema changes + ci fix #27 ("feat: schema changes + ci fix") replaces jdx/mise-action@v2 with a manual mise install to fix exactly this. That fix hasn't been merged to main, so this PR can't get a CI run. I did not touch the workflow here to keep this PR a pure regeneration; locally pnpm build and pnpm lint both pass.
  • Overlap with feat: schema changes + ci fix #27: this PR regenerates from today's live spec, so it includes everything in feat: schema changes + ci fix #27's schema changes (campaigns endpoint, stakingRewards risk types, lending_interestlending) plus the newer additions (robinhood/tempo/pharos networks, KYC + tokens endpoints, prime, investment schedules). If feat: schema changes + ci fix #27's CI fix is merged first, I'm happy to rebase/regenerate here.

Regenerated src/api via `pnpm generate-api` against the live yield.xyz
OpenAPI spec. Adds `robinhood` / `robinhood-testnet` to all network
enums plus other upstream spec changes (new endpoints, campaign/KYC
schemas, and reshaped risk types).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Jul 15, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: cbf2b31

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@yieldxyz/sdk Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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