Skip to content

Commit d8502d9

Browse files
authored
fix: remove orphaned sandbox resource wrapper (#48)
1 parent b820b25 commit d8502d9

4 files changed

Lines changed: 2 additions & 59 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ let runs = client.query_runs().list(Some(50), None, None, None).await?;
9696
Handles exist for every resource — `datasets`, `connections`, `connection_types`,
9797
`databases`, `database_context`, `embedding_providers`, `indexes`,
9898
`information_schema`, `jobs`, `queries`, `query_runs`, `results`, `refresh`,
99-
`sandboxes`, `saved_queries`, `secrets`, `uploads`, `workspaces`. The hottest
99+
`saved_queries`, `secrets`, `uploads`, `workspaces`. The hottest
100100
operations also have flat shortcuts directly on `Client` (`query`, `get_result`,
101101
`list_results`, `list_query_runs`, `list_workspaces`).
102102

src/client.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -673,11 +673,6 @@ impl Client {
673673
crate::resources::RefreshApi::new(&self.configuration)
674674
}
675675

676-
/// Sandboxes resource handle.
677-
pub fn sandboxes(&self) -> crate::resources::SandboxesApi<'_> {
678-
crate::resources::SandboxesApi::new(&self.configuration)
679-
}
680-
681676
/// Saved-queries resource handle.
682677
pub fn saved_queries(&self) -> crate::resources::SavedQueriesApi<'_> {
683678
crate::resources::SavedQueriesApi::new(&self.configuration)

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ pub use client::{
4444
pub use resources::{
4545
ConnectionTypesApi, ConnectionsApi, DatabaseContextApi, DatabasesApi, DatasetsApi,
4646
EmbeddingProvidersApi, IndexesApi, InformationSchemaApi, JobsApi, QueryApi, QueryRunsApi,
47-
RefreshApi, ResultsApi, SandboxesApi, SavedQueriesApi, SecretsApi, UploadsApi, WorkspacesApi,
47+
RefreshApi, ResultsApi, SavedQueriesApi, SecretsApi, UploadsApi, WorkspacesApi,
4848
};
4949
pub use status::{QueryRunStatus, QueryRunStatusExt, ResultStatus, ResultStatusExt};
5050

src/resources.rs

Lines changed: 0 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -656,57 +656,6 @@ impl<'a> RefreshApi<'a> {
656656
}
657657
}
658658

659-
/// Sandboxes resource handle. Wraps [`apis::sandboxes_api`](crate::apis::sandboxes_api).
660-
pub struct SandboxesApi<'a> {
661-
config: &'a Configuration,
662-
}
663-
664-
impl<'a> SandboxesApi<'a> {
665-
pub(crate) fn new(config: &'a Configuration) -> Self {
666-
Self { config }
667-
}
668-
669-
/// Create a new sandbox.
670-
pub async fn create(
671-
&self,
672-
request: models::CreateSandboxRequest,
673-
) -> Result<models::SandboxResponse, Error<apis::sandboxes_api::CreateSandboxError>> {
674-
apis::sandboxes_api::create_sandbox(self.config, request).await
675-
}
676-
677-
/// Fetch a sandbox by public id.
678-
pub async fn get(
679-
&self,
680-
public_id: &str,
681-
) -> Result<models::SandboxResponse, Error<apis::sandboxes_api::GetSandboxError>> {
682-
apis::sandboxes_api::get_sandbox(self.config, public_id).await
683-
}
684-
685-
/// List sandboxes.
686-
pub async fn list(
687-
&self,
688-
) -> Result<models::ListSandboxesResponse, Error<apis::sandboxes_api::ListSandboxesError>> {
689-
apis::sandboxes_api::list_sandboxes(self.config).await
690-
}
691-
692-
/// Update a sandbox by public id.
693-
pub async fn update(
694-
&self,
695-
public_id: &str,
696-
request: models::UpdateSandboxRequest,
697-
) -> Result<models::SandboxResponse, Error<apis::sandboxes_api::UpdateSandboxError>> {
698-
apis::sandboxes_api::update_sandbox(self.config, public_id, request).await
699-
}
700-
701-
/// Delete a sandbox by public id.
702-
pub async fn delete(
703-
&self,
704-
public_id: &str,
705-
) -> Result<models::DeleteSandboxResponse, Error<apis::sandboxes_api::DeleteSandboxError>> {
706-
apis::sandboxes_api::delete_sandbox(self.config, public_id).await
707-
}
708-
}
709-
710659
/// Saved-queries resource handle. Wraps [`apis::saved_queries_api`](crate::apis::saved_queries_api).
711660
pub struct SavedQueriesApi<'a> {
712661
config: &'a Configuration,
@@ -951,7 +900,6 @@ mod tests {
951900
let _ = QueryRunsApi::new(&config);
952901
let _ = ResultsApi::new(&config);
953902
let _ = RefreshApi::new(&config);
954-
let _ = SandboxesApi::new(&config);
955903
let _ = SavedQueriesApi::new(&config);
956904
let _ = SecretsApi::new(&config);
957905
let _ = UploadsApi::new(&config);

0 commit comments

Comments
 (0)