chore: sync .NET client with Apify OpenAPI spec v2-2026-07-08T143931Z + compression/OS-token alignment - #5
Merged
Conversation
- Bump ApiSpecVersion to v2-2026-07-08T143931Z and client version to 0.1.2 - Align User-Agent OS token with reference clients (win32/darwin/linux/android/freebsd) - Add brotli request-body compression for bodies >= 1024 bytes (Content-Encoding: br) - Document the Actor versions / environment-variables sub-API and make doc token preamble null-safe
…-Agent OS token - Add RequestCompression option (Brotli default, Gzip); both paths reachable and tested - Map User-Agent OS token to the reference os.platform() values across all platforms (win32/darwin/linux/android/freebsd/openbsd/netbsd/sunos/aix) - Fix csproj version to match ClientVersion; document RequestCompression
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Syncs the .NET client with Apify OpenAPI spec
v2-2026-07-08T143931Zand aligns it with recent reference-client changes, then applies two cross-client uniformity requirements. Version0.1.2.Changes
Spec sync
ApifyClientVersion.ApiSpecVersiontov2-2026-07-08T143931Z. No in-scope endpoint/parameter/schema delta; coverage unchanged.Request-body compression — both brotli and gzip (reference: apify-client-js#962)
RequestCompressionenum (Brotli,Gzip) andApifyClientOptions.RequestCompression(defaultBrotli), threaded intoHttpClientCore. Both paths are implemented (BrotliStream→Content-Encoding: br,GZipStream→Content-Encoding: gzip), genuinely reachable via the public option, and tested. Existing behavior preserved: only compress string/byte payloads ≥ 1024 bytes, prepared once before the retry loop, skip whenContent-Encodingis already set.User-Agent OS token — identical across all clients (reference: apify-client-js#964)
ResolveOsTokenemits exactly the reference JSos.platform()tokens:win32/darwin/android/linux/freebsd(viaOperatingSystem.IsX()) plusopenbsd/netbsd/sunos(Solaris + illumos)/aix(viaRuntimeInformation), withunknownonly for non-Node platforms. Confirmedwin32(notwindows) anddarwin(notosx/macos).Docs
RequestCompression; fixed a pre-existing csproj/ClientVersionversion mismatch and several pre-existing doc issues (JSON namespace guidance, storages return types,Countlabeling, log cross-links, examples link).Testing
dotnet format --verify-no-changesclean; Release build clean (warnings-as-errors).Content-Encoding: brandgzip).Note
The live spec has since advanced to
v2-2026-07-09T114529Z(one day newer than this PR's baseline); a re-sync to that version is a separate future change, not part of this compression/OS-token work.