aftership-tracking-sdk 7.0.0 → 9.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -0
- data/README.md +68 -83
- data/lib/aftership-tracking-sdk/api/courier.rb +8 -8
- data/lib/aftership-tracking-sdk/api/estimated_delivery_date.rb +4 -4
- data/lib/aftership-tracking-sdk/api/tracking.rb +50 -416
- data/lib/aftership-tracking-sdk/api_client.rb +2 -2
- data/lib/aftership-tracking-sdk/configuration.rb +108 -108
- data/lib/aftership-tracking-sdk/models/additional_fields_v1.rb +1 -1
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_create_tracking_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_delete_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_get_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_mark_tracking_completed_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_retrack_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_tracking.rb +2 -0
- data/lib/aftership-tracking-sdk/models/aftership_estimated_delivery_date_update_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_create_tracking_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_delete_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_get_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_mark_tracking_completed_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_retrack_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_tracking.rb +2 -0
- data/lib/aftership-tracking-sdk/models/carbon_emissions_update_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/checkpoint.rb +2 -0
- data/lib/aftership-tracking-sdk/models/coordinate_checkpoint.rb +2 -0
- data/lib/aftership-tracking-sdk/models/courier.rb +2 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_create_tracking_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_delete_tracking_by_id_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_get_tracking_by_id_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_mark_tracking_completed_by_id_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_retrack_tracking_by_id_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_tracking.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_estimated_delivery_date_update_tracking_by_id_response.rb +173 -0
- data/lib/aftership-tracking-sdk/models/courier_response_v1.rb +2 -0
- data/lib/aftership-tracking-sdk/models/{tracking_create_tracking_request.rb → create_tracking_request.rb} +9 -7
- data/lib/aftership-tracking-sdk/models/create_tracking_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/{mark_tracking_completed_by_slug_tracking_number_request.rb → custom_estimated_delivery_date_create_tracking_response.rb} +41 -9
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_delete_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_get_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_mark_tracking_completed_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_retrack_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_tracking.rb +2 -0
- data/lib/aftership-tracking-sdk/models/custom_estimated_delivery_date_update_tracking_by_id_response.rb +183 -0
- data/lib/aftership-tracking-sdk/models/data_courier_response_v1.rb +2 -0
- data/lib/aftership-tracking-sdk/models/data_tracking_response_get_multiple_v1.rb +8 -126
- data/lib/aftership-tracking-sdk/models/delete_tracking_by_id_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/destination_address_estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/destination_address_estimated_delivery_date_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/{tracking_detect_courier_request.rb → detect_courier_request.rb} +5 -3
- data/lib/aftership-tracking-sdk/models/detect_courier_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/estimated_delivery_date_response.rb +12 -0
- data/lib/aftership-tracking-sdk/models/estimated_pickup_estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/estimated_pickup_estimated_delivery_date_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/events_checkpoint.rb +2 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_create_tracking_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_delete_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_get_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_mark_tracking_completed_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_retrack_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_tracking.rb +2 -0
- data/lib/aftership-tracking-sdk/models/first_estimated_delivery_update_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/get_all_couriers_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/get_tracking_by_id_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/get_trackings_response.rb +5 -3
- data/lib/aftership-tracking-sdk/models/get_user_couriers_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_create_tracking_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_delete_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_get_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_mark_tracking_completed_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_retrack_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_tracking.rb +2 -0
- data/lib/aftership-tracking-sdk/models/latest_estimated_delivery_update_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/mark_tracking_completed_by_id_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/mark_tracking_completed_by_id_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/meta_v1.rb +2 -0
- data/lib/aftership-tracking-sdk/models/{next_couriers_tracking_create_tracking_request.rb → next_couriers_create_tracking_request.rb} +4 -2
- data/lib/aftership-tracking-sdk/models/{get_checkpoint_by_tracking_id_response.rb → next_couriers_create_tracking_response.rb} +33 -51
- data/lib/aftership-tracking-sdk/models/next_couriers_delete_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/{get_checkpoint_by_slug_tracking_number_response.rb → next_couriers_get_tracking_by_id_response.rb} +33 -51
- data/lib/aftership-tracking-sdk/models/next_couriers_mark_tracking_completed_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/next_couriers_retrack_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/next_couriers_tracking.rb +22 -0
- data/lib/aftership-tracking-sdk/models/next_couriers_update_tracking_by_id_response.rb +193 -0
- data/lib/aftership-tracking-sdk/models/order_processing_time_estimated_pickup_estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/order_processing_time_estimated_pickup_estimated_delivery_date_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/origin_address_estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/origin_address_estimated_delivery_date_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/pagination.rb +14 -6
- data/lib/aftership-tracking-sdk/models/pagination_data_tracking_response_get_multiple_v1.rb +173 -0
- data/lib/aftership-tracking-sdk/models/{notification_request_v1.rb → pagination_get_trackings_response.rb} +28 -16
- data/lib/aftership-tracking-sdk/models/predict_batch_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/predict_batch_response.rb +2 -0
- data/lib/aftership-tracking-sdk/models/reason_events_checkpoint.rb +2 -0
- data/lib/aftership-tracking-sdk/models/retrack_tracking_by_id_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/{tracking_delete_response_v1.rb → shipment_weight_create_tracking_response.rb} +18 -16
- data/lib/aftership-tracking-sdk/models/{data_notification_response_v1.rb → shipment_weight_delete_tracking_by_id_response.rb} +21 -9
- data/lib/aftership-tracking-sdk/models/{notification.rb → shipment_weight_get_tracking_by_id_response.rb} +18 -16
- data/lib/aftership-tracking-sdk/models/shipment_weight_mark_tracking_completed_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/shipment_weight_retrack_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/{notification_response_v1.rb → shipment_weight_tracking.rb} +18 -16
- data/lib/aftership-tracking-sdk/models/shipment_weight_update_tracking_by_id_response.rb +163 -0
- data/lib/aftership-tracking-sdk/models/slug_group_v1.rb +1 -1
- data/lib/aftership-tracking-sdk/models/tag_v1.rb +1 -1
- data/lib/aftership-tracking-sdk/models/tracking.rb +56 -24
- data/lib/aftership-tracking-sdk/models/tracking_response_get_multiple_v1.rb +2 -0
- data/lib/aftership-tracking-sdk/models/tracking_response_v1.rb +5 -3
- data/lib/aftership-tracking-sdk/models/{tracking_update_tracking_by_id_request.rb → update_tracking_by_id_request.rb} +5 -3
- data/lib/aftership-tracking-sdk/models/update_tracking_by_id_response.rb +953 -0
- data/lib/aftership-tracking-sdk/models/weight_estimated_delivery_date_request.rb +2 -0
- data/lib/aftership-tracking-sdk/models/weight_estimated_delivery_date_response.rb +2 -0
- data/lib/aftership-tracking-sdk/version.rb +1 -1
- metadata +64 -22
- data/lib/aftership-tracking-sdk/api/last_checkpoint.rb +0 -143
- data/lib/aftership-tracking-sdk/api/notification.rb +0 -403
- data/lib/aftership-tracking-sdk/models/custom_fields_tracking_update_tracking_by_slug_tracking_number_request.rb +0 -139
- data/lib/aftership-tracking-sdk/models/data_tracking_delete_response_v1.rb +0 -151
- data/lib/aftership-tracking-sdk/models/data_tracking_response_v1.rb +0 -151
- data/lib/aftership-tracking-sdk/models/partial_delete_tracking.rb +0 -241
- data/lib/aftership-tracking-sdk/models/partial_update_tracking.rb +0 -251
- data/lib/aftership-tracking-sdk/models/tracking_update_tracking_by_slug_tracking_number_request.rb +0 -391
@@ -0,0 +1,163 @@
|
|
1
|
+
# This code was auto generated by AfterShip SDK Generator.
|
2
|
+
# Do not edit the class manually.
|
3
|
+
module AftershipAPI::Model
|
4
|
+
class ShipmentWeightUpdateTrackingByIdResponse
|
5
|
+
|
6
|
+
# The unit in which the value field is expressed.
|
7
|
+
# unit?: String;
|
8
|
+
attr_accessor :unit
|
9
|
+
|
10
|
+
# The total amount of shipment weight.
|
11
|
+
# value?: Float;
|
12
|
+
attr_accessor :value
|
13
|
+
|
14
|
+
# Initializes the object
|
15
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
16
|
+
def initialize(attributes = {})
|
17
|
+
if (!attributes.is_a?(Hash))
|
18
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `AftershipAPI::ShipmentWeightUpdateTrackingByIdResponse` initialize method"
|
19
|
+
end
|
20
|
+
|
21
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
22
|
+
h[k.to_sym] = v
|
23
|
+
}
|
24
|
+
|
25
|
+
if attributes.key?(:'unit')
|
26
|
+
self.unit = attributes[:'unit']
|
27
|
+
end
|
28
|
+
|
29
|
+
if attributes.key?(:'value')
|
30
|
+
self.value = attributes[:'value']
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
# Attribute type mapping.
|
35
|
+
def self.openapi_types
|
36
|
+
{
|
37
|
+
:'unit' => :'String',
|
38
|
+
:'value' => :'Float',
|
39
|
+
}
|
40
|
+
end
|
41
|
+
|
42
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
43
|
+
def self.attribute_map
|
44
|
+
{
|
45
|
+
:'unit' => :'unit',
|
46
|
+
:'value' => :'value',
|
47
|
+
}
|
48
|
+
end
|
49
|
+
|
50
|
+
# Builds the object from hash
|
51
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
52
|
+
# @return [Object] Returns the model itself
|
53
|
+
def self.build_from_hash(attributes)
|
54
|
+
return nil unless attributes.is_a?(Hash)
|
55
|
+
attributes = attributes.transform_keys(&:to_sym)
|
56
|
+
transformed_hash = {}
|
57
|
+
openapi_types.each_pair do |key, type|
|
58
|
+
if attributes.key?(key) && attributes[key].nil?
|
59
|
+
transformed_hash["#{key}"] = nil
|
60
|
+
elsif type =~ /\AArray<(.*)>/i
|
61
|
+
# check to ensure the input is an array given that the attribute
|
62
|
+
# is documented as an array but the input is not
|
63
|
+
if attributes[key].is_a?(Array)
|
64
|
+
transformed_hash["#{key}"] = attributes[key].map { |v| _deserialize($1, v) }
|
65
|
+
end
|
66
|
+
elsif !attributes[key].nil?
|
67
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[key])
|
68
|
+
end
|
69
|
+
end
|
70
|
+
new(transformed_hash)
|
71
|
+
end
|
72
|
+
|
73
|
+
# Deserializes the data based on type
|
74
|
+
# @param type [String] Data type
|
75
|
+
# @param value [String] Value to be deserialized
|
76
|
+
# @return [Object] Deserialized data
|
77
|
+
def self._deserialize(type, value)
|
78
|
+
case type.to_sym
|
79
|
+
when :Time
|
80
|
+
Time.parse(value)
|
81
|
+
when :Date
|
82
|
+
Date.parse(value)
|
83
|
+
when :String
|
84
|
+
value.to_s
|
85
|
+
when :Integer
|
86
|
+
value.to_i
|
87
|
+
when :Float
|
88
|
+
value.to_f
|
89
|
+
when :Boolean
|
90
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
91
|
+
true
|
92
|
+
else
|
93
|
+
false
|
94
|
+
end
|
95
|
+
when :Object
|
96
|
+
# generic object (usually a Hash), return directly
|
97
|
+
value
|
98
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
99
|
+
inner_type = Regexp.last_match[:inner_type]
|
100
|
+
value.map { |v| _deserialize(inner_type, v) }
|
101
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
102
|
+
k_type = Regexp.last_match[:k_type]
|
103
|
+
v_type = Regexp.last_match[:v_type]
|
104
|
+
{}.tap do |hash|
|
105
|
+
value.each do |k, v|
|
106
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
107
|
+
end
|
108
|
+
end
|
109
|
+
else # model
|
110
|
+
klass = AftershipAPI::Model.const_get(type)
|
111
|
+
klass.build_from_hash(value)
|
112
|
+
end
|
113
|
+
end
|
114
|
+
|
115
|
+
# Returns the string representation of the object
|
116
|
+
# @return [String] String presentation of the object
|
117
|
+
def to_s
|
118
|
+
to_hash.to_s
|
119
|
+
end
|
120
|
+
|
121
|
+
# to_body is an alias to to_hash (backward compatibility)
|
122
|
+
# @return [Hash] Returns the object in the form of hash
|
123
|
+
def to_body
|
124
|
+
to_hash
|
125
|
+
end
|
126
|
+
|
127
|
+
# Returns the object in the form of hash
|
128
|
+
# @return [Hash] Returns the object in the form of hash
|
129
|
+
def to_hash
|
130
|
+
hash = {}
|
131
|
+
self.class.attribute_map.each_pair do |attr, param|
|
132
|
+
value = self.send(attr)
|
133
|
+
next if value.nil?
|
134
|
+
|
135
|
+
hash[param] = _to_hash(value)
|
136
|
+
end
|
137
|
+
hash
|
138
|
+
end
|
139
|
+
|
140
|
+
# Outputs non-array value in the form of hash
|
141
|
+
# For object, use to_hash. Otherwise, just return the value
|
142
|
+
# @param value [Object] Any valid value
|
143
|
+
# @return [Hash] Returns the value in the form of hash
|
144
|
+
def _to_hash(value)
|
145
|
+
if value.is_a?(Array)
|
146
|
+
value.compact.map { |v| _to_hash(v) }
|
147
|
+
elsif value.is_a?(Hash)
|
148
|
+
{}.tap do |hash|
|
149
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
150
|
+
end
|
151
|
+
elsif value.respond_to? :to_hash
|
152
|
+
value.to_hash
|
153
|
+
else
|
154
|
+
value
|
155
|
+
end
|
156
|
+
end
|
157
|
+
|
158
|
+
def to_json(*a)
|
159
|
+
to_hash.to_json(*a)
|
160
|
+
end
|
161
|
+
end
|
162
|
+
end
|
163
|
+
|
@@ -16,7 +16,7 @@ module AftershipAPI::Model
|
|
16
16
|
FASTWAY_GROUP = "fastway-group".freeze
|
17
17
|
ASENDIA_GROUP = "asendia-group".freeze
|
18
18
|
def self.all_vars
|
19
|
-
@all_vars ||= [AMAZON_GROUP,
|
19
|
+
@all_vars ||= [AMAZON_GROUP,FEDEX_GROUP,TOLL_GROUP,TAQBIN_GROUP,TNT_GROUP,CJ_GROUP,HERMES_GROUP,DPD_GROUP,GLS_GROUP,DHL_GROUP,FASTWAY_GROUP,ASENDIA_GROUP,].freeze
|
20
20
|
end
|
21
21
|
|
22
22
|
# Builds the enum from string
|
@@ -13,7 +13,7 @@ module AftershipAPI::Model
|
|
13
13
|
EXCEPTION = "Exception".freeze
|
14
14
|
EXPIRED = "Expired".freeze
|
15
15
|
def self.all_vars
|
16
|
-
@all_vars ||= [PENDING,
|
16
|
+
@all_vars ||= [PENDING,INFORECEIVED,INTRANSIT,OUTFORDELIVERY,ATTEMPTFAIL,DELIVERED,AVAILABLEFORPICKUP,EXCEPTION,EXPIRED,].freeze
|
17
17
|
end
|
18
18
|
|
19
19
|
# Builds the enum from string
|
@@ -2,10 +2,15 @@
|
|
2
2
|
# Do not edit the class manually.
|
3
3
|
module AftershipAPI::Model
|
4
4
|
class Tracking
|
5
|
+
|
5
6
|
# Tracking ID.
|
6
7
|
# id?: String;
|
7
8
|
attr_accessor :id
|
8
9
|
|
10
|
+
# The length of the tracking ID has been increased from 24 characters to 32 characters. We will use the legacy_id field to store the original 24-character tracking ID to maintain compatibility with existing data. Therefore, all tracking endpoints will continue to work with the legacy_id field as before.
|
11
|
+
# legacy_id?: String;
|
12
|
+
attr_accessor :legacy_id
|
13
|
+
|
9
14
|
# The date and time the shipment was imported or added to AfterShip. It uses the format `YYYY-MM-DDTHH:mm:ssZ` for the timezone GMT +0.
|
10
15
|
# created_at?: String;
|
11
16
|
attr_accessor :created_at
|
@@ -90,9 +95,9 @@ module AftershipAPI::Model
|
|
90
95
|
# emails?: String[];
|
91
96
|
attr_accessor :emails
|
92
97
|
|
93
|
-
# The estimated delivery date provided by the carrier.
|
94
|
-
#
|
95
|
-
attr_accessor :
|
98
|
+
# The field contains the estimated delivery date provided by the carrier.
|
99
|
+
# courier_estimated_delivery_date?: CourierEstimatedDeliveryDateTracking;
|
100
|
+
attr_accessor :courier_estimated_delivery_date
|
96
101
|
|
97
102
|
# Text field for the note.
|
98
103
|
# note?: String;
|
@@ -126,19 +131,15 @@ module AftershipAPI::Model
|
|
126
131
|
# shipment_type?: String;
|
127
132
|
attr_accessor :shipment_type
|
128
133
|
|
129
|
-
#
|
130
|
-
# shipment_weight?:
|
134
|
+
# The shipment_weight field represents the total weight of the shipment. In scenarios where the carrier does not provide this information, you can provide the weight to AfterShip. We will prioritize the data provided by the carrier, if available. The shipment weight will be included in the Response and accessed through the GET API, Webhook, and CSV export. It will also be displayed on the AfterShip Tracking admin. Additionally, it plays a significant role in error-free shipment handling and carbon emission calculations, ensuring accurate and informed decision-making
|
135
|
+
# shipment_weight?: ShipmentWeightTracking;
|
131
136
|
attr_accessor :shipment_weight
|
132
137
|
|
133
|
-
# Weight unit provied by carrier.
|
134
|
-
# shipment_weight_unit?: String;
|
135
|
-
attr_accessor :shipment_weight_unit
|
136
|
-
|
137
138
|
# Signed by information for delivered shipment.
|
138
139
|
# signed_by?: String;
|
139
140
|
attr_accessor :signed_by
|
140
141
|
|
141
|
-
# The phone number(s) to receive sms notifications. Phone number should begin with `+` and `Area Code` before phone number.
|
142
|
+
# The phone number(s) to receive sms notifications. Phone number should begin with `+` and `Area Code` before phone number.
|
142
143
|
# smses?: String[];
|
143
144
|
attr_accessor :smses
|
144
145
|
|
@@ -182,11 +183,11 @@ module AftershipAPI::Model
|
|
182
183
|
# checkpoints?: Checkpoint[];
|
183
184
|
attr_accessor :checkpoints
|
184
185
|
|
185
|
-
# Phone number(s) subscribed to receive sms notifications.
|
186
|
+
# Phone number(s) subscribed to receive sms notifications.
|
186
187
|
# subscribed_smses?: String[];
|
187
188
|
attr_accessor :subscribed_smses
|
188
189
|
|
189
|
-
# Email address(es) subscribed to receive email notifications.
|
190
|
+
# Email address(es) subscribed to receive email notifications.
|
190
191
|
# subscribed_emails?: String[];
|
191
192
|
attr_accessor :subscribed_emails
|
192
193
|
|
@@ -194,7 +195,7 @@ module AftershipAPI::Model
|
|
194
195
|
# return_to_sender?: Boolean;
|
195
196
|
attr_accessor :return_to_sender
|
196
197
|
|
197
|
-
# The promised delivery date of the order. It uses the
|
198
|
+
# The promised delivery date of the order. It uses the formats:- YYYY-MM-DD- YYYY-MM-DDTHH:mm:ss- YYYY-MM-DDTHH:mm:ssZ
|
198
199
|
# order_promised_delivery_date?: String;
|
199
200
|
attr_accessor :order_promised_delivery_date
|
200
201
|
|
@@ -314,6 +315,18 @@ module AftershipAPI::Model
|
|
314
315
|
# signature_requirement?: String;
|
315
316
|
attr_accessor :signature_requirement
|
316
317
|
|
318
|
+
# The delivery location type represents the secure area where the carrier leaves the package, such as a safe place, locker, mailbox, front porch, etc. This information helps ensure the shipment reaches the intended recipient efficiently, minimizing the risk of theft or damage.
|
319
|
+
# delivery_location_type?: String;
|
320
|
+
attr_accessor :delivery_location_type
|
321
|
+
|
322
|
+
# The tracking URL directs your customers to the shipment tracking page which can display either the default or a customized page based on segmentation rules.- The universal URL is used by default, but you can opt for a custom domain if you have one. Learn how to set up a custom domain .The field is not automatically enabled in API & Webhook. Please contact support if you’d like to enable it.
|
323
|
+
# aftership_tracking_url?: String;
|
324
|
+
attr_accessor :aftership_tracking_url
|
325
|
+
|
326
|
+
# The order URL directs your customers to the order tracking page, which includes all shipments. It can display either the default or a customized page based on segmentation rules.- The universal URL is used by default, but you can opt for a custom domain if you have one. Learn how to set up a custom domain .The field is not automatically enabled in API & Webhook. Please contact support if you’d like to enable it.
|
327
|
+
# aftership_tracking_order_url?: String;
|
328
|
+
attr_accessor :aftership_tracking_order_url
|
329
|
+
|
317
330
|
# Initializes the object
|
318
331
|
# @param [Hash] attributes Model attributes in the form of hash
|
319
332
|
def initialize(attributes = {})
|
@@ -329,6 +342,10 @@ module AftershipAPI::Model
|
|
329
342
|
self.id = attributes[:'id']
|
330
343
|
end
|
331
344
|
|
345
|
+
if attributes.key?(:'legacy_id')
|
346
|
+
self.legacy_id = attributes[:'legacy_id']
|
347
|
+
end
|
348
|
+
|
332
349
|
if attributes.key?(:'created_at')
|
333
350
|
self.created_at = attributes[:'created_at']
|
334
351
|
end
|
@@ -413,8 +430,8 @@ module AftershipAPI::Model
|
|
413
430
|
self.emails = attributes[:'emails']
|
414
431
|
end
|
415
432
|
|
416
|
-
if attributes.key?(:'
|
417
|
-
self.
|
433
|
+
if attributes.key?(:'courier_estimated_delivery_date')
|
434
|
+
self.courier_estimated_delivery_date = attributes[:'courier_estimated_delivery_date']
|
418
435
|
end
|
419
436
|
|
420
437
|
if attributes.key?(:'note')
|
@@ -453,10 +470,6 @@ module AftershipAPI::Model
|
|
453
470
|
self.shipment_weight = attributes[:'shipment_weight']
|
454
471
|
end
|
455
472
|
|
456
|
-
if attributes.key?(:'shipment_weight_unit')
|
457
|
-
self.shipment_weight_unit = attributes[:'shipment_weight_unit']
|
458
|
-
end
|
459
|
-
|
460
473
|
if attributes.key?(:'signed_by')
|
461
474
|
self.signed_by = attributes[:'signed_by']
|
462
475
|
end
|
@@ -636,12 +649,25 @@ module AftershipAPI::Model
|
|
636
649
|
if attributes.key?(:'signature_requirement')
|
637
650
|
self.signature_requirement = attributes[:'signature_requirement']
|
638
651
|
end
|
652
|
+
|
653
|
+
if attributes.key?(:'delivery_location_type')
|
654
|
+
self.delivery_location_type = attributes[:'delivery_location_type']
|
655
|
+
end
|
656
|
+
|
657
|
+
if attributes.key?(:'aftership_tracking_url')
|
658
|
+
self.aftership_tracking_url = attributes[:'aftership_tracking_url']
|
659
|
+
end
|
660
|
+
|
661
|
+
if attributes.key?(:'aftership_tracking_order_url')
|
662
|
+
self.aftership_tracking_order_url = attributes[:'aftership_tracking_order_url']
|
663
|
+
end
|
639
664
|
end
|
640
665
|
|
641
666
|
# Attribute type mapping.
|
642
667
|
def self.openapi_types
|
643
668
|
{
|
644
669
|
:'id' => :'String',
|
670
|
+
:'legacy_id' => :'String',
|
645
671
|
:'created_at' => :'String',
|
646
672
|
:'updated_at' => :'String',
|
647
673
|
:'last_updated_at' => :'String',
|
@@ -663,7 +689,7 @@ module AftershipAPI::Model
|
|
663
689
|
:'destination_raw_location' => :'String',
|
664
690
|
:'courier_destination_country_iso3' => :'String',
|
665
691
|
:'emails' => :'Array<String>',
|
666
|
-
:'
|
692
|
+
:'courier_estimated_delivery_date' => :'CourierEstimatedDeliveryDateTracking',
|
667
693
|
:'note' => :'String',
|
668
694
|
:'order_id' => :'String',
|
669
695
|
:'order_id_path' => :'String',
|
@@ -672,8 +698,7 @@ module AftershipAPI::Model
|
|
672
698
|
:'shipment_pickup_date' => :'String',
|
673
699
|
:'shipment_delivery_date' => :'String',
|
674
700
|
:'shipment_type' => :'String',
|
675
|
-
:'shipment_weight' => :'
|
676
|
-
:'shipment_weight_unit' => :'String',
|
701
|
+
:'shipment_weight' => :'ShipmentWeightTracking',
|
677
702
|
:'signed_by' => :'String',
|
678
703
|
:'smses' => :'Array<String>',
|
679
704
|
:'source' => :'String',
|
@@ -719,6 +744,9 @@ module AftershipAPI::Model
|
|
719
744
|
:'shipping_method' => :'String',
|
720
745
|
:'failed_delivery_attempts' => :'Integer',
|
721
746
|
:'signature_requirement' => :'String',
|
747
|
+
:'delivery_location_type' => :'String',
|
748
|
+
:'aftership_tracking_url' => :'String',
|
749
|
+
:'aftership_tracking_order_url' => :'String',
|
722
750
|
}
|
723
751
|
end
|
724
752
|
|
@@ -726,6 +754,7 @@ module AftershipAPI::Model
|
|
726
754
|
def self.attribute_map
|
727
755
|
{
|
728
756
|
:'id' => :'id',
|
757
|
+
:'legacy_id' => :'legacy_id',
|
729
758
|
:'created_at' => :'created_at',
|
730
759
|
:'updated_at' => :'updated_at',
|
731
760
|
:'last_updated_at' => :'last_updated_at',
|
@@ -747,7 +776,7 @@ module AftershipAPI::Model
|
|
747
776
|
:'destination_raw_location' => :'destination_raw_location',
|
748
777
|
:'courier_destination_country_iso3' => :'courier_destination_country_iso3',
|
749
778
|
:'emails' => :'emails',
|
750
|
-
:'
|
779
|
+
:'courier_estimated_delivery_date' => :'courier_estimated_delivery_date',
|
751
780
|
:'note' => :'note',
|
752
781
|
:'order_id' => :'order_id',
|
753
782
|
:'order_id_path' => :'order_id_path',
|
@@ -757,7 +786,6 @@ module AftershipAPI::Model
|
|
757
786
|
:'shipment_delivery_date' => :'shipment_delivery_date',
|
758
787
|
:'shipment_type' => :'shipment_type',
|
759
788
|
:'shipment_weight' => :'shipment_weight',
|
760
|
-
:'shipment_weight_unit' => :'shipment_weight_unit',
|
761
789
|
:'signed_by' => :'signed_by',
|
762
790
|
:'smses' => :'smses',
|
763
791
|
:'source' => :'source',
|
@@ -803,6 +831,9 @@ module AftershipAPI::Model
|
|
803
831
|
:'shipping_method' => :'shipping_method',
|
804
832
|
:'failed_delivery_attempts' => :'failed_delivery_attempts',
|
805
833
|
:'signature_requirement' => :'signature_requirement',
|
834
|
+
:'delivery_location_type' => :'delivery_location_type',
|
835
|
+
:'aftership_tracking_url' => :'aftership_tracking_url',
|
836
|
+
:'aftership_tracking_order_url' => :'aftership_tracking_order_url',
|
806
837
|
}
|
807
838
|
end
|
808
839
|
|
@@ -919,3 +950,4 @@ module AftershipAPI::Model
|
|
919
950
|
end
|
920
951
|
end
|
921
952
|
end
|
953
|
+
|
@@ -2,12 +2,13 @@
|
|
2
2
|
# Do not edit the class manually.
|
3
3
|
module AftershipAPI::Model
|
4
4
|
class TrackingResponseV1
|
5
|
+
|
5
6
|
# Meta data
|
6
7
|
# meta: MetaV1;
|
7
8
|
attr_accessor :meta
|
8
9
|
|
9
|
-
#
|
10
|
-
# data:
|
10
|
+
# Object describes the tracking information.<div style="display:none; height: 0"></div>
|
11
|
+
# data: Tracking;
|
11
12
|
attr_accessor :data
|
12
13
|
|
13
14
|
# Initializes the object
|
@@ -34,7 +35,7 @@ module AftershipAPI::Model
|
|
34
35
|
def self.openapi_types
|
35
36
|
{
|
36
37
|
:'meta' => :'MetaV1',
|
37
|
-
:'data' => :'
|
38
|
+
:'data' => :'Tracking',
|
38
39
|
}
|
39
40
|
end
|
40
41
|
|
@@ -159,3 +160,4 @@ module AftershipAPI::Model
|
|
159
160
|
end
|
160
161
|
end
|
161
162
|
end
|
163
|
+
|
@@ -1,7 +1,8 @@
|
|
1
1
|
# This code was auto generated by AfterShip SDK Generator.
|
2
2
|
# Do not edit the class manually.
|
3
3
|
module AftershipAPI::Model
|
4
|
-
class
|
4
|
+
class UpdateTrackingByIdRequest
|
5
|
+
|
5
6
|
# The phone number(s) to receive sms notifications. Input `[]` to clear the value of this field. Supports up to 3 phone numbers.
|
6
7
|
# smses?: String[];
|
7
8
|
attr_accessor :smses
|
@@ -38,7 +39,7 @@ module AftershipAPI::Model
|
|
38
39
|
# language?: String;
|
39
40
|
attr_accessor :language
|
40
41
|
|
41
|
-
# The promised delivery date of the order. It uses the
|
42
|
+
# The promised delivery date of the order. It uses the formats:- YYYY-MM-DD- YYYY-MM-DDTHH:mm:ss- YYYY-MM-DDTHH:mm:ssZ
|
42
43
|
# order_promised_delivery_date?: String;
|
43
44
|
attr_accessor :order_promised_delivery_date
|
44
45
|
|
@@ -150,7 +151,7 @@ module AftershipAPI::Model
|
|
150
151
|
# @param [Hash] attributes Model attributes in the form of hash
|
151
152
|
def initialize(attributes = {})
|
152
153
|
if (!attributes.is_a?(Hash))
|
153
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `AftershipAPI::
|
154
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `AftershipAPI::UpdateTrackingByIdRequest` initialize method"
|
154
155
|
end
|
155
156
|
|
156
157
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
@@ -499,3 +500,4 @@ module AftershipAPI::Model
|
|
499
500
|
end
|
500
501
|
end
|
501
502
|
end
|
503
|
+
|