You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(ruby): Add API key (header-based) authentication support to Ruby SDK generator (#9882)
* Add API key (header-based) authentication support to Ruby SDK generator
- Implement header authentication scheme in RootClientGenerator
- Add constructor parameter for header auth schemes with environment variable support
- Add header auth scheme to raw client headers with optional prefix support
- Successfully tested with custom-auth fixture (X-API-KEY header)
- Follows same pattern as Python generator implementation
Co-Authored-By: Deep Singhvi <[email protected]>
* Fix: Use header wire value for parameter naming instead of scheme name
- Changed parameter name from scheme name to snake_case of header wire value
- Example: X-API-KEY header now generates x_api_key parameter instead of custom_auth_scheme
- Imported snakeCase from lodash-es for string conversion
- Updated both parameter creation and header value references to use consistent naming
Co-Authored-By: Deep Singhvi <[email protected]>
* Use Fern name field for header parameter naming
- Removed manual lodash snakeCase conversion
- Using header.name.name.snakeCase.safeName instead of snakeCase(header.name.wireValue)
- This ensures proper use of Fern's built-in name conversion
Co-Authored-By: Deep Singhvi <[email protected]>
* Add any-auth fixture support for API key authentication
- Generated output now includes X-API-Key header alongside Bearer token
- Test passes successfully with ruby-sdk-v2 generator
Co-Authored-By: Deep Singhvi <[email protected]>
* Fix: Support multiple authentication parameters in client constructor
- Changed getAuthenticationParameter() to getAuthenticationParameters() returning an array
- Now handles APIs with multiple auth schemes (e.g., any-auth with bearer + API key)
- Fixes missing api_key parameter issue in any-auth fixture
- Both token and api_key are now properly added to constructor with ENV defaults
Co-Authored-By: Deep Singhvi <[email protected]>
* chore: Add changelog entry for v1.0.0-rc29
- Added API key (header-based) authentication support
- Added support for multiple authentication schemes in the same API
Co-Authored-By: Deep Singhvi <[email protected]>
---------
Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Co-authored-by: Deep Singhvi <[email protected]>
Co-authored-by: Piper Gragg <[email protected]>
0 commit comments