feat(ir): add OAuthAuthorizationCode.redirectUriBackupPorts for loopback port fallback - #17281
Conversation
…ack port fallback Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
There was a problem hiding this comment.
AI Review Summary
Purely additive IR schema change: adds OAuthAuthorizationCode.redirectUriBackupPorts as optional<list<integer>>, regenerates the SDK types/serializers, bumps the IR minor version, and patches two test fixtures for the noOptionalProperties required-key style. Consistent with the existing redirectUri field and the surrounding conventions; no functional risk to existing consumers. Only nit is a likely-wrong changelog date (though it matches the prior entry).
- 🔵 1 suggestion(s)
Docs Generation Benchmark ResultsComparing PR branch against median of 5 nightly run(s) on
Docs generation runs |
SDK Generation Benchmark ResultsComparing PR branch against median of 5 nightly run(s) on Full benchmark table (click to expand)
main (generator): generator-only time via --skip-scripts (includes Docker image build, container startup, IR parsing, and code generation — this is the same Docker-based flow customers use via |
Description
Add one additive, optional IR field to the authorization-code (PKCE) OAuth config so a generated CLI can fall back across a pre-registered set of loopback callback ports. Ships as
@fern-fern/ir-sdk@67.18.0. Pure schema addition — no consumer behavior change, no migration. Config parsing/converter/validator/generator/runtime all live in the follow-up generator PR.Schema (
ir-types-latest/definition/auth.yml), added toOAuthAuthorizationCoderight afterredirectUri:Regenerated SDK shape (
noOptionalProperties→ required key typed| undefined):OAuthDeviceCodeis untouched (device grant has no browser callback).Changes Made
ir-types-latest/definition/auth.yml: addOAuthAuthorizationCode.redirectUriBackupPorts(optional<list<integer>>); append a discoverability sentence to theredirectUridoc.OAuthAuthorizationCode.ts(api + serialization) viafern generate --api ir-types-latest --local.ir-types-latest/VERSION67.17.0→67.18.0(minor, additive) + IRCHANGELOG.mdentry.packages/cli/cli/changes/unreleased/ir-oauth-redirect-backup-ports.yml(type: internal).OAuthAuthorizationCode(register/.../convertAuth.test.tsandir-generator-tests/.../oauthPublicClientDynamic.test.ts). BecausenoOptionalPropertiesmakes the new key a required| undefinedproperty, each fixture neededredirectUriBackupPorts: undefinedadded to compile. Noversions.yml irVersion,generators.ymlcoordinate, or migration changes.Testing
pnpm --filter @fern-api/ir-sdk compilepnpm turbo run compile --filter=@fern-api/register --filter=@fern-api/ir-generator --filter=@fern-api/ir-generator-testspnpm turbo run testfor@fern-api/register+@fern-api/ir-generator-tests(all green)git statusshows only the expected filesLink to Devin session: https://app.devin.ai/sessions/55f07ebd06b74a67a8e6102098d8ffbf