pub struct Client { /* private fields */ }Expand description
Explicit connection/credential configuration; no session state is written to disk.
Implementations§
Source§impl Client
impl Client
Sourcepub fn new(base_url: &str) -> Result<Self, Error>
pub fn new(base_url: &str) -> Result<Self, Error>
Accepts a bare backend origin, /api/v1, or /api/v1/.
pub fn with_bearer(self, token: impl Into<String>) -> Self
pub fn with_test_key(self, key: impl Into<String>) -> Result<Self, Error>
Sourcepub fn with_test_app_secret(
self,
secret: impl Into<String>,
) -> Result<Self, Error>
pub fn with_test_app_secret( self, secret: impl Into<String>, ) -> Result<Self, Error>
Selects an IAM sandbox using only the imported application’s secret.
Sourcepub async fn contracts(&self) -> Result<Value, Error>
pub async fn contracts(&self) -> Result<Value, Error>
Live metadata for the selected environment. Never returns a secret.
Sourcepub fn with_telemetry(self, enabled: bool) -> Self
pub fn with_telemetry(self, enabled: bool) -> Self
Opts this client instance out of diagnostic telemetry.
Sourcepub fn with_source(self, source: &'static str) -> Result<Self, Error>
pub fn with_source(self, source: &'static str) -> Result<Self, Error>
Identifies the interface in request diagnostics; no command arguments are sent.
Sourcepub async fn email_settings(&self) -> Result<Value, Error>
pub async fn email_settings(&self) -> Result<Value, Error>
Reads this identity’s organization email preferences.
Sourcepub async fn set_email_settings(&self, body: &Value) -> Result<Value, Error>
pub async fn set_email_settings(&self, body: &Value) -> Result<Value, Error>
Replaces the organization email and event subscriptions.
Sourcepub async fn report(&self, body: &Value) -> Result<Value, Error>
pub async fn report(&self, body: &Value) -> Result<Value, Error>
Queues a bug report for Commit maintainers; preserve the mutation across retries.
pub async fn testing_context(&self) -> Result<Value, Error>
Sourcepub async fn claim_project_task(
&self,
project: &str,
task: &str,
) -> Result<Value, Error>
pub async fn claim_project_task( &self, project: &str, task: &str, ) -> Result<Value, Error>
Atomically take an unassigned task.
Sourcepub async fn delete_project_task(
&self,
project: &str,
task: &str,
) -> Result<Value, Error>
pub async fn delete_project_task( &self, project: &str, task: &str, ) -> Result<Value, Error>
Remove a task subtree and its linked todos.
Sourcepub async fn project_versions(
&self,
project: &str,
query: &[(&str, &str)],
) -> Result<Value, Error>
pub async fn project_versions( &self, project: &str, query: &[(&str, &str)], ) -> Result<Value, Error>
Retained project version metadata, newest first.
Sourcepub async fn project_version(
&self,
project: &str,
version: i64,
) -> Result<Value, Error>
pub async fn project_version( &self, project: &str, version: i64, ) -> Result<Value, Error>
One complete retained project snapshot.
pub fn with_org_id(self, org_id: impl Into<String>) -> Self
Sourcepub fn with_mutation(self, mutation: Mutation) -> Self
pub fn with_mutation(self, mutation: Mutation) -> Self
Attaches retry/precondition inputs to requests made through this clone.
pub fn base_url(&self) -> &Url
pub fn new_idempotency_key() -> String
pub async fn health(&self) -> Result<Value, Error>
pub async fn ready(&self) -> Result<Value, Error>
pub async fn version(&self) -> Result<Value, Error>
Sourcepub async fn iam(&self) -> Result<Value, Error>
pub async fn iam(&self) -> Result<Value, Error>
Public IAM application metadata. Caller credentials and test context are omitted.
Sourcepub async fn login_status(&self) -> Result<Value, Error>
pub async fn login_status(&self) -> Result<Value, Error>
Verify the current login against IAM and return its public actor identity.
Missing or rejected credentials return authenticated: false; transport,
permission, and server failures remain errors. No tokens are returned.
pub async fn login_with_slt(&self, slt: &str) -> Result<SessionTokens, Error>
pub async fn refresh_session( &self, refresh_token: &str, ) -> Result<SessionTokens, Error>
pub async fn logout(&self, token: &str) -> Result<(), Error>
Sourcepub async fn list_todos(&self, query: &[(&str, &str)]) -> Result<Value, Error>
pub async fn list_todos(&self, query: &[(&str, &str)]) -> Result<Value, Error>
GET /api/v1/todos.
Sourcepub async fn get_todo(&self, todo_id: &str) -> Result<Value, Error>
pub async fn get_todo(&self, todo_id: &str) -> Result<Value, Error>
GET /api/v1/todos/{todo_id}.
Sourcepub async fn create_todo<T: Serialize + ?Sized>(
&self,
body: &T,
) -> Result<Value, Error>
pub async fn create_todo<T: Serialize + ?Sized>( &self, body: &T, ) -> Result<Value, Error>
POST /api/v1/todos.
Sourcepub async fn update_todo<T: Serialize + ?Sized>(
&self,
todo_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn update_todo<T: Serialize + ?Sized>( &self, todo_id: &str, body: &T, ) -> Result<Value, Error>
PATCH /api/v1/todos/{todo_id}.
Sourcepub async fn delete_todo(&self, todo_id: &str) -> Result<Value, Error>
pub async fn delete_todo(&self, todo_id: &str) -> Result<Value, Error>
DELETE /api/v1/todos/{todo_id}.
Sourcepub async fn list_notes(
&self,
todo_id: &str,
query: &[(&str, &str)],
) -> Result<Value, Error>
pub async fn list_notes( &self, todo_id: &str, query: &[(&str, &str)], ) -> Result<Value, Error>
GET /api/v1/todos/{todo_id}/notes.
Sourcepub async fn add_note<T: Serialize + ?Sized>(
&self,
todo_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn add_note<T: Serialize + ?Sized>( &self, todo_id: &str, body: &T, ) -> Result<Value, Error>
POST /api/v1/todos/{todo_id}/notes.
Sourcepub async fn todo_subscription(&self, todo_id: &str) -> Result<Value, Error>
pub async fn todo_subscription(&self, todo_id: &str) -> Result<Value, Error>
GET /api/v1/todos/{todo_id}/notification-subscription.
Sourcepub async fn replace_todo_subscription<T: Serialize + ?Sized>(
&self,
todo_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn replace_todo_subscription<T: Serialize + ?Sized>( &self, todo_id: &str, body: &T, ) -> Result<Value, Error>
PUT /api/v1/todos/{todo_id}/notification-subscription.
Sourcepub async fn notification_settings(&self) -> Result<Value, Error>
pub async fn notification_settings(&self) -> Result<Value, Error>
GET /api/v1/notification-settings.
Sourcepub async fn update_notification_settings<T: Serialize + ?Sized>(
&self,
body: &T,
) -> Result<Value, Error>
pub async fn update_notification_settings<T: Serialize + ?Sized>( &self, body: &T, ) -> Result<Value, Error>
PUT /api/v1/notification-settings.
Sourcepub async fn list_projects(
&self,
query: &[(&str, &str)],
) -> Result<Value, Error>
pub async fn list_projects( &self, query: &[(&str, &str)], ) -> Result<Value, Error>
GET /api/v1/projects.
Sourcepub async fn get_project(&self, project_id: &str) -> Result<Value, Error>
pub async fn get_project(&self, project_id: &str) -> Result<Value, Error>
GET /api/v1/projects/{project_id}.
Sourcepub async fn create_project<T: Serialize + ?Sized>(
&self,
body: &T,
) -> Result<Value, Error>
pub async fn create_project<T: Serialize + ?Sized>( &self, body: &T, ) -> Result<Value, Error>
POST /api/v1/projects.
Sourcepub async fn update_project<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn update_project<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
PATCH /api/v1/projects/{project_id}.
Sourcepub async fn project_diary(&self, project_id: &str) -> Result<Value, Error>
pub async fn project_diary(&self, project_id: &str) -> Result<Value, Error>
GET /api/v1/projects/{project_id}/diary.
Sourcepub async fn replace_project_diary<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn replace_project_diary<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
PUT /api/v1/projects/{project_id}/diary.
Sourcepub async fn project_tasks(
&self,
project_id: &str,
query: &[(&str, &str)],
) -> Result<Value, Error>
pub async fn project_tasks( &self, project_id: &str, query: &[(&str, &str)], ) -> Result<Value, Error>
GET /api/v1/projects/{project_id}/tasks.
Sourcepub async fn project_entries(
&self,
project_id: &str,
query: &[(&str, &str)],
) -> Result<Value, Error>
pub async fn project_entries( &self, project_id: &str, query: &[(&str, &str)], ) -> Result<Value, Error>
GET /api/v1/projects/{project_id}/entries.
Sourcepub async fn create_project_task<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn create_project_task<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
POST /api/v1/projects/{project_id}/tasks.
Sourcepub async fn update_project_task<T: Serialize + ?Sized>(
&self,
project_id: &str,
task_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn update_project_task<T: Serialize + ?Sized>( &self, project_id: &str, task_id: &str, body: &T, ) -> Result<Value, Error>
PATCH /api/v1/projects/{project_id}/tasks/{task_id}.
Sourcepub async fn create_project_blocker<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn create_project_blocker<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
POST /api/v1/projects/{project_id}/blockers.
Sourcepub async fn create_project_update<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn create_project_update<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
POST /api/v1/projects/{project_id}/updates.
Sourcepub async fn complete_project<T: Serialize + ?Sized>(
&self,
project_id: &str,
body: &T,
) -> Result<Value, Error>
pub async fn complete_project<T: Serialize + ?Sized>( &self, project_id: &str, body: &T, ) -> Result<Value, Error>
POST /api/v1/projects/{project_id}/completion.
Sourcepub async fn list_test_environments(&self) -> Result<Value, Error>
pub async fn list_test_environments(&self) -> Result<Value, Error>
GET /api/v1/test-environments.
Sourcepub async fn create_test_environment<T: Serialize + ?Sized>(
&self,
body: &T,
) -> Result<Value, Error>
pub async fn create_test_environment<T: Serialize + ?Sized>( &self, body: &T, ) -> Result<Value, Error>
Legacy creation route, retained for source compatibility.
New creation returns honeycomb_manages_testing_lifecycle; create through Honeycomb.
Sourcepub async fn retrieve_test_environment_key(
&self,
id: &str,
) -> Result<Value, Error>
pub async fn retrieve_test_environment_key( &self, id: &str, ) -> Result<Value, Error>
GET /api/v1/test-environments/{id}/key.
Sourcepub async fn rotate_test_environment(&self, id: &str) -> Result<Value, Error>
pub async fn rotate_test_environment(&self, id: &str) -> Result<Value, Error>
POST /api/v1/test-environments/{id}/rotate.
Sourcepub async fn delete_test_environment(&self, id: &str) -> Result<Value, Error>
pub async fn delete_test_environment(&self, id: &str) -> Result<Value, Error>
DELETE /api/v1/test-environments/{id}.