Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use public.api.bsky.app for unauthed sessions by default #121

Merged
merged 1 commit into from
Dec 13, 2024

Conversation

drasticactions
Copy link
Owner

This makes a minor-ish breaking change to the default Instance URL that's created. Originally, I was using "https://bsky.social" as the default, which does not work well for unauthenticated endpoints when compared to the public API. But, for 99% of user sessions when you need to authenticate, you want that. And generally, when you're logged in, you want to use your PDS.

I tried to get the logic right by:

  • Switching the default Instance URL to the public API ("https://public.api.bsky.app") by default.
  • If you try logging with this set as the instance URL (and you didn't set one yourself for the users PDS), it will switch back to bsky.social for the CreateSession call, which will then set the correct PDS from then on.
  • If you had set the Instance Uri in the builder, nothing changes, it will default to that.

@drasticactions drasticactions merged commit afd410f into develop Dec 13, 2024
6 checks passed
@drasticactions drasticactions deleted the switch-public-api branch December 13, 2024 11:15
drasticactions added a commit that referenced this pull request Dec 27, 2024
* Add missing parameters to getAuthorFeed

* Don't set ATError object when logging

* Add AspectRatio to ImageView

* Start sourcegen

* Update

* Update Tools

* Update

* Remove usings, since it's in global

* Try again

* update

* Update

* Update

* Update

* Update

* Update

* Update

* Almost...

* Update

* Update

* Update logging-in.md

* Add codeflow to readme

* Update...

* Expose the Cursor on the NotificationCollection

* Almost... maybe...

* Firehose

* Update

* The big one

* Update

* Update...

* Fix Readme

* Start refactoring...

* More types

* More cleanup

* More modding...

* More types...

* Closer...

* Nearly...

* Fun!

* First run!

* Tests and More

* Add Tests for Endpoints

* Add class entries

* Trying to generate helpers...

* More generated Parameters

* And helper methods!

* Update Generated Types with less aggressive Null values

Also fix JSON ATObject type to allow fallback

* Update Docs, bump ATProto again...

* Revert...

* Revert...

* Revert...

* Add parameter constructors...

* Update docs

* More docs

* Update docs

* Adjust tests (???)

* Remove deprecated classes and methods

* Remove FishyFlipDX, Replace FishyFlip with Source Gen Bits (#104)

+semver: breaking

* Add docs, bump to net9.0 (#105)

* Add docs, bump to net9.0

* Bump to net9

* Fix ImportRepo, add OpenGraphParser (#106)

* Fix ImportRepo

* Add OpenGraphParser

* Cleanup + Fix WASM support  (#108)

* Order by classname

* Update

* small cleanup

* Update

* Use SupportsAutomaticDecompression for setting AutomaticDecompression, add WASM site back

* Add WhiteWind Generator, add GetRecord (#110)

* Add ATError Object Generator (#112)

* Add Error Generator

* Add Possible Errors

* Warning cleanup

* Add ToString override for ATError (#113)

* Fix GetBlob to return byte[] (#114)

* Resolve Repo DIDs and Handles independently (#115)

* Start refactoring URL

* Update

* Fix tests

* Fix Facet Parsing (#116)

* Fix Facet Parsing

* Remove DistinctBy

* Reintroduce bskycli (#117)

* Add bskycli

* Image Aspect Ratio

* Update

* Update

* Update readme

* Update

* Fix Windows script

* Bump ATProtocol, Bind ATFile Lexicon support (#118)

* Bump atprotocol

* Add ATFile support

* Add build_binding script (#119)

* Update PasswordAuth with AuthenticateWithPasswordResultAsync (#120)

* Update PasswordAuth with AuthenticateWithPasswordResultAsync

* Really???

* Use public.api.bsky.app for unauthed sessions by default (#121)

* Add 2FA Auth Token support for Password Auth (#122)

* Bump dependencies (#123)

* Add Post helper for PostView (#124)

* Bump dependencies (#125)

* Resolve users PDS before authentication (#126)

* Add Pastesphere support (#127)

* Add AniBlue support (#128)

* Bump Bindings (#129)

* Add community lexicons (#130)

* Add DidDoc helpers (#131)

* patch: Special case booleans (#132)

* Bump bindings (#133)

* Override ATUri/ATIdentifier Equals for proper checking (#134)

* Bump bindings

* Override Equals

* Add support for setting Labels / Fixes Chat (#135)

* Update SourceGen for Labels

* Update for labels

* Fix chat too

---------

Co-authored-by: Thomas May <[email protected]>
Co-authored-by: Kevin Gosse <[email protected]>
Co-authored-by: Matt Brailsford <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant