Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# Changelog

## 0.6.2

- Bumped `Version::API_SPEC_VERSION` to the Apify OpenAPI spec `v2-2026-09-28T115051Z`. No public
interface changes.
- Updated the `TaskClient::publish()` doc comment and `docs/tasks.md` to reflect the new published-task
limits (up to 10 published tasks per Actor, 100 per account; previously documented as "fewer than
50 per Actor"), matching the spec's corrected description. Behavior is unchanged: the client already
surfaces the API's rejection as-is when a task can't be published.
- The `idempotency-key` header on `RunClient::charge()` is now a required parameter in the spec (was
optional). No client change needed: this client already always sends an idempotency key, generating
one automatically when the caller doesn't supply one.
- Documented that the charge idempotency key expires 3 minutes after the charge (a later request
reusing it creates a new charge rather than deduplicating), per the spec's updated description.
`RunChargeOptions::$idempotencyKey` and `docs/options.md`.

## 0.6.1

- Bumped `Version::API_SPEC_VERSION` to the Apify OpenAPI spec `v2-2026-09-10T091137Z`. This
Expand Down
2 changes: 1 addition & 1 deletion docs/options.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ For `run()->charge()` (pay-per-event Actors). `eventName` is **required**.
|---|---|---|
| `eventName` | `string` | Name of the event to charge for. |
| `count` | `?int` | Number of times to charge the event (defaults to 1). |
| `idempotencyKey` | `?string` | Deduplicates the charge across retries; auto-generated if unset. |
| `idempotencyKey` | `?string` | Deduplicates the charge across retries; auto-generated if unset. Expires 3 minutes after the charge — reusing it later creates a new charge rather than deduplicating. |

## Builds

Expand Down
6 changes: 4 additions & 2 deletions docs/tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,10 @@ foreach ($client->tasks()->iterate(new ListOptions(), 50) as $t) {
- `get(): ?Task`, `update(mixed $newFields): Task`, `delete(): void`
- `publish(): Task`, `unpublish(): Task` — publish/unpublish the task's public landing page, by
setting `isPublic` through `update()`. Both require write permission to the task's Actor;
publishing additionally requires the Actor to be public, to have fewer than 50 already-published
tasks, and the task's `publicConfig.inputSchemaFields`/`publicConfig.datasetView` to be set.
publishing additionally requires the Actor to be public and the task's
`publicConfig.inputSchemaFields`/`publicConfig.datasetView` to be set. An Actor can have up to 10
published tasks and an account up to 100 (contact Apify support to raise these limits); if the
conditions aren't met, the request fails and nothing is changed.
- `start(mixed $input = null, ?TaskStartOptions $options = null): ActorRun`
- `call(mixed $input = null, ?TaskStartOptions $options = null, ?int $waitSecs = null): ActorRun`
- `getInput(): mixed`, `updateInput(mixed $input): mixed`
Expand Down
2 changes: 2 additions & 0 deletions src/Options/RunChargeOptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ public function __construct(
/**
* A key that deduplicates the charge across retries. If unset, one is auto-generated as
* {@code "{runId}-{eventName}-{timestampMillis}-{random}"}, matching the reference client.
* The key expires 3 minutes after the charge; a later request reusing it creates a new
* charge instead of being deduplicated against the original.
*/
public readonly ?string $idempotencyKey = null,
) {
Expand Down
9 changes: 5 additions & 4 deletions src/Resource/TaskClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,11 @@ public function delete(): void
* Publishes the task on its public landing page, by setting {@code isPublic} through
* {@see update()}. Requires write permission to the task's Actor.
*
* To publish, the task's Actor must be public, its {@code publicConfig.inputSchemaFields} and
* {@code publicConfig.datasetView} must be set, and the Actor must have fewer than 50
* published tasks; if any of these are not met, the request fails and nothing is changed.
* Publishing an already published task does nothing.
* To publish, the task's Actor must be public and its {@code publicConfig.inputSchemaFields}
* and {@code publicConfig.datasetView} must be set. An Actor can have up to 10 published
* tasks and an account up to 100; contact Apify support to raise these limits. If any of
* these conditions are not met, the request fails and nothing is changed (including fields
* unrelated to publishing). Publishing an already published task does nothing.
*/
public function publish(): Task
{
Expand Down
4 changes: 2 additions & 2 deletions src/Version.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ final class Version
* The semantic version of this client library (see https://semver.org/).
* Changes to the public interface other than additive ones are considered breaking changes.
*/
public const CLIENT_VERSION = '0.6.1';
public const CLIENT_VERSION = '0.6.2';

/**
* The version of the Apify OpenAPI specification this client was generated and verified
* against. Corresponds to the {@code info.version} field of the Apify OpenAPI document.
*/
public const API_SPEC_VERSION = 'v2-2026-09-10T091137Z';
public const API_SPEC_VERSION = 'v2-2026-09-28T115051Z';

private function __construct()
{
Expand Down
Loading