1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
* Selling Partner API for Merchant Fulfillment
*
* With the Selling Partner API for Merchant Fulfillment, you can build applications that sellers can use to purchase shipping for non-Prime and Prime orders using Amazon's Buy Shipping Services.
*
* The version of the OpenAPI document: v0
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// RejectedShippingService : Information about a rejected shipping service
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RejectedShippingService {
/// The rejected shipping carrier name. For example, USPS.
#[serde(rename = "CarrierName")]
pub carrier_name: String,
/// The rejected shipping service localized name. For example, FedEx Standard Overnight.
#[serde(rename = "ShippingServiceName")]
pub shipping_service_name: String,
/// An Amazon-defined shipping service identifier.
#[serde(rename = "ShippingServiceId")]
pub shipping_service_id: String,
/// A reason code meant to be consumed programatically. For example, `CARRIER_CANNOT_SHIP_TO_POBOX`.
#[serde(rename = "RejectionReasonCode")]
pub rejection_reason_code: String,
/// A localized human readable description of the rejected reason.
#[serde(rename = "RejectionReasonMessage", skip_serializing_if = "Option::is_none")]
pub rejection_reason_message: Option<String>,
}
impl RejectedShippingService {
/// Information about a rejected shipping service
pub fn new(carrier_name: String, shipping_service_name: String, shipping_service_id: String, rejection_reason_code: String) -> RejectedShippingService {
RejectedShippingService {
carrier_name,
shipping_service_name,
shipping_service_id,
rejection_reason_code,
rejection_reason_message: None,
}
}
}