Skip to content

feat: add Server Actor client and sync with Apify OpenAPI spec v2-2026-11-04T151257Z - #28

Merged
Pijukatel merged 6 commits into
masterfrom
claude/bold-wright-3x9r01
Nov 9, 2026
Merged

Pijukatel merged 6 commits into
masterfrom
claude/bold-wright-3x9r01

Conversation

@Pijukatel

@Pijukatel Pijukatel commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Syncs the Java client with OpenAPI spec v2-2026-11-04T151257Z (apify/apify-docs#3083, #3084, #3152) and apify-client-js #1179, #1187, #1188, #1190 and #1197. CLIENT_VERSION goes to 0.13.0.

Spec sync

  • API_SPEC_VERSION is bumped. The version is updated in pom.xml, the README and the CHANGELOG.
  • New actorPath field on ActorVersion and BuildActVersion.
  • Javadoc updated for:
    • ActorStandby: tenancy and the admin-only flags.
    • ActorDefinition paths, which are relative to .actor/.
    • TARBALL, which is a zip archive.
  • Added Actor.getStandbyUrl(). The spec has this field but the Java model was missing it.

Server Actors (JS #1179)

  • ActorClient.server() returns an ActorServerClient. standby() is a deprecated alias that logs a warning once per process.
  • ActorServerClient has request, requestStream, getUrl and getOpenApiSpec, configured through ActorServerRequestOptions.
  • The token goes in X-Apify-Authorization.
  • Only 429 and 503 are retried, by both request and requestStream. Transport errors are not retried.
  • Error responses and redirects are returned as they are.
  • Request compression is opt-in.
  • A custom HttpTransport that cannot disable redirects makes a Server Actor request fail rather than risk sending the token to the redirect target. DefaultHttpTransport supports disabling redirects, including when it wraps your own HttpClient.
  • New public types: ServerActorException, ActorServerStreamResponse, ApiResponse.bodyAsString() and bodyAs().

Dataset count (JS #1187, #1190, #1197)

  • PaginationList.getCount() on a dataset items page is now the larger of the scanned rows and the items returned.
  • Offset iteration advances by that count, capped at the rows requested. limit now counts rows, as in the JS client, and a page's items are no longer trimmed to the cap.
  • getScannedCount() and setScannedCount() are kept but deprecated.
  • The chunkSize docs are updated.

Signed URL validity (JS #1188)

  • A non-positive expiresInSecs throws IllegalArgumentException before any request is sent. This applies to DatasetClient.createItemsPublicUrl, all overloads of KeyValueStoreClient.createKeysPublicUrl, and Signatures.signStorageContent.
  • Values above 4611686018427387 are rejected too, the same maximum as the Rust client, so the expiry cannot overflow.
  • The expiry is counted from when the URL is signed, after the storage lookup.
  • The exception is thrown synchronously, not delivered in the returned future. This matches how setRecord handles a blank contentEncoding.

Tests and docs

  • ActorServerClientTest has 45 cases against a real local socket server.
  • ActorServerIntegrationTest builds and calls a live echo Server Actor.
  • New count cases in the existing dataset tests.
  • New tests for the signed URL bounds, for no request being sent before the check, for when the expiry is counted, and for the maximum not overflowing.
  • docs/actors.md has a new Server Actors section. docs/storages.md, the README and the CHANGELOG are updated.

@Pijukatel Pijukatel added adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team. labels Nov 6, 2026 — with Claude
@apify-service-account apify-service-account added the tested Temporary label used only programatically for some analytics. label Nov 6, 2026
…js #1188)

A non-positive or too large expiresInSecs now fails with IllegalArgumentException before any request in createItemsPublicUrl and createKeysPublicUrl and in Signatures.signStorageContent. The expiry is still computed when the URL is signed, after the storage lookup.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017ocuAGnQ7tWM7EdPahZPAA
@Pijukatel
Pijukatel merged commit 1d3c129 into master Nov 9, 2026
3 of 5 checks passed
@Pijukatel
Pijukatel deleted the claude/bold-wright-3x9r01 branch November 9, 2026 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team. tested Temporary label used only programatically for some analytics.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants