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
Describe the bug
The generic types for Agent enforces Record<string, unknown> as bound for Props. This Record type requires subtypes to define an index signature for type string, which prevents using interfaces with well-defined properties.
To Reproduce
Steps to reproduce the behavior:
Go to '...'
Click on '....'
Scroll down to '....'
See error
Expected behavior
While the type could still default to Record<string, unknown>, it should allow using proper interfaces that have no index signature.
Screenshots
This is the error reported by Typescript on a getAgentsByName call passing { props: config } as third argument:
Activity
mattzcarey commentedon Jul 7, 2026
@agent-think repro this pls
fix: allow interfaces as agent props
fix: allow interfaces as agent props
fix: allow interfaces as agent props (cloudflare#2238)