Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 0.3.19 #533

Merged
merged 1 commit into from
Sep 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion VERSION.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.18
0.3.19
2 changes: 1 addition & 1 deletion kittycad.rs.patch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"path": "/info/x-rust",
"value": {
"client": "// Authenticate via an API token.\nlet client = kittycad::Client::new(\"$TOKEN\");\n\n// - OR -\n\n// Authenticate with your token and host parsed from the environment variables:\n// `KITTYCAD_API_TOKEN`.\nlet client = kittycad::Client::new_from_env();",
"install": "[dependencies]\nkittycad = \"0.3.18\""
"install": "[dependencies]\nkittycad = \"0.3.19\""
}
},
{
Expand Down
2 changes: 1 addition & 1 deletion kittycad/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "kittycad"
description = "A fully generated & opinionated API client for the KittyCAD API."
version = "0.3.18"
version = "0.3.19"
documentation = "https://docs.rs/kittycad"
readme = "README.md"
repository = "https://github.com/KittyCAD/kittycad.rs/tree/main/kittycad"
Expand Down
2 changes: 1 addition & 1 deletion kittycad/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ To install the library, add the following to your `Cargo.toml` file.

```toml
[dependencies]
kittycad = "0.3.18"
kittycad = "0.3.19"
```

## Basic example
Expand Down
30 changes: 15 additions & 15 deletions kittycad/src/api_calls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
) -> Result<Vec<crate::types::ApiCallQueryGroup>, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "api-call-metrics"),
format!("{}/{}", self.client.base_url, "api-call-metrics"),
);
req = req.bearer_auth(&self.client.token);
let query_params = vec![("group_by", format!("{}", group_by))];
Expand Down Expand Up @@ -54,7 +54,7 @@
) -> Result<crate::types::ApiCallWithPriceResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "api-calls"),
format!("{}/{}", self.client.base_url, "api-calls"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -117,7 +117,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "api-calls"),
format!("{}/{}", self.client.base_url, "api-calls"),

Check warning on line 120 in kittycad/src/api_calls.rs

View check run for this annotation

Codecov / codecov/patch

kittycad/src/api_calls.rs#L120

Added line #L120 was not covered by tests
);
req = req.bearer_auth(&self.client.token);
let mut request = req.build()?;
Expand Down Expand Up @@ -170,7 +170,7 @@
) -> Result<crate::types::ApiCallWithPrice, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"api-calls/{id}".replace("{id}", &format!("{}", id))
Expand Down Expand Up @@ -207,7 +207,7 @@
) -> Result<crate::types::AsyncApiCallResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "async/operations"),
format!("{}/{}", self.client.base_url, "async/operations"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -274,7 +274,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "async/operations"),
format!("{}/{}", self.client.base_url, "async/operations"),

Check warning on line 277 in kittycad/src/api_calls.rs

View check run for this annotation

Codecov / codecov/patch

kittycad/src/api_calls.rs#L277

Added line #L277 was not covered by tests
);
req = req.bearer_auth(&self.client.token);
let mut request = req.build()?;
Expand Down Expand Up @@ -338,7 +338,7 @@
) -> Result<crate::types::AsyncApiCallOutput, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"async/operations/{id}".replace("{id}", &format!("{}", id))
Expand Down Expand Up @@ -374,7 +374,7 @@
) -> Result<crate::types::ApiCallWithPriceResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "org/api-calls"),
format!("{}/{}", self.client.base_url, "org/api-calls"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -437,7 +437,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "org/api-calls"),
format!("{}/{}", self.client.base_url, "org/api-calls"),

Check warning on line 440 in kittycad/src/api_calls.rs

View check run for this annotation

Codecov / codecov/patch

kittycad/src/api_calls.rs#L440

Added line #L440 was not covered by tests
);
req = req.bearer_auth(&self.client.token);
let mut request = req.build()?;
Expand Down Expand Up @@ -490,7 +490,7 @@
) -> Result<crate::types::ApiCallWithPrice, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"org/api-calls/{id}".replace("{id}", &format!("{}", id))
Expand Down Expand Up @@ -526,7 +526,7 @@
) -> Result<crate::types::ApiCallWithPriceResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "user/api-calls"),
format!("{}/{}", self.client.base_url, "user/api-calls"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -589,7 +589,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "user/api-calls"),
format!("{}/{}", self.client.base_url, "user/api-calls"),
);
req = req.bearer_auth(&self.client.token);
let mut request = req.build()?;
Expand Down Expand Up @@ -650,7 +650,7 @@
) -> Result<crate::types::ApiCallWithPrice, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"user/api-calls/{id}".replace("{id}", &format!("{}", id))
Expand Down Expand Up @@ -687,7 +687,7 @@
) -> Result<crate::types::ApiCallWithPriceResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"users/{id}/api-calls".replace("{id}", id)
Expand Down Expand Up @@ -755,7 +755,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(

Check warning on line 758 in kittycad/src/api_calls.rs

View check run for this annotation

Codecov / codecov/patch

kittycad/src/api_calls.rs#L758

Added line #L758 was not covered by tests
"{}/{}",
self.client.base_url,
"users/{id}/api-calls".replace("{id}", id)
Expand Down
10 changes: 5 additions & 5 deletions kittycad/src/api_tokens.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
) -> Result<crate::types::ApiTokenResultsPage, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "user/api-tokens"),
format!("{}/{}", self.client.base_url, "user/api-tokens"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -84,7 +84,7 @@
async {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "user/api-tokens"),
format!("{}/{}", self.client.base_url, "user/api-tokens"),

Check warning on line 87 in kittycad/src/api_tokens.rs

View check run for this annotation

Codecov / codecov/patch

kittycad/src/api_tokens.rs#L87

Added line #L87 was not covered by tests
);
req = req.bearer_auth(&self.client.token);
let mut request = req.build()?;
Expand Down Expand Up @@ -144,7 +144,7 @@
) -> Result<crate::types::ApiToken, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "user/api-tokens"),
format!("{}/{}", self.client.base_url, "user/api-tokens"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![];
Expand Down Expand Up @@ -187,7 +187,7 @@
) -> Result<crate::types::ApiToken, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"user/api-tokens/{token}".replace("{token}", token)
Expand Down Expand Up @@ -228,7 +228,7 @@
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::DELETE,
&format!(
format!(
"{}/{}",
self.client.base_url,
"user/api-tokens/{token}".replace("{token}", token)
Expand Down
6 changes: 3 additions & 3 deletions kittycad/src/apps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ impl Apps {
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "apps/github/callback"),
format!("{}/{}", self.client.base_url, "apps/github/callback"),
);
req = req.bearer_auth(&self.client.token);
req = req.json(body);
Expand Down Expand Up @@ -58,7 +58,7 @@ impl Apps {
) -> Result<crate::types::AppClientInfo, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "apps/github/consent"),
format!("{}/{}", self.client.base_url, "apps/github/consent"),
);
req = req.bearer_auth(&self.client.token);
let resp = req.send().await?;
Expand Down Expand Up @@ -88,7 +88,7 @@ impl Apps {
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "apps/github/webhook"),
format!("{}/{}", self.client.base_url, "apps/github/webhook"),
);
req = req.bearer_auth(&self.client.token);
req = req.body(body.clone());
Expand Down
2 changes: 1 addition & 1 deletion kittycad/src/executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl Executor {
) -> Result<crate::types::CodeOutput, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!(
format!(
"{}/{}",
self.client.base_url,
"file/execute/{lang}".replace("{lang}", &format!("{}", lang))
Expand Down
12 changes: 6 additions & 6 deletions kittycad/src/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ impl File {
) -> Result<crate::types::FileCenterOfMass, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "file/center-of-mass"),
format!("{}/{}", self.client.base_url, "file/center-of-mass"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![("src_format", format!("{}", src_format))];
Expand Down Expand Up @@ -78,7 +78,7 @@ impl File {
) -> Result<crate::types::FileConversion, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!(
format!(
"{}/{}",
self.client.base_url,
"file/conversion/{src_format}/{output_format}"
Expand Down Expand Up @@ -141,7 +141,7 @@ impl File {
) -> Result<crate::types::FileDensity, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "file/density"),
format!("{}/{}", self.client.base_url, "file/density"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![
Expand Down Expand Up @@ -189,7 +189,7 @@ impl File {
) -> Result<crate::types::FileMass, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "file/mass"),
format!("{}/{}", self.client.base_url, "file/mass"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![
Expand Down Expand Up @@ -252,7 +252,7 @@ impl File {
) -> Result<crate::types::FileSurfaceArea, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "file/surface-area"),
format!("{}/{}", self.client.base_url, "file/surface-area"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![("src_format", format!("{}", src_format))];
Expand Down Expand Up @@ -308,7 +308,7 @@ impl File {
) -> Result<crate::types::FileVolume, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "file/volume"),
format!("{}/{}", self.client.base_url, "file/volume"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![("src_format", format!("{}", src_format))];
Expand Down
10 changes: 5 additions & 5 deletions kittycad/src/hidden.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ impl Hidden {
) -> Result<crate::types::VerificationTokenResponse, crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "auth/email"),
format!("{}/{}", self.client.base_url, "auth/email"),
);
req = req.bearer_auth(&self.client.token);
req = req.json(body);
Expand Down Expand Up @@ -53,7 +53,7 @@ impl Hidden {
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!("{}/{}", self.client.base_url, "auth/email/callback"),
format!("{}/{}", self.client.base_url, "auth/email/callback"),
);
req = req.bearer_auth(&self.client.token);
let mut query_params = vec![
Expand Down Expand Up @@ -87,7 +87,7 @@ impl Hidden {
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::GET,
&format!(
format!(
"{}/{}",
self.client.base_url,
"auth/saml/provider/{provider_id}/login"
Expand Down Expand Up @@ -129,7 +129,7 @@ impl Hidden {
) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!(
format!(
"{}/{}",
self.client.base_url,
"auth/saml/provider/{provider_id}/login"
Expand Down Expand Up @@ -159,7 +159,7 @@ impl Hidden {
pub async fn logout<'a>(&'a self) -> Result<(), crate::types::error::Error> {
let mut req = self.client.client.request(
http::Method::POST,
&format!("{}/{}", self.client.base_url, "logout"),
format!("{}/{}", self.client.base_url, "logout"),
);
req = req.bearer_auth(&self.client.token);
let resp = req.send().await?;
Expand Down
2 changes: 1 addition & 1 deletion kittycad/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
//!
//! ```toml
//! [dependencies]
//! kittycad = "0.3.18"
//! kittycad = "0.3.19"
//! ```
//!
//! ## Basic example
Expand Down
Loading
Loading