Skip to content

Commit 6d2a808

Browse files
authored
feat: sync Rust client with Apify OpenAPI spec v2-2026-09-02T154542Z (#24)
1 parent 472cd9b commit 6d2a808

6 files changed

Lines changed: 25 additions & 4 deletions

File tree

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ All notable changes to the Rust Apify API client are documented here. The format
44
based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and the project adheres
55
to [Semantic Versioning](https://semver.org/).
66

7+
## [0.10.0] - 2026-09-04
8+
9+
### Added
10+
- `Task::description`, matching the spec's newly-documented task `description` field (also
11+
present on the reference JS client's `Task`). Previously only accessible untyped via
12+
`Task::extra`.
13+
14+
### Changed
15+
- Bumped `API_SPEC_VERSION` to `v2-2026-09-02T154542Z`.
16+
- Bumped crate version to `0.10.0`.
17+
718
## [0.9.1] - 2026-08-28
819

920
### Changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "apify-client"
3-
version = "0.9.1"
3+
version = "0.10.0"
44
authors = ["Apify Technologies <support@apify.com>"]
55
description = "An official, but experimental, AI-generated and AI-maintained Rust client for the Apify API (https://apify.com)."
66
license = "Apache-2.0"

docs/tasks.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ are preserved in `extra`.
4040
| `user_id` | `Option<String>` | ID of the user who owns the task. |
4141
| `name` | `Option<String>` | Technical name of the task, used in API paths. |
4242
| `title` | `Option<String>` | Human-readable title shown in the UI. |
43+
| `description` | `Option<String>` | Human-readable description shown on the task's public landing page. Required (up to 400 characters), alongside `title` (3 to 63 characters), to publish the task. |
4344
| `created_at` | `Option<DateTime<Utc>>` | When the task was created. |
4445
| `modified_at` | `Option<DateTime<Utc>>` | When the task was last modified. |
4546
| `is_public` | `Option<bool>` | Whether the task is published on its public landing page. Derived from `public_config.published_at`; set it via `publish()`/`unpublish()` or `update()`. |

src/models.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,11 @@ pub struct Task {
165165
/// Human-readable title.
166166
#[serde(default)]
167167
pub title: Option<String>,
168+
/// Human-readable description shown on the task's public landing page. Required (up to 400
169+
/// characters), alongside `title` (3 to 63 characters), to [`publish`](crate::clients::task::TaskClient::publish)
170+
/// the task.
171+
#[serde(default)]
172+
pub description: Option<String>,
168173
/// When the task was created.
169174
#[serde(default)]
170175
pub created_at: Option<DateTime<Utc>>,

src/version.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ pub const CLIENT_VERSION: &str = env!("CARGO_PKG_VERSION");
1010
/// and verified against.
1111
///
1212
/// This corresponds to the `info.version` field of the Apify OpenAPI document.
13-
pub const API_SPEC_VERSION: &str = "v2-2026-08-27T071624Z";
13+
pub const API_SPEC_VERSION: &str = "v2-2026-09-02T154542Z";

tests/task.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,13 +283,17 @@ async fn task_crud_flow() {
283283
let input = task_client.get_input().await.expect("get input");
284284
assert!(input.is_some());
285285

286-
// Update (rename).
286+
// Update (rename + set description).
287287
let renamed = common::unique_name("task-renamed");
288288
let updated = task_client
289-
.update(&json!({ "name": renamed }))
289+
.update(&json!({ "name": renamed, "description": "Updated by task_crud_flow." }))
290290
.await
291291
.expect("update task");
292292
assert_eq!(updated.name.as_deref(), Some(renamed.as_str()));
293+
assert_eq!(
294+
updated.description.as_deref(),
295+
Some("Updated by task_crud_flow.")
296+
);
293297

294298
// List its runs (likely empty, but the endpoint should respond).
295299
let runs = task_client

0 commit comments

Comments
 (0)