bluesky-social / atproto

Social networking technology created by Bluesky
Other
6.17k stars 432 forks source link

Instantiate XrpcClient from an OAuthAgent #2714

Closed matthieusieben closed 1 month ago

matthieusieben commented 1 month ago

Potentially breaking changes:

matthieusieben commented 1 month ago

Hey @devinivy, thank you for the review. I moved the OAuthAtpAgent class into the api agent. This reverses the dependency between @atproto/api and @atproto/oauth-client but that extra dependency in api is only needed for typing purposes and should not impact the bundle size.

With this change, the @atproto/api is no longer needed in order to instantiate custom @atproto/xrpc clients.

matthieusieben commented 1 month ago

This whole PR introduces a breaking change in the oauth-client* packages but I think it's fine since those were not released yet (will impact ozone but no big deal).

cc @foysalit

matthieusieben commented 1 month ago

Thanks @surfdude29 for your careful review <3

surfdude29 commented 1 month ago

Thanks @surfdude29 for your careful review <3

No worries, happy to help :)