xrpc 1.1.3
xrpc: ^1.1.3 copied to clipboard
Core library for XRPC communication. This is a wrapped HTTP client for AT Protocol.
Release Note #
1.1.3 #
- chore: bump
at_primitivesto^1.2.0.
1.1.2 #
- docs: rewrote the README example, which imported non-existent
atproto.Session/atproto.CurrentSessionand used fictional NSIDs; it now matches the workingexample/example.dart(server.atproto.com/createSession/getSession, noatprotoimport). - docs: documented the streaming API (
subscribe<T>returning anXRPCResponse<Subscription<T>>) with a minimal usage snippet. - chore: bump
at_primitivesto^1.1.1.
1.1.1 #
- fix: procedure/record request bodies no longer drop legitimately empty collections (e.g.
threadgate.allow: []); onlynullvalues are stripped. Query parameters are unchanged. This now also covers thehttp.postbody path (previously it still pruned empty[]/{}). - fix:
subscribepropagates backpressure and cancellation to the underlying WebSocket, preventing unbounded buffering on slow consumers (firehose) and socket leaks. - fix:
subscribeno longer drains the WebSocket before a consumer listens — the underlying subscription starts paused and resumes on the first listen, so a consumer that delays or never listens cannot buffer firehose frames unboundedly. - fix:
RateLimit.waitUntilReset()caps its delay at 60s, so a hostile or misconfigured far-futureRetry-AfterHTTP-date can no longer hang the caller indefinitely. - fix: an empty
200response body with atoconverter now yieldsEmptyDatainstead of throwing a rawFormatException. - fix: blob uploads fall back to
application/octet-stream(was*/*) when the content type cannot be sniffed.
1.1.0 #
- fix:
subscribe()now closes itsStreamController, propagates WebSocket errors viaaddError, and always deliversdone, so a server disconnect no longer hangsawait forforever or leaks the controller. - fix: non-JSON error bodies (e.g. an HTML
502from a proxy or an empty429) fall back to a typed exception instead of throwing aFormatException, so typed errors and retries keep working. - fix!:
409 Conflictis no longer treated as a success and its body is no longer parsed as a data model. - fix: unknown HTTP status codes (e.g. Cloudflare
520) map toHttpStatus.unknowninstead of throwingUnsupportedErrorwhile building the error response. - fix:
_buildWsUrinow uses theUribuilder (percent-encoding, repeated list params, ISO8601 UTC), so multi-valued subscription params produce a valid URL. - fix: rate-limit header parsing is now defensive (
tryParse, unlimited fallback), so a malformed header no longer turns a successful response into a crash. - fix:
RateLimit.fromHeadersnow honors theRetry-Afterheader (delta-seconds and HTTP-date forms) when usableratelimit-*headers are absent, soisExceededandwaitUntilReset()respect the backoff of a429relayed by a proxy that strips theratelimit-*headers. - fix: the optional
ratelimit-policyheader is no longer required to parse rate limit info; responses carrying onlyratelimit-limit/ratelimit-remaining/ratelimit-resetare now parsed instead of being treated as unlimited. - feat: injectable
http.Clientfor connection reuse (non-breaking), plus aprocedureadaptor param andsubscribeprotocol param. - chore: bump
at_primitivesto^1.1.0.
1.0.3 #
- MIGRATION: Updated to use the consolidated
at_primitivespackage for AT Protocol primitive types. - IMPROVEMENT: Reduced dependency complexity by adopting unified primitive types.
1.0.2 #
- Fix SDK constraint to '">=3.8.0 <4.0.0"'.
1.0.1 #
- chore: optimized docs.
1.0.0 #
- Bump SDK constraint to '^3.8.0'.
0.6.1 #
- Use
web_socket_channel: ^3.0.0.
0.6.0 #
- Add parameter
headerBuilderonqueryandprocedurefunctions.
0.5.2 #
- Bump SDK constraint to '^3.3.0'.
0.5.1 #
- Improved redundant error messages. Now it shows like
GET https://bsky.social/xrpc/com.atproto.identity.resolveHandle 400 Error: Params must have the property "handle". (#1253) - Added
parametersarg on.postand.procedure. (#1252) - Removed
.uploadfromxrpc. You can upload from.procedureand pass bytes tobody. (#1252)
0.5.0 #
- Renamed types. (#1217)
- From
TotoResponseDataBuilder - From
ResponseAdaptortoResponseDataAdaptor
- From
0.4.3 #
- Don't remove empty list.
0.4.1 #
- Added
.postfunction. (#999) - Use
bsky.networkas default when service is missing for.subscribefunction.
0.3.3 #
- You can specify
Uint8Listas a type parameter.
0.3.2 #
- Fixed field names for rate limits.
0.3.0 #
- Drop support for null unsafe Dart, bump SDK constraint to '^3.0.0'. (#599)
- Dart3 modifier applied.
0.2.2 #
0.2.1 #
- Allows
Map<String, dynamic>to be specified for generics, allowing response data to be retrieved as JSON. (#563)
0.2.0 #
0.1.2 #
- Added
decoderparameter insubscribeand delegate data decoding to the responsibility of the app that usesxrpc. (#472)
0.0.13 #
- Supported
protocoloptions inquery,procedure,upload. You can choosehttpas a protocol for your test locally. Defaults tohttps. (#269)
0.0.3 #
- Fixed internal structures.
0.0.1 #
- First Release.
0.0.0 #
- Let's start.