allegro / allegro-api

Issue tracker and wiki for Allegro REST API
https://developer.allegro.pl/
213 stars 39 forks source link

Niepełne informacje przy zwracaniu punktów Ruch #4108

Closed artmarus closed 3 years ago

artmarus commented 3 years ago

Występuje problem:

:beetle: Opis

curl --request GET \ --url 'https://api.allegro.pl.allegrosandbox.pl/order/checkout-forms?limit=10&offset=0' \ --header 'Accept: application/vnd.allegro.public.v1+json'

{ "checkoutForms": [ { "id": "ba0b8c41-5a4e-11eb-964b-ab606daf83d9", "messageToSeller": null, "buyer": { "id": "93964519", "email": "s6tz6c2ums+5de15f915@user.allegrogroup.pl", "login": "!g_93964519", "firstName": "Adrian", "lastName": "Test", "companyName": null, "guest": true, "personalIdentity": null, "phoneNumber": "+48 666 777 888", "address": { "street": "Testowa", "city": "Wrocław", "postCode": "51-619", "countryCode": "PL" } }, "payment": { "id": "9eee0f91-5a4f-11eb-b927-a74bc036b093", "type": "ONLINE", "provider": "PAYU", "finishedAt": "2021-01-19T12:13:55.778Z", "paidAmount": { "amount": "105.00", "currency": "PLN" } }, "status": "READY_FOR_PROCESSING", "fulfillment": { "status": "NEW", "shipmentSummary": { "lineItemsSent": "NONE" } }, "delivery": { "address": { "firstName": "Adrian", "lastName": "Test", "street": "Testowa", "city": "Wrocław", "zipCode": "51-619", "countryCode": "PL", "companyName": null, "phoneNumber": "+48 666 777 888", "modifiedAt": null }, "method": { "id": "b715fac1-8ec2-4f5c-8fdf-0f9cec9085ad", "name": "Paczka w RUCHu" }, "pickupPoint": { "id": "963926", "name": "PACZKA w RUCHu: SZ-963926-18-01", "description": null, "address": { "street": "Targowa 23", "zipCode": "74-110", "city": "Banie" }, "modifiedAt": null }, "cost": { "amount": "5.00", "currency": "PLN" }, "smart": false, "time": { "guaranteed": null }, "calculatedNumberOfPackages": 1 }, "invoice": { "required": false, "address": null }, "lineItems": [ { "id": "ba0b6530-5a4e-11eb-964b-ab606daf83d9", "offer": { "id": "6931296755", "name": "Czajnik Alladyna", "external": null }, "quantity": 1, "originalPrice": { "amount": "100.00", "currency": "PLN" }, "price": { "amount": "100.00", "currency": "PLN" }, "selectedAdditionalServices": [], "boughtAt": "2021-01-19T12:13:44.409Z" } ], "surcharges": [], "discounts": [], "summary": { "totalToPay": { "amount": "105.00", "currency": "PLN" } }, "updatedAt": "2021-01-19T12:13:55.778Z", "revision": "bd4d65cd" }, { "id": "5d119b11-1d31-11eb-b8bc-7d00fc7e4b1d", "messageToSeller": "proszę o coś tam\nenter\nenter \nenter", "buyer": { "id": "44207128", "email": "om76ecmfph+4fe438770@user.allegrogroup.pl", "login": "abc_bolek", "firstName": "mmm", "lastName": "jjj", "companyName": null, "guest": false, "personalIdentity": null, "phoneNumber": "+48 12 111 11 11", "address": { "street": "polna 4", "city": "Trzebnica", "postCode": "55-100", "countryCode": "PL" } }, "payment": { "id": "5e7faa00-1d31-11eb-8194-65c427019685", "type": "ONLINE", "provider": "PAYU", "finishedAt": "2020-11-02T17:33:21.958Z", "paidAmount": { "amount": "2.00", "currency": "PLN" } }, "status": "READY_FOR_PROCESSING", "fulfillment": { "status": "NEW", "shipmentSummary": { "lineItemsSent": "NONE" } }, "delivery": { "address": { "firstName": "mmm", "lastName": "jjj", "street": "polna 4", "city": "Trzebnica", "zipCode": "55-100", "countryCode": "PL", "companyName": null, "phoneNumber": "+48 121 111 111", "modifiedAt": null }, "method": { "id": "b4525da7-fe10-4e89-af86-70479d3f251e", "name": "Kurier UPS" }, "pickupPoint": null, "cost": { "amount": "1.00", "currency": "PLN" }, "smart": false, "time": { "guaranteed": null }, "calculatedNumberOfPackages": 1 }, "invoice": { "required": false, "address": null }, "lineItems": [ { "id": "5d117400-1d31-11eb-b8bc-7d00fc7e4b1d", "offer": { "id": "7678487520", "name": "Sundries Metaliczny szklany słoik", "external": { "id": "1qa" } }, "quantity": 1, "originalPrice": { "amount": "1.00", "currency": "PLN" }, "price": { "amount": "1.00", "currency": "PLN" }, "selectedAdditionalServices": [], "boughtAt": "2020-11-02T17:33:10.012Z" } ], "surcharges": [], "discounts": [], "summary": { "totalToPay": { "amount": "2.00", "currency": "PLN" } }, "updatedAt": "2020-11-02T17:33:21.958Z", "revision": "bd4d65cd" } ]

Zauważyliśmy, że endpoint '/order/checkout-forms' dla pola "pickupPoint":"id" i przewoźnika 'Ruch' zwraca niepełne dane. Przykładowo: Gdy klient po stronie Allegro wybierze metodę dostawy Paczka w RUCHu (b715fac1-8ec2-4f5c-8fdf-0f9cec9085ad) oraz punkt odbioru 'SZ-963926-18-01', to w odpowiedzi z '/order/checkout-forms' w polu id dostaniemy '963926'. Pełne informacje znajdują się natomiast w polu 'name', niemniej są one w mało przystępnej i użytecznej formie, tj. razem z dodatkowym ciągiem znaków: 'PACZKA w RUCHu: SZ-963926-18-01'. Czy jest to celowe zachowanie? Jeśli nie, to możemy liczyć na rozwiązanie tego problemu?

AureliuszBrussy commented 3 years ago

Konsultuję Twoje zgłoszenie z odpowiednim zespołem. Wrócę do Ciebie z odpowiedzią.

Radeq commented 3 years ago

@AureliuszBrussy , czy udało się coś ustalić? Potwierdzam spostrzeżenie @artmarus - API Ruch oczekuje podanie pełnego numeru np. SZ-963926-18-01 który jest zwracany jako część name a nie w id.

AureliuszBrussy commented 3 years ago

@Radeq zweryfikowaliśmy to i naszych ustaleń wynika, że publiczne API RUCHu wspiera i rozpoznaje również identyfikatory o skróconej formie.

stale[bot] commented 3 years ago

W tym wątku nie pojawiła się żadna nowa odpowiedź w ciągu 30 dni. Dlatego automatycznie oznaczamy go jako przeterminowany. Jeśli w ciągu 7 dni nie pojawi się żadna odpowiedź, zamkniemy ten wątek. Dziękujemy za zaangażowanie w dyskusję.