pub struct PriceListClient { /* private fields */ }Expand description
Calls PriceListService.
The public price list: the list price of every billable product, for anyone to read, websites included. It needs no access token.
Unlike the rest of this API, its path has been /v1/pricing since before
the API was published, and its fields are written in snake case, as
websites read them.
Implementations§
Source§impl PriceListClient
impl PriceListClient
Sourcepub fn new(client: &Client) -> Self
pub fn new(client: &Client) -> Self
Returns a client of PriceListService that sends its calls through client.
Sourcepub fn service(&self) -> &Service
pub fn service(&self) -> &Service
The endpoint the client sends its calls to, which also serves the operations its methods answer with.
Sourcepub fn with_options(&self, options: CallOptions) -> Self
pub fn with_options(&self, options: CallOptions) -> Self
The same client, whose calls are sent as options says instead of as the Client’s settings do, such as a mutation that must not be sent twice: .with_options(CallOptions::new().max_attempts(1)). See CallOptions.
Sourcepub async fn get_price_list(
&self,
request: GetPriceListRequest,
) -> Result<PriceList, Error>
pub async fn get_price_list( &self, request: GetPriceListRequest, ) -> Result<PriceList, Error>
Returns the prices in effect now. The answer carries an ETag; a
request that sends it back in If-None-Match is answered
304 Not Modified, without a body, while the list is unchanged.