[1.23.0] SMART service handling



Warning!

Resource is available only in the following countries: PL

Adding the option of sending Allegro SMART services during inpost_locker_allegro_smart shipment creation.



Structure

Shipment resource for Allegro SMART has the same attributes as Shipment simplified mode. The only difference is in cod parameter:

Parameter

Type

Description

Validation

Availability

Parameter

Type

Description

Validation

Availability

cod

Cod

Cash collection amount.

The attribute is not required.

PL


 

Authentication

Resource access requires an active access token.


 

Allegro parcels before

Allegro parcels no longer require custom_attributes to include allegro_transaction_id and allegro_user_id, sending a full masked allegro email is sufficient. The e-mail will have the following structure permanentsendercode+transactionidenntifier@allegromail.com, example: 8awgqyk6a5+cub31c122@allegromail.com.


 

Creating Allegro SMART shipments

 SMART shipments can be created only for emails within the allegro domain:

In case of the given email reaching the SMART limit, the service will be automatically changed to the equivalent service without _smart.

In case an allegro domain email and service inpost_locker_allegro, when the email has an available SMART limit, service will automatically change to the equivalent _smart  service.



Beneath, you can see which services should be used for each delivery option:

 

Delivery Option - Allegro Paczkomat® 24/7 InPost:

  • with Allegro Smart  -  use inpost_locker_allegro

  • without Allegro Smart  -  use inpost_locker_allegro (service will be changed to inpost_locker_allegro_smart if the email has available SMART limit)



Attention! Wrong service for the delivery method

In case the wrong service is specified for the delivery method (e.g. inpost_locker_standard service for Allegro Paczkomat® 24/7), SMART will not be available.

 

Examples of inquiries are available at https://dokumentacja-inpost.atlassian.net/wiki/spaces/PL/pages/28639258 .

 

Sample request to create a package for Allegro Paczkomat® 24/7 InPost delivery method:

POST /v1/organizations/123/shipments HTTP/1.1 Host: api-shipx-pl.easypack24.net Content-Type: application/json Authorization: Bearer lkfjasd9f70y43ohriw...[ommited for brevity]... { "comments": "dowolny komentarz", "receiver": { "first_name": "Jan", "last_name": "Kowalski", "name": "Nazwa", "email": "jinfq3pjv+4c5547c60@user.allegrogroup.pl", "phone": "888000000", "address": { "id": "123", "street": "Malborska", "building_number": "130", "city": "Kraków", "post_code": "30-624", "country_code": "PL" } }, "parcels": [ { "template": "medium" } ], "custom_attributes": { "target_point": "BBI01A" }, "service": "inpost_locker_allegro" }

Response

HTTP/1.1 201 CREATED Content-Type: application/json { "href": "https://api-shipx-pl.easypack24.net/v1/organizations/1/shipments/1234567890", "id": "1234567890", "status": "created", "tracking_number": null, "service": "inpost_locker_allegro_smart", "reference": null, "is_return": false, "application_id": 1, "created_by_id": null, "external_customer_id": null, "sending_method": null, "mpk": null, "comments": "dowolny komentarz", "additional_services": [], "custom_attributes": { "target_point": "BBI01A" }, "cod": { "amount": null, "currency": null }, "insurance": { "amount": null, "currency": null }, "sender": { "id": 2860, "name": null, "company_name": "Inittec Sp. z o.o. (API Tests)", "first_name": "Robert", "last_name": "Dzikowski", "email": "rdzikowski@grupainteger.pl", "phone": "121323123", "address": { "id": 2824, "street": "Zawiła", "building_number": "65 L", "line1": null, "line2": null, "city": "Kraków", "post_code": "30-390", "country_code": "PL" } }, "receiver": { "id": 2859, "name": "Nazwa", "company_name": null, "first_name": "Jan", "last_name": "Kowalski", "email": "jinfq3pjv+4c5547c60@user.allegrogroup.pl", "phone": "888000000", "address": { "id": 2823, "street": "Malborska", "building_number": "130", "line1": null, "line2": null, "city": "Kraków", "post_code": "30-624", "country_code": "PL" } }, "selected_offer": null, "offers": [], "transactions": [], "parcels": [ { "id": 1494, "tracking_number": null, "is_non_standard": false, "template": "medium", "dimensions": { "length": 380.0, "width": 640.0, "height": 190.0, "unit": "mm" }, "weight": { "amount": 25.0, "unit": "kg" } } ] }