Struct gusto_api::contractors::Contractors [−][src]
pub struct Contractors { /* fields omitted */ }
Implementations
Get a contractor.
This function performs a GET
to the /v1/contractors/{contractor_id_or_uuid}
endpoint.
Get a contractor.
pub async fn put_contractor(
&self,
contractor_id_or_uuid: &str,
body: &PutContractorRequest
) -> Result<Contractor>
pub async fn put_contractor(
&self,
contractor_id_or_uuid: &str,
body: &PutContractorRequest
) -> Result<Contractor>
Update a contractor.
This function performs a PUT
to the /v1/contractors/{contractor_id_or_uuid}
endpoint.
Update a contractor.
pub async fn get_company_contractors(
&self,
company_id_or_uuid: &str
) -> Result<Vec<Contractor>>
pub async fn get_company_contractors(
&self,
company_id_or_uuid: &str
) -> Result<Vec<Contractor>>
Get contractors of a company.
This function performs a GET
to the /v1/companies/{company_id_or_uuid}/contractors
endpoint.
Get all contractors, active and inactive, individual and business, for a company.
pub async fn get_all_company_contractors(
&self,
company_id_or_uuid: &str
) -> Result<Vec<Contractor>>
pub async fn get_all_company_contractors(
&self,
company_id_or_uuid: &str
) -> Result<Vec<Contractor>>
Get contractors of a company.
This function performs a GET
to the /v1/companies/{company_id_or_uuid}/contractors
endpoint.
As opposed to get_company_contractors
, this function returns all the pages of the request at once.
Get all contractors, active and inactive, individual and business, for a company.
pub async fn post_company_contractor(
&self,
company_id_or_uuid: &str,
body: &PostCompanyContractorRequest
) -> Result<Contractor>
pub async fn post_company_contractor(
&self,
company_id_or_uuid: &str,
body: &PostCompanyContractorRequest
) -> Result<Contractor>
Create a contractor.
This function performs a POST
to the /v1/companies/{company_id_or_uuid}/contractors
endpoint.
Create an individual or business contractor.