Skip to content

chore(stainless): add ruby/go/csharp/php/cli targets and sync resources#518

Merged
pengying merged 1 commit into
mainfrom
05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources
May 28, 2026
Merged

chore(stainless): add ruby/go/csharp/php/cli targets and sync resources#518
pengying merged 1 commit into
mainfrom
05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources

Conversation

@pengying
Copy link
Copy Markdown
Contributor

@pengying pengying commented May 28, 2026

Summary

Updates the Stainless config to reflect the current API surface and adds five new SDK targets.

New SDK targets

  • ruby (gem grid, rubygems publish disabled)
  • go (package grid)
  • csharp (package grid, nuget publish disabled)
  • php (package grid, composer org-placeholder/grid)
  • cli (binary grid)

All have production_repo: null for now.

Resource sync

  • config.models: add embedded_wallet_config
  • sandbox: add cards.simulate subresource (authorization/clearing/return) with associated card simulation models
  • $shared: add slv_external_account_create_info, slv_beneficiary, swift_external_account_create_info
  • customers.methods: add generate_kyc_link: post /customers/{customerId}/kyc-link
  • agents: add agent_account_restrictions, agent_approval_thresholds
  • Add top-level cards resource (issue / list / retrieve / update)

Auth credential verify-request aliases — intentionally omitted

email_otp_credential_verify_request, oauth_credential_verify_request, and passkey_credential_verify_request are not added as model aliases. The auth verify-request schemas are defined as:

allOf:
  - $ref: AuthCredentialVerifyRequest
  - $ref: <X>CredentialVerifyRequestFields

Two existing openapi.transforms (lines stripping type from AuthCredentialVerifyRequest.properties, then removing the $ref from allOf[0] of each verify variant) reduce these to structurally equivalent to their Fields siblings. Stainless collapses the allOf and emits only the <X>CredentialVerifyRequestFields types in credentials.ts, so a model alias pointing to <X>CredentialVerifyRequest would generate broken imports (TS2724 / TS2552 in auth.ts, credentials.ts, index.ts).

The create-side aliases work because AuthCredentialCreateRequest retains a non-type field (accountId) after the transform, so its variants don't collapse.

Other

Notes

Stacked on top of #517 (document request body refactor); no code dependency between the two — sequencing is just chronological.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 28, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
grid-flow-builder Ready Ready Preview, Comment May 28, 2026 4:32am

Request Review

Copy link
Copy Markdown
Contributor Author

pengying commented May 28, 2026

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 28, 2026

Greptile Summary

This PR extends the Stainless SDK configuration with five new target languages (Ruby, Go, C#, PHP, CLI) and synchronises resource definitions: adds a top-level cards resource, a sandbox.cards.simulate subresource, new auth credential verify request models, new agent restriction/threshold models, and new SLV/SWIFT external account schemas. Several methods are also simplified from the verbose endpoint-plus-body-param form to the shorthand endpoint string.

  • New SDK targets: Ruby, Go, C#, PHP, and CLI generators are enabled; all have production_repo: null and publishing disabled, indicating they are not yet wired for release.
  • Resource sync: cards CRUD, sandbox card simulation endpoints, and multiple schema additions (EmbeddedWalletConfig, AgentAccountRestrictions, AgentApprovalThresholds, SLV/SWIFT schemas) are added; KYC-link and session-refresh methods are simplified to shorthand form.
  • PHP placeholder: The composer_package_name is set to org-placeholder/grid, which must be replaced with the real vendor namespace before the PHP target can be published.

Confidence Score: 4/5

Safe to merge with the caveat that the PHP composer_package_name placeholder must be resolved before the PHP target is published.

The bulk of the change is mechanical YAML configuration: new SDK targets (all with publication disabled and production_repo: null) and resource/model additions that mirror the OpenAPI spec. The only concrete problem is that the PHP target carries org-placeholder/grid as its Composer package name, which would publish under the wrong vendor if left unchanged. Every other language target looks complete.

.stainless/stainless.yml — specifically the composer_package_name field under the php target block.

Important Files Changed

Filename Overview
.stainless/stainless.yml Adds ruby/go/csharp/php/cli SDK targets and syncs resource models/methods; PHP target contains a placeholder composer_package_name: org-placeholder/grid that needs to be replaced before publication.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[stainless.yml config] --> B[Existing targets]
    A --> C[New targets added]
    B --> B1[typescript]
    B --> B2[kotlin]
    B --> B3[python]
    C --> C1[ruby\nedition: ruby.2025-10-08]
    C --> C2[go\nedition: go.2026-04-15]
    C --> C3[csharp\nedition: csharp.2025-10-08]
    C --> C4[php\nedition: php.2025-10-08\ncomposer_package_name: org-placeholder/grid]
    C --> C5[cli\nedition: cli.2025-10-08]
    A --> D[Resource changes]
    D --> D1[config: + embedded_wallet_config]
    D --> D2[customers: generate_kyc_link]
    D --> D3[cards: new top-level resource]
    D --> D4[sandbox.cards.simulate]
    D --> D5[agents: + restrictions + thresholds]
    D --> D6[auth.credentials: + 3 verify request models]
    D --> D7[$shared: + slv / swift schemas]
Loading

Fix All in Claude Code

Prompt To Fix All With AI
Fix the following 1 code review issue. Work through them one at a time, proposing concise fixes.

---

### Issue 1 of 1
.stainless/stainless.yml:71
**Placeholder composer package name**

`composer_package_name: org-placeholder/grid` is an explicit placeholder. Composer (PHP's package manager) uses `vendor/package` naming, and the vendor segment here is clearly not the real organization name. If this config is consumed by Stainless to generate or publish the PHP SDK, the package will be registered under the wrong vendor name, making it undiscoverable and unusable by PHP consumers via `composer require`.

Reviews (1): Last reviewed commit: "chore(stainless): add ruby/go/csharp/php..." | Re-trigger Greptile

Comment thread .stainless/stainless.yml
edition: php.2025-10-08
package_name: grid
production_repo: null
composer_package_name: org-placeholder/grid
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Placeholder composer package name

composer_package_name: org-placeholder/grid is an explicit placeholder. Composer (PHP's package manager) uses vendor/package naming, and the vendor segment here is clearly not the real organization name. If this config is consumed by Stainless to generate or publish the PHP SDK, the package will be registered under the wrong vendor name, making it undiscoverable and unusable by PHP consumers via composer require.

Prompt To Fix With AI
This is a comment left during a code review.
Path: .stainless/stainless.yml
Line: 71

Comment:
**Placeholder composer package name**

`composer_package_name: org-placeholder/grid` is an explicit placeholder. Composer (PHP's package manager) uses `vendor/package` naming, and the vendor segment here is clearly not the real organization name. If this config is consumed by Stainless to generate or publish the PHP SDK, the package will be registered under the wrong vendor name, making it undiscoverable and unusable by PHP consumers via `composer require`.

How can I resolve this? If you propose a fix, please make it concise.

Fix in Claude Code

@pengying pengying force-pushed the 05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources branch from fe1705f to f84586d Compare May 28, 2026 01:24
@pengying pengying force-pushed the 05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources branch from f84586d to a00d279 Compare May 28, 2026 01:51
bsiaotickchong
bsiaotickchong previously approved these changes May 28, 2026
Copy link
Copy Markdown
Contributor Author

pengying commented May 28, 2026

Merge activity

  • May 28, 4:32 AM UTC: A user started a stack merge that includes this pull request via Graphite.
  • May 28, 4:33 AM UTC: Graphite rebased this pull request as part of a merge.
  • May 28, 4:33 AM UTC: @pengying merged this pull request with Graphite.

@pengying pengying changed the base branch from 05-27-refactor_openapi_extract_document_upload_replace_request_bodies_into_reusable_components to graphite-base/518 May 28, 2026 04:32
@pengying pengying changed the base branch from graphite-base/518 to main May 28, 2026 04:32
@pengying pengying dismissed bsiaotickchong’s stale review May 28, 2026 04:32

The base branch was changed.

@pengying pengying force-pushed the 05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources branch from a00d279 to 041978e Compare May 28, 2026 04:32
Copy link
Copy Markdown

@restamp-bot restamp-bot Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

041978e is a pure rebase onto 501fdaa. Approving based on @bsiaotickchong's previous approval of a00d279.

@pengying pengying merged commit d329472 into main May 28, 2026
8 checks passed
@pengying pengying deleted the 05-27-chore_stainless_add_ruby_go_csharp_php_cli_targets_and_sync_resources branch May 28, 2026 04:33
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.

2 participants