-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Jess Frazelle <[email protected]>
- Loading branch information
Showing
4 changed files
with
7 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -59,7 +59,7 @@ | |
"op": "add", | ||
"path": "/paths/~1v1~1employments/post/x-rust", | ||
"value": { | ||
"example": "/// Create employment\n/// \n/// Creates an employment. We support creating employees and contractors.\n/// \n/// This endpoint requires and returns country-specific data. The exact required and returned fields will\n/// vary depending on which country the employment is in. To see the list of parameters for each country,\n/// see the **Show form schema** endpoint under the [Countries](#tag/Countries) category.\n/// \n/// Please note that the compliance requirements for each country are subject to change, which will result\n/// in required and optional parameters being added and deleted without notice.\n/// \n/// If you are using this endpoint to build an integration, make sure you are dynamically collecting or\n/// displaying the latest parameters for each country by querying the _\"Show form schema\"_ endpoint.\n/// \n/// For more information on JSON Schemas, see the **How JSON Schemas work** documentation.\n/// \n/// To learn how you can dynamically generate forms to display in your UI, see the documentation for\n/// the [json-schema-form](https://www.notion.so/remotecom/json-schema-form-Documentation-4f390236948b4b2e8b7350ebcd488ca6) tool.\n/// \n/// \nasync fn example_employments_post_create() -> anyhow::Result<()> {\n let client = remote_api::Client::new_from_env();\n let result: remote_api::types::EmploymentResponse = client\n .employments()\n .post_create(&remote_api::types::EmploymentBasicParams {\n company_id: \"some-string\".to_string(),\n country_code: Some(\"some-string\".to_string()),\n full_name: \"some-string\".to_string(),\n job_title: \"some-string\".to_string(),\n personal_email: \"[email protected]\".to_string(),\n provisional_start_date: Some(chrono::Utc::now().date_naive()),\n type_: remote_api::types::EmploymentBasicParamsType::Contractor,\n })\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", | ||
"example": "/// Create employment\n/// \n/// Creates an employment. We support creating employees and contractors.\n/// \n/// This endpoint requires and returns country-specific data. The exact required and returned fields will\n/// vary depending on which country the employment is in. To see the list of parameters for each country,\n/// see the **Show form schema** endpoint under the [Countries](#tag/Countries) category.\n/// \n/// Please note that the compliance requirements for each country are subject to change, which will result\n/// in required and optional parameters being added and deleted without notice.\n/// \n/// If you are using this endpoint to build an integration, make sure you are dynamically collecting or\n/// displaying the latest parameters for each country by querying the _\"Show form schema\"_ endpoint.\n/// \n/// For more information on JSON Schemas, see the **How JSON Schemas work** documentation.\n/// \n/// To learn how you can dynamically generate forms to display in your UI, see the documentation for\n/// the [json-schema-form](https://www.notion.so/remotecom/json-schema-form-Documentation-4f390236948b4b2e8b7350ebcd488ca6) tool.\n/// \n/// \nasync fn example_employments_post_create() -> anyhow::Result<()> {\n let client = remote_api::Client::new_from_env();\n let result: remote_api::types::EmploymentResponse = client\n .employments()\n .post_create(&remote_api::types::EmploymentBasicParams {\n company_id: \"some-string\".to_string(),\n country_code: Some(\"some-string\".to_string()),\n full_name: \"some-string\".to_string(),\n job_title: Some(\"some-string\".to_string()),\n personal_email: \"[email protected]\".to_string(),\n provisional_start_date: Some(chrono::Utc::now().date_naive()),\n type_: remote_api::types::EmploymentBasicParamsType::Contractor,\n })\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n", | ||
"libDocsLink": "https://docs.rs/remote-api/latest/remote-api/employments/struct.Employments.html#method.post_create" | ||
} | ||
}, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -58,7 +58,7 @@ impl Employments { | |
} | ||
} | ||
|
||
#[doc = "Create employment\n\nCreates an employment. We support creating employees and contractors.\n\nThis endpoint requires and returns country-specific data. The exact required and returned fields will\nvary depending on which country the employment is in. To see the list of parameters for each country,\nsee the **Show form schema** endpoint under the [Countries](#tag/Countries) category.\n\nPlease note that the compliance requirements for each country are subject to change, which will result\nin required and optional parameters being added and deleted without notice.\n\nIf you are using this endpoint to build an integration, make sure you are dynamically collecting or\ndisplaying the latest parameters for each country by querying the _\"Show form schema\"_ endpoint.\n\nFor more information on JSON Schemas, see the **How JSON Schemas work** documentation.\n\nTo learn how you can dynamically generate forms to display in your UI, see the documentation for\nthe [json-schema-form](https://www.notion.so/remotecom/json-schema-form-Documentation-4f390236948b4b2e8b7350ebcd488ca6) tool.\n\n\n\n```rust,no_run\nasync fn example_employments_post_create() -> anyhow::Result<()> {\n let client = remote_api::Client::new_from_env();\n let result: remote_api::types::EmploymentResponse = client\n .employments()\n .post_create(&remote_api::types::EmploymentBasicParams {\n company_id: \"some-string\".to_string(),\n country_code: Some(\"some-string\".to_string()),\n full_name: \"some-string\".to_string(),\n job_title: \"some-string\".to_string(),\n personal_email: \"[email protected]\".to_string(),\n provisional_start_date: Some(chrono::Utc::now().date_naive()),\n type_: remote_api::types::EmploymentBasicParamsType::Contractor,\n })\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n```"] | ||
#[doc = "Create employment\n\nCreates an employment. We support creating employees and contractors.\n\nThis endpoint requires and returns country-specific data. The exact required and returned fields will\nvary depending on which country the employment is in. To see the list of parameters for each country,\nsee the **Show form schema** endpoint under the [Countries](#tag/Countries) category.\n\nPlease note that the compliance requirements for each country are subject to change, which will result\nin required and optional parameters being added and deleted without notice.\n\nIf you are using this endpoint to build an integration, make sure you are dynamically collecting or\ndisplaying the latest parameters for each country by querying the _\"Show form schema\"_ endpoint.\n\nFor more information on JSON Schemas, see the **How JSON Schemas work** documentation.\n\nTo learn how you can dynamically generate forms to display in your UI, see the documentation for\nthe [json-schema-form](https://www.notion.so/remotecom/json-schema-form-Documentation-4f390236948b4b2e8b7350ebcd488ca6) tool.\n\n\n\n```rust,no_run\nasync fn example_employments_post_create() -> anyhow::Result<()> {\n let client = remote_api::Client::new_from_env();\n let result: remote_api::types::EmploymentResponse = client\n .employments()\n .post_create(&remote_api::types::EmploymentBasicParams {\n company_id: \"some-string\".to_string(),\n country_code: Some(\"some-string\".to_string()),\n full_name: \"some-string\".to_string(),\n job_title: Some(\"some-string\".to_string()),\n personal_email: \"[email protected]\".to_string(),\n provisional_start_date: Some(chrono::Utc::now().date_naive()),\n type_: remote_api::types::EmploymentBasicParamsType::Contractor,\n })\n .await?;\n println!(\"{:?}\", result);\n Ok(())\n}\n```"] | ||
#[tracing::instrument] | ||
pub async fn post_create<'a>( | ||
&'a self, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters