pub struct VoiceSystemFlowRecord {
pub id: String,
pub name: String,
pub description: String,
pub language: String,
pub version: u32,
pub yaml: String,
pub published_at: Option<String>,
pub access: String,
pub system_tags: Vec<String>,
}Expand description
One system (ready-made) call-flow record as served by the unauthenticated
GET /api/voice/flows/system?language=…&schema_versions=… endpoint.
Public by design — a signed-out device lists the catalogue and may
preview, cache, and arm from it (gated by entitlement at arming time).
description, publishedAt, and systemTags may be absent on older
rows or when the platform withheld them; all are optional.
A consumer has to be able to name this type — to map a record into its
own cache row, or to build one in a fixture — not merely receive it by
inference from Client::system_flows. This example is that guarantee:
a doctest compiles as a downstream crate, so it fails if the type ever
stops being re-exported from the crate root. The unit tests below cannot
catch that, because inside the crate the private voice module is always
in scope — which is exactly how 0.0.26 through 0.0.28 shipped these two
types unreachable.
use wavekat_platform_client::{VoiceSystemFlowRecord, VoiceSystemFlowsPage};
let page: VoiceSystemFlowsPage = serde_json::from_str(
r#"{"flows":[{"id":"flow_voicemail","name":"Voicemail","description":"",
"language":"en","version":2,"yaml":"schema_version: 1\n",
"publishedAt":null,"access":"open","systemTags":["system"]}]}"#,
)
.unwrap();
let first: &VoiceSystemFlowRecord = &page.flows[0];
assert_eq!(first.access, "open");Fields§
§id: StringPlatform-assigned flow id (flow_…), stable across versions.
name: String§description: StringOptional short description of what the flow does.
language: StringBCP-47-ish language tag — the tier this flow was selected in by the device’s language preference.
version: u32Published version number (1-based).
yaml: StringThe immutable published YAML document, verbatim.
published_at: Option<String>When this version was published, verbatim from the platform’s D1
column — which defaults to SQLite CURRENT_TIMESTAMP and so is
"YYYY-MM-DD HH:MM:SS" in UTC, not RFC 3339 (space separator, no
offset). Some rows do carry RFC 3339. Consumers must accept both:
a strict RFC 3339 parse is how every pulled flow once rendered as
“Updated Jan 1, 1970” in the desktop client. Absent on older rows.
access: StringPlatform-resolved arming rung. One of "open", "account", "pro",
or an unknown value (forward-compat for new platform rungs). Unknown
values are treated as the strictest known rung at arm time.
Raw platform tags, preserved verbatim so a future feature can read a new tag without a daemon release.