diff --git a/kittycad.rs b/kittycad.rs index 3a2b54e..4faf73d 160000 --- a/kittycad.rs +++ b/kittycad.rs @@ -1 +1 @@ -Subproject commit 3a2b54e0b783f7940d4fecec08e43e8f8d02d730 +Subproject commit 4faf73d65bcf815cd7e0fd5efbcadef8bb96b0b7 diff --git a/rippling/rippling-api.rs.patch.json b/rippling/rippling-api.rs.patch.json new file mode 100644 index 0000000..e0f0f8d --- /dev/null +++ b/rippling/rippling-api.rs.patch.json @@ -0,0 +1,138 @@ +[ + { + "op": "add", + "path": "/info/x-rust", + "value": { + "client": "// Authenticate via an API token.\nlet client = rippling-api::Client::new(\"$TOKEN\");\n\n// - OR -\n\n// Authenticate with your token and host parsed from the environment variables:\n// `RIPPLING_API_TOKEN`.\nlet client = rippling_api::Client::new_from_env();", + "install": "[dependencies]\nrippling-api = \"0.1.0\"" + } + }, + { + "op": "add", + "path": "/paths/~1companies/get/x-rust", + "value": { + "example": "/// List companies\n/// \n/// A List of companies\n/// - Requires: `API Tier 1`\n/// - Expandable fields: `legal_entities`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `order_by: Option`\nasync fn example_companies_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListCompaniesResponse = client\n .companies()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/companies/struct.Companies.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1custom-fields/get/x-rust", + "value": { + "example": "/// List custom fields\n/// \n/// A List of custom fields\n/// - Requires: `API Tier 1`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `order_by: Option`\nasync fn example_custom_fields_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListCustomFieldsResponse = client\n .custom_fields()\n .list(Some(\"some-string\".to_string()))\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/custom_fields/struct.CustomFields.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1departments/get/x-rust", + "value": { + "example": "/// List departments\n/// \n/// A List of departments\n/// - Requires: `API Tier 1`\n/// - Expandable fields: `parent`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `order_by: Option`\nasync fn example_departments_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListDepartmentsResponse = client\n .departments()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/departments/struct.Departments.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1departments~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific department\n/// \n/// Retrieve a specific department\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_departments_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetDepartmentsResponse = client\n .departments()\n .get(\n Some(\"some-string\".to_string()),\n uuid::Uuid::from_str(\"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\")?,\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/departments/struct.Departments.html#method.get" + } + }, + { + "op": "add", + "path": "/paths/~1employment-types/get/x-rust", + "value": { + "example": "/// List employment types\n/// \n/// A List of employment types\n/// - Requires: `API Tier 1`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `order_by: Option`\nasync fn example_employment_types_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListEmploymentTypesResponse = client\n .employment_types()\n .list(Some(\"some-string\".to_string()))\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/employment_types/struct.EmploymentTypes.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1employment-types~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific employment type\n/// \n/// Retrieve a specific employment type\n/// \n/// **Parameters:**\n/// \n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_employment_types_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetEmploymentTypesResponse = client\n .employment_types()\n .get(uuid::Uuid::from_str(\n \"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\",\n )?)\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/employment_types/struct.EmploymentTypes.html#method.get" + } + }, + { + "op": "add", + "path": "/paths/~1entitlements/get/x-rust", + "value": { + "example": "/// List entitlements\n/// \n/// A List of entitlements\n/// - Requires: `API Tier 1`\nasync fn example_entitlements_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListEntitlementsResponse = client.entitlements().list().await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/entitlements/struct.Entitlements.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1sso-me/get/x-rust", + "value": { + "example": "/// Retrieve my SSO information\n/// \n/// SSO information of the current user\n/// - Requires: `API Tier 1`\n/// - Expandable fields: `company`\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\nasync fn example_me_list_sso() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::Ssome = client\n .me()\n .list_sso(Some(\"some-string\".to_string()))\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/me/struct.Me.html#method.list_sso" + } + }, + { + "op": "add", + "path": "/paths/~1teams/get/x-rust", + "value": { + "example": "/// List teams\n/// \n/// A List of teams\n/// - Requires: `API Tier 1`\n/// - Expandable fields: `parent`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `order_by: Option`\nasync fn example_teams_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListTeamsResponse = client\n .teams()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/teams/struct.Teams.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1teams~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific team\n/// \n/// Retrieve a specific team\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_teams_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetTeamsResponse = client\n .teams()\n .get(\n Some(\"some-string\".to_string()),\n uuid::Uuid::from_str(\"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\")?,\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/teams/struct.Teams.html#method.get" + } + }, + { + "op": "add", + "path": "/paths/~1users/get/x-rust", + "value": { + "example": "/// List users\n/// \n/// A List of users\n/// - Requires: `API Tier 1`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `order_by: Option`\nasync fn example_users_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListUsersResponse =\n client.users().list(Some(\"some-string\".to_string())).await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/users/struct.Users.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1users~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific user\n/// \n/// Retrieve a specific user\n/// \n/// **Parameters:**\n/// \n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_users_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetUsersResponse = client\n .users()\n .get(uuid::Uuid::from_str(\n \"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\",\n )?)\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/users/struct.Users.html#method.get" + } + }, + { + "op": "add", + "path": "/paths/~1work-locations/get/x-rust", + "value": { + "example": "/// List work locations\n/// \n/// A List of work locations\n/// - Requires: `API Tier 1`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `order_by: Option`\nasync fn example_work_locations_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListWorkLocationsResponse = client\n .work_locations()\n .list(Some(\"some-string\".to_string()))\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/work_locations/struct.WorkLocations.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1work-locations~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific work location\n/// \n/// Retrieve a specific work location\n/// \n/// **Parameters:**\n/// \n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_work_locations_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetWorkLocationsResponse = client\n .work_locations()\n .get(uuid::Uuid::from_str(\n \"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\",\n )?)\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/work_locations/struct.WorkLocations.html#method.get" + } + }, + { + "op": "add", + "path": "/paths/~1workers/get/x-rust", + "value": { + "example": "/// List workers\n/// \n/// A List of workers\n/// - Requires: `API Tier 1`\n/// - Filterable fields: `status`, `work_email`\n/// - Expandable fields: `user`, `legal_entity`, `employment_type`, `compensation`, `department`, `teams`, `level`, `custom_fields`\n/// - Sortable fields: `id`, `created_at`, `updated_at`\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `filter: Option`\n/// - `order_by: Option`\nasync fn example_workers_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListWorkersResponse = client\n .workers()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/workers/struct.Workers.html#method.list" + } + }, + { + "op": "add", + "path": "/paths/~1workers~1{id}/get/x-rust", + "value": { + "example": "/// Retrieve a specific worker\n/// \n/// Retrieve a specific worker\n/// \n/// **Parameters:**\n/// \n/// - `expand: Option`\n/// - `id: &'astr`: ID of the resource to return (required)\nuse std::str::FromStr;\nasync fn example_workers_get() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::GetWorkersResponse = client\n .workers()\n .get(\n Some(\"some-string\".to_string()),\n uuid::Uuid::from_str(\"d9797f8d-9ad6-4e08-90d7-2ec17e13471c\")?,\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", + "libDocsLink": "https://docs.rs/rippling-api/latest/rippling-api/workers/struct.Workers.html#method.get" + } + } +] \ No newline at end of file diff --git a/rippling/src/companies.rs b/rippling/src/companies.rs index 5f53fa1..ecb46f6 100644 --- a/rippling/src/companies.rs +++ b/rippling/src/companies.rs @@ -12,7 +12,7 @@ impl Companies { Self { client } } - #[doc = "List companies\n\nA List of companies\n- Requires: `API Tier 1`\n- Expandable fields: `parent_legal_entity`, `legal_entities`\n- Sortable fields: `id`, `created_at`, `updated_at`\n\n**Parameters:**\n\n- `expand: Option`\n- `order_by: Option`\n\n```rust,no_run\nasync fn example_companies_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListCompaniesResponse = client\n .companies()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n```"] + #[doc = "List companies\n\nA List of companies\n- Requires: `API Tier 1`\n- Expandable fields: `legal_entities`\n- Sortable fields: `id`, `created_at`, `updated_at`\n\n**Parameters:**\n\n- `expand: Option`\n- `order_by: Option`\n\n```rust,no_run\nasync fn example_companies_list() -> anyhow::Result<()> {\n let client = rippling_api::Client::new_from_env();\n let result: rippling_api::types::ListCompaniesResponse = client\n .companies()\n .list(\n Some(\"some-string\".to_string()),\n Some(\"some-string\".to_string()),\n )\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n```"] #[tracing::instrument] pub async fn list<'a>( &'a self, @@ -43,7 +43,6 @@ impl Companies { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/custom_fields.rs b/rippling/src/custom_fields.rs index 35260d6..1c3a297 100644 --- a/rippling/src/custom_fields.rs +++ b/rippling/src/custom_fields.rs @@ -44,7 +44,6 @@ impl CustomFields { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/departments.rs b/rippling/src/departments.rs index 595eb19..d55b847 100644 --- a/rippling/src/departments.rs +++ b/rippling/src/departments.rs @@ -43,7 +43,6 @@ impl Departments { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -74,7 +73,7 @@ impl Departments { &format!( "{}/{}", self.client.base_url, - "departments/{id}".replace("{id}", &id) + "departments/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -93,7 +92,6 @@ impl Departments { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/employment_types.rs b/rippling/src/employment_types.rs index a00d049..2fb5410 100644 --- a/rippling/src/employment_types.rs +++ b/rippling/src/employment_types.rs @@ -44,7 +44,6 @@ impl EmploymentTypes { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -74,7 +73,7 @@ impl EmploymentTypes { &format!( "{}/{}", self.client.base_url, - "employment-types/{id}".replace("{id}", &id) + "employment-types/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -87,7 +86,6 @@ impl EmploymentTypes { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/entitlements.rs b/rippling/src/entitlements.rs index 23b73c5..9b9be0f 100644 --- a/rippling/src/entitlements.rs +++ b/rippling/src/entitlements.rs @@ -31,7 +31,6 @@ impl Entitlements { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/me.rs b/rippling/src/me.rs index 3e83fed..f643fa4 100644 --- a/rippling/src/me.rs +++ b/rippling/src/me.rs @@ -44,7 +44,6 @@ impl Me { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/teams.rs b/rippling/src/teams.rs index d8001c4..d635c3e 100644 --- a/rippling/src/teams.rs +++ b/rippling/src/teams.rs @@ -43,7 +43,6 @@ impl Teams { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -73,7 +72,7 @@ impl Teams { &format!( "{}/{}", self.client.base_url, - "teams/{id}".replace("{id}", &id) + "teams/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -92,7 +91,6 @@ impl Teams { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/types.rs b/rippling/src/types.rs index f02812d..2ad324c 100644 --- a/rippling/src/types.rs +++ b/rippling/src/types.rs @@ -1,6 +1,4 @@ #![doc = r" This module contains the generated types for the library."] -#[cfg(feature = "tabled")] -use tabled::Tabled; pub mod base64 { #![doc = " Base64 data that encodes to url safe base64, but can decode from multiple"] #![doc = " base64 implementations to account for various clients and libraries. Compatible"] @@ -4556,7 +4554,7 @@ pub struct Team { pub parent_id: Option, #[doc = "The parent team\n\nExpandable field"] #[serde(default, skip_serializing_if = "Option::is_none")] - pub parent: Option, + pub parent: Option>, #[doc = "The name of the team."] pub name: String, } @@ -4664,7 +4662,7 @@ pub struct Department { pub parent_id: Option, #[doc = "The parent department.\n\nExpandable field"] #[serde(default, skip_serializing_if = "Option::is_none")] - pub parent: Option, + pub parent: Option>, } impl std::fmt::Display for Department { @@ -4766,9 +4764,6 @@ pub struct Compensation { #[doc = "The worker's ID."] #[serde(default, skip_serializing_if = "Option::is_none")] pub worker_id: Option, - #[doc = "The worker's details.\n\nExpandable field"] - #[serde(default, skip_serializing_if = "Option::is_none")] - pub worker: Option, #[doc = "The worker's annual compensation. This calculation assumes 40-hour work weeks for \ workers with an hourly wage."] #[serde(default, skip_serializing_if = "Option::is_none")] @@ -4829,7 +4824,7 @@ impl std::fmt::Display for Compensation { #[cfg(feature = "tabled")] impl tabled::Tabled for Compensation { - const LENGTH: usize = 18; + const LENGTH: usize = 17; fn fields(&self) -> Vec> { vec![ self.id.clone().into(), @@ -4840,11 +4835,6 @@ impl tabled::Tabled for Compensation { } else { String::new().into() }, - if let Some(worker) = &self.worker { - format!("{:?}", worker).into() - } else { - String::new().into() - }, if let Some(annual_compensation) = &self.annual_compensation { format!("{:?}", annual_compensation).into() } else { @@ -4919,7 +4909,6 @@ impl tabled::Tabled for Compensation { "created_at".into(), "updated_at".into(), "worker_id".into(), - "worker".into(), "annual_compensation".into(), "annual_salary_equivalent".into(), "hourly_wage".into(), @@ -5693,7 +5682,7 @@ pub struct LegalEntity { pub parent_id: Option, #[doc = "The parent legal entity.\n\nExpandable field"] #[serde(default, skip_serializing_if = "Option::is_none")] - pub parent: Option, + pub parent: Option>, #[doc = "The legal entity management type in the case of an employer of record (EOR) or \ professional employment organization (PEO). * `PEO`: The legal entity is considered \ a Professional Employment Organization (PEO). * `EOR`: The legal entity is \ @@ -5703,9 +5692,6 @@ pub struct LegalEntity { #[doc = "The company or organization associated with the legal entity"] #[serde(default, skip_serializing_if = "Option::is_none")] pub company_id: Option, - #[doc = "The company or organization associated with the legal entity\n\nExpandable field"] - #[serde(default, skip_serializing_if = "Option::is_none")] - pub company: Option, } impl std::fmt::Display for LegalEntity { @@ -5720,7 +5706,7 @@ impl std::fmt::Display for LegalEntity { #[cfg(feature = "tabled")] impl tabled::Tabled for LegalEntity { - const LENGTH: usize = 15; + const LENGTH: usize = 14; fn fields(&self) -> Vec> { vec![ self.id.clone().into(), @@ -5781,11 +5767,6 @@ impl tabled::Tabled for LegalEntity { } else { String::new().into() }, - if let Some(company) = &self.company { - format!("{:?}", company).into() - } else { - String::new().into() - }, ] } @@ -5805,7 +5786,6 @@ impl tabled::Tabled for LegalEntity { "parent".into(), "management_type".into(), "company_id".into(), - "company".into(), ] } } @@ -5951,9 +5931,6 @@ pub struct Company { #[doc = "The company's ultimate holding entity."] #[serde(default, skip_serializing_if = "Option::is_none")] pub parent_legal_entity_id: Option, - #[doc = "The company's ultimate holding entity.\n\nExpandable field"] - #[serde(default, skip_serializing_if = "Option::is_none")] - pub parent_legal_entity: Option, #[doc = "A list of the company's entities."] pub legal_entities_id: String, #[doc = "A list of the company's entities.\n\nExpandable field"] @@ -5989,7 +5966,7 @@ impl std::fmt::Display for Company { #[cfg(feature = "tabled")] impl tabled::Tabled for Company { - const LENGTH: usize = 13; + const LENGTH: usize = 12; fn fields(&self) -> Vec> { vec![ self.id.clone().into(), @@ -6000,11 +5977,6 @@ impl tabled::Tabled for Company { } else { String::new().into() }, - if let Some(parent_legal_entity) = &self.parent_legal_entity { - format!("{:?}", parent_legal_entity).into() - } else { - String::new().into() - }, self.legal_entities_id.clone().into(), format!("{:?}", self.legal_entities).into(), if let Some(physical_address) = &self.physical_address { @@ -6042,7 +6014,6 @@ impl tabled::Tabled for Company { "created_at".into(), "updated_at".into(), "parent_legal_entity_id".into(), - "parent_legal_entity".into(), "legal_entities_id".into(), "legal_entities".into(), "physical_address".into(), diff --git a/rippling/src/users.rs b/rippling/src/users.rs index e3b88d2..f3d4f69 100644 --- a/rippling/src/users.rs +++ b/rippling/src/users.rs @@ -44,7 +44,6 @@ impl Users { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -66,7 +65,7 @@ impl Users { &format!( "{}/{}", self.client.base_url, - "users/{id}".replace("{id}", &id) + "users/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -79,7 +78,6 @@ impl Users { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/work_locations.rs b/rippling/src/work_locations.rs index 5f828c7..4e6a141 100644 --- a/rippling/src/work_locations.rs +++ b/rippling/src/work_locations.rs @@ -44,7 +44,6 @@ impl WorkLocations { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -66,7 +65,7 @@ impl WorkLocations { &format!( "{}/{}", self.client.base_url, - "work-locations/{id}".replace("{id}", &id) + "work-locations/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -79,7 +78,6 @@ impl WorkLocations { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/rippling/src/workers.rs b/rippling/src/workers.rs index 321857d..5ba1f44 100644 --- a/rippling/src/workers.rs +++ b/rippling/src/workers.rs @@ -48,7 +48,6 @@ impl Workers { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); @@ -71,7 +70,7 @@ impl Workers { &format!( "{}/{}", self.client.base_url, - "workers/{id}".replace("{id}", &id) + "workers/{id}".replace("{id}", id) ), ); req = req.bearer_auth(&self.client.token); @@ -90,7 +89,6 @@ impl Workers { format_serde_error::SerdeError::new(text.to_string(), err), status, ) - .into() }) } else { let text = resp.text().await.unwrap_or_default(); diff --git a/specs/rippling.yaml b/specs/rippling.yaml index 1c8666f..78ef910 100644 --- a/specs/rippling.yaml +++ b/specs/rippling.yaml @@ -459,13 +459,12 @@ paths: - Companies summary: List companies description: "A List of companies\n - Requires: `API Tier 1`\n - Expandable\ - \ fields: `parent_legal_entity`, `legal_entities`\n - Sortable fields: `id`,\ + \ fields: `legal_entities`\n - Sortable fields: `id`,\ \ `created_at`, `updated_at`" parameters: - $ref: '#/components/parameters/expand' - $ref: '#/components/parameters/order_by' x-rippling-expandable-fields: - - parent_legal_entity - legal_entities x-rippling-sortable-fields: - id @@ -2460,14 +2459,6 @@ components: worker_id: type: string description: The worker's ID. - worker: - type: object - description: 'The worker''s details. - - - Expandable field' - allOf: - - $ref: '#/components/schemas/Worker' annual_compensation: type: object description: The worker's annual compensation. This calculation assumes @@ -2534,7 +2525,6 @@ components: description: The payment terms for an worker's compensation. description: '' x-rippling-expandable-fields: - - worker required: - id - created_at @@ -2843,18 +2833,9 @@ components: company_id: type: string description: The company or organization associated with the legal entity - company: - type: object - description: 'The company or organization associated with the legal entity - - - Expandable field' - allOf: - - $ref: '#/components/schemas/Company' description: '' x-rippling-expandable-fields: - parent - - company required: - id - created_at @@ -2933,14 +2914,6 @@ components: parent_legal_entity_id: type: string description: The company's ultimate holding entity. - parent_legal_entity: - type: object - description: 'The company''s ultimate holding entity. - - - Expandable field' - allOf: - - $ref: '#/components/schemas/LegalEntity' legal_entities_id: type: string description: A list of the company's entities. @@ -2974,7 +2947,6 @@ components: description: The name of the company. description: '' x-rippling-expandable-fields: - - parent_legal_entity - legal_entities required: - id