Skip to main content

Crate sylphx_sdk_core

Crate sylphx_sdk_core 

Source
Expand description

Shared transport and auth for Sylphx Platform Rust SDKs.

Wire payloads are owned by sylphx-api-types (Protobuf). This crate only maps HTTP status + JSON error envelopes onto typed errors and applies auth.

Re-exports§

pub use project_binding::BindingAdmissionError;
pub use project_binding::BindingDispatchError;
pub use project_binding::CurrentBindingAuthority;
pub use project_binding::CurrentBindingHead;
pub use project_binding::PlatformBindingVerifier;
pub use project_binding::ProjectBindingAdmission;
pub use project_binding::CLOCK_SKEW_SECONDS;
pub use project_binding::MAX_BINDING_LIFETIME_SECONDS;
pub use project_binding::PLATFORM_ISSUER;
pub use project_binding::PROJECT_BINDING_ALGORITHM;
pub use project_binding::PROJECT_BINDING_HEADER;
pub use project_binding::PROJECT_BINDING_TYPE;

Modules§

project_binding
Platform-owned signed project-binding admission for downstream services. Platform project-binding admission for downstream HTTP and Connect calls.

Structs§

BuildConnectionUrlInput
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Input for build_connection_url.
ParsedConnectionUrl
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Parsed Sylphx connection URL components (dual-oracle of ParsedConnectionUrl).
RetryConfig
Retry policy for transient failures.
Transport
Production HTTP transport.
TransportConfig
Shared HTTP client configuration for one plane endpoint.
VerifiedBindingContext
Re-export contract identity for consumers and CLI evidence. Immutable identity and scope proved by Platform binding admission.

Enums§

ConnectionCredentialType
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Credential kind — publishable (pk) or secret (sk).
ConnectionEnv
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Target environment encoded in the credential.
Credential
Credential material for a plane.
SdkError
SDK-level errors.
VerifiedBindingContextError
Re-export contract identity for consumers and CLI evidence. Failure to construct a verified-binding context from incomplete claims.

Constants§

API_TYPES_CONTRACT_PACKAGE
Re-export contract identity for consumers and CLI evidence. Schema identity for publish/admission evidence.
API_TYPES_CONTRACT_REVISION
Re-export contract identity for consumers and CLI evidence. Human-readable contract revision for this crate release.
DEFAULT_MANAGEMENT_BASE_URL
Default Management API base URL (includes /v1).
PLATFORM_CONSOLE_SLUG
Customer Zero project slug (Console dogfood residual). Matches packages/contract platform-identity PLATFORM_CONSOLE_SLUG (ADR-089 §2.8.1 / ADR-3888). Identity / routing only — never an operator privilege grant (ADR-3418, ADR-3422).
VERIFIED_BINDING_CONTEXT_REVISION
Re-export contract identity for consumers and CLI evidence. Canonical revision of the verified-binding request context contract.
WIRE_CONTRACT_PACKAGE
Deprecated aliases — prefer API_TYPES_CONTRACT_*. Schema identity for publish/admission evidence.
WIRE_CONTRACT_REVISION
Deprecated aliases — prefer API_TYPES_CONTRACT_*. Human-readable contract revision for this crate release.

Functions§

auth_header_pair
Build Authorization / x-app-secret header pair for inspection/tests.
baas_base_url
Build the BaaS plane base URL for a tenant slug.
build_connection_url
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Build a canonical Sylphx connection URL (dual-oracle of buildConnectionUrl).
normalize_management_base_url
Normalize a Management API base URL so callers always hit /v1.
parse_connection_url
Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Connection URL SSOT (ADR-123 dual-oracle of @sylphx/sdk connection-url). Parse a Sylphx connection URL (dual-oracle of parseConnectionUrl).
platform_console_baas_base_url
Customer Zero BaaS base URL (…/v1) for operator device login dogfood.
strip_json_nulls
Remove JSON null values from objects (recursively).

Type Aliases§

SdkEventStream
Backpressure-aware typed Server-Sent Events response stream.