Skip to content

Commit 399f881

Browse files
authored
Merge pull request #25 from 1415003719/2025-07
upgrade dependences
2 parents 2120f93 + 1f933b6 commit 399f881

File tree

7 files changed

+354
-302
lines changed

7 files changed

+354
-302
lines changed

README.md

Lines changed: 83 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ If you need support using AfterShip products, please contact support@aftership.c
2020
- [Error Handling](#error-handling)
2121
- [Error List](#error-list)
2222
- [Endpoints](#endpoints)
23-
- [/courier-connections](#courier-connections)
24-
- [/estimated-delivery-date](#estimated-delivery-date)
2523
- [/trackings](#trackings)
2624
- [/couriers](#couriers)
25+
- [/courier-connections](#courier-connections)
26+
- [/estimated-delivery-date](#estimated-delivery-date)
2727
- [Help](#help)
2828
- [License](#license)
2929

@@ -145,15 +145,6 @@ The SDK will return an error object when there is any error during the request,
145145

146146
The AfterShip instance has the following properties which are exactly the same as the API endpoints:
147147

148-
- courier_connection
149-
- Get courier connections
150-
- Create courier connections
151-
- Get courier connection by id
152-
- Update courier connection by id
153-
- Delete courier connection by id
154-
- estimated_delivery_date
155-
- Prediction for the Estimated Delivery Date
156-
- Batch prediction for the Estimated Delivery Date
157148
- tracking
158149
- Get trackings
159150
- Create a tracking
@@ -165,238 +156,247 @@ The AfterShip instance has the following properties which are exactly the same a
165156
- courier
166157
- Get couriers
167158
- Detect courier
159+
- courier_connection
160+
- Get courier connections
161+
- Create courier connections
162+
- Get courier connection by id
163+
- Update courier connection by id
164+
- Delete courier connection by id
165+
- estimated_delivery_date
166+
- Prediction for the Estimated Delivery Date
167+
- Batch prediction for the Estimated Delivery Date
168168

169-
### /courier-connections
170-
**GET** /courier-connections
169+
### /trackings
170+
**GET** /trackings
171171

172172
```python
173173

174-
result = sdk.courier_connection.get_courier_connections(
174+
result = sdk.tracking.get_trackings(
175175

176176

177177

178178
)
179179
print(result)
180180
```
181181

182-
**POST** /courier-connections
182+
**POST** /trackings
183183

184184
```python
185-
req = tracking.PostCourierConnectionsRequest()
186-
187-
188-
req.courier_slug = 'valid_value'
185+
req = tracking.CreateTrackingRequest()
189186

190187

191-
req.credentials = {}
188+
req.tracking_number = 'valid_value'
192189

193190

194-
result = sdk.courier_connection.post_courier_connections(
191+
result = sdk.tracking.create_tracking(
195192

196193
req,
197194

198195
)
199196
print(result)
200197
```
201198

202-
**GET** /courier-connections/{id}
199+
**GET** /trackings/{id}
203200

204201
```python
205202

206-
result = sdk.courier_connection.get_courier_connections_by_id(
203+
result = sdk.tracking.get_tracking_by_id(
207204
'valid_value',
208205

209206

210207
)
211208
print(result)
212209
```
213210

214-
**PATCH** /courier-connections/{id}
211+
**PUT** /trackings/{id}
215212

216213
```python
217-
req = tracking.PutCourierConnectionsByIdRequest()
218-
219-
220-
req.credentials = {}
214+
req = tracking.UpdateTrackingByIdRequest()
221215

222216

223-
result = sdk.courier_connection.put_courier_connections_by_id(
217+
result = sdk.tracking.update_tracking_by_id(
224218
'valid_value',
225219
req,
226220

227221
)
228222
print(result)
229223
```
230224

231-
**DELETE** /courier-connections/{id}
225+
**DELETE** /trackings/{id}
232226

233227
```python
234228

235-
result = sdk.courier_connection.delete_courier_connections_by_id(
229+
result = sdk.tracking.delete_tracking_by_id(
236230
'valid_value',
237231

238232

239233
)
240234
print(result)
241235
```
242236

243-
### /estimated-delivery-date
244-
**POST** /estimated-delivery-date/predict
237+
**POST** /trackings/{id}/retrack
245238

246239
```python
247-
req = tracking.EstimatedDeliveryDateRequest()
248-
249-
250-
req.slug = 'valid_value'
251240

252-
253-
req.origin_address = tracking.EstimatedDeliveryDateRequestOriginAddress()
254-
255-
256-
req.destination_address = tracking.EstimatedDeliveryDateRequestDestinationAddress()
257-
258-
259-
result = sdk.estimated_delivery_date.predict(
241+
result = sdk.tracking.retrack_tracking_by_id(
242+
'valid_value',
260243

261-
req,
262244

263245
)
264246
print(result)
265247
```
266248

267-
**POST** /estimated-delivery-date/predict-batch
249+
**POST** /trackings/{id}/mark-as-completed
268250

269251
```python
270-
req = tracking.PredictBatchRequest()
252+
req = tracking.MarkTrackingCompletedByIdRequest()
271253

272254

273255

274-
result = sdk.estimated_delivery_date.predict_batch(
275-
256+
result = sdk.tracking.mark_tracking_completed_by_id(
257+
'valid_value',
276258
req,
277259

278260
)
279261
print(result)
280262
```
281263

282-
### /trackings
283-
**GET** /trackings
264+
### /couriers
265+
**GET** /couriers
284266

285267
```python
286268

287-
result = sdk.tracking.get_trackings(
269+
result = sdk.courier.get_couriers(
288270

289271

290272

291273
)
292274
print(result)
293275
```
294276

295-
**POST** /trackings
277+
**POST** /couriers/detect
296278

297279
```python
298-
req = tracking.CreateTrackingRequest()
280+
req = tracking.DetectCourierRequest()
299281

300282

301283
req.tracking_number = 'valid_value'
302284

303285

304-
result = sdk.tracking.create_tracking(
286+
result = sdk.courier.detect_courier(
305287

306288
req,
307289

308290
)
309291
print(result)
310292
```
311293

312-
**GET** /trackings/{id}
294+
### /courier-connections
295+
**GET** /courier-connections
313296

314297
```python
315298

316-
result = sdk.tracking.get_tracking_by_id(
317-
'valid_value',
299+
result = sdk.courier_connection.get_courier_connections(
300+
318301

319302

320303
)
321304
print(result)
322305
```
323306

324-
**PUT** /trackings/{id}
307+
**POST** /courier-connections
325308

326309
```python
327-
req = tracking.UpdateTrackingByIdRequest()
310+
req = tracking.PostCourierConnectionsRequest()
328311

329312

330-
result = sdk.tracking.update_tracking_by_id(
331-
'valid_value',
313+
req.courier_slug = 'valid_value'
314+
315+
316+
req.credentials = {}
317+
318+
319+
result = sdk.courier_connection.post_courier_connections(
320+
332321
req,
333322

334323
)
335324
print(result)
336325
```
337326

338-
**DELETE** /trackings/{id}
327+
**GET** /courier-connections/{id}
339328

340329
```python
341330

342-
result = sdk.tracking.delete_tracking_by_id(
331+
result = sdk.courier_connection.get_courier_connections_by_id(
343332
'valid_value',
344333

345334

346335
)
347336
print(result)
348337
```
349338

350-
**POST** /trackings/{id}/retrack
339+
**PATCH** /courier-connections/{id}
351340

352341
```python
342+
req = tracking.PutCourierConnectionsByIdRequest()
353343

354-
result = sdk.tracking.retrack_tracking_by_id(
344+
345+
req.credentials = {}
346+
347+
348+
result = sdk.courier_connection.put_courier_connections_by_id(
355349
'valid_value',
356-
350+
req,
357351

358352
)
359353
print(result)
360354
```
361355

362-
**POST** /trackings/{id}/mark-as-completed
356+
**DELETE** /courier-connections/{id}
363357

364358
```python
365-
req = tracking.MarkTrackingCompletedByIdRequest()
366-
367359

368-
369-
result = sdk.tracking.mark_tracking_completed_by_id(
360+
result = sdk.courier_connection.delete_courier_connections_by_id(
370361
'valid_value',
371-
req,
362+
372363

373364
)
374365
print(result)
375366
```
376367

377-
### /couriers
378-
**GET** /couriers
368+
### /estimated-delivery-date
369+
**POST** /estimated-delivery-date/predict
379370

380371
```python
372+
req = tracking.EstimatedDeliveryDateRequest()
381373

382-
result = sdk.courier.get_couriers(
383-
374+
375+
req.slug = 'valid_value'
376+
377+
378+
req.origin_address = tracking.EstimatedDeliveryDateRequestOriginAddress()
379+
380+
381+
req.destination_address = tracking.EstimatedDeliveryDateRequestDestinationAddress()
382+
383+
384+
result = sdk.estimated_delivery_date.predict(
384385

386+
req,
385387

386388
)
387389
print(result)
388390
```
389391

390-
**POST** /couriers/detect
392+
**POST** /estimated-delivery-date/predict-batch
391393

392394
```python
393-
req = tracking.DetectCourierRequest()
394-
395+
req = tracking.PredictBatchRequest()
395396

396-
req.tracking_number = 'valid_value'
397397

398398

399-
result = sdk.courier.detect_courier(
399+
result = sdk.estimated_delivery_date.predict_batch(
400400

401401
req,
402402

0 commit comments

Comments
 (0)