Skip to content

fix(bidi): set Strands user agent for Nova Sonic client#2132

Open
jonathan343 wants to merge 1 commit intostrands-agents:mainfrom
jonathan343:update-aws-sdk-user-agent
Open

fix(bidi): set Strands user agent for Nova Sonic client#2132
jonathan343 wants to merge 1 commit intostrands-agents:mainfrom
jonathan343:update-aws-sdk-user-agent

Conversation

@jonathan343
Copy link
Copy Markdown

@jonathan343 jonathan343 commented Apr 15, 2026

Description

This PR ensures the bidirectional Nova Sonic Bedrock client includes the Strands user-agent marker when making requests. That brings Nova Sonic traffic in line with expected SDK attribution and adds a focused unit test covering the client configuration used in start().

Related Issues

None

Documentation PR

None

Type of Change

Bug fix

Testing

Focused unit test added for Nova Sonic client startup configuration. Additionally, I ran the bidirectional example in the README.md and verified the outgoing User-Agent header includes lib/strands-agent#<version>:

DEBUG:smithy_core.aio.client:Sending request HTTPRequest(..., fields=Fields(OrderedDict({..., 'user-agent':
Field(name='User-Agent', value=['aws-sdk-python/0.5.0 md/smithy-core#0.4.0 md/awscrt#0.32.0 ua/2.1
api/Bedrock_Runtime#0.5.0 os/macos#25.3.0 md/arch#arm64 lang/python#3.14.3 md/pyimpl#CPython lib/strands-
agents#1.35.1.dev12+gd063f9946'], kind='header'), ...})))
  • I ran hatch run prepare

Checklist

  • I have read the CONTRIBUTING document
  • I have added any necessary tests that prove my fix is effective or my feature works
  • I have updated the documentation accordingly
    • Not needed
  • I have added an appropriate example to the documentation to outline the feature, or no new docs are needed
    • Not needed
  • My changes generate no new warnings
  • Any dependent changes have been merged and published
    • Not needed

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@jonathan343 jonathan343 force-pushed the update-aws-sdk-user-agent branch from d063f99 to dc45f1f Compare April 15, 2026 22:39
@jonathan343 jonathan343 changed the title fix: set Strands user agent for bidi Nova Sonic client fix(bidi): set Strands user agent for Nova Sonic client Apr 15, 2026
@github-actions github-actions bot added size/s and removed size/s labels Apr 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant