![]() |
AW: DHL-API mit RESTClient
One more thing, i don't have TRESTClient, so may be someone here can help or suggest how to add HTTP header.
|
AW: DHL-API mit RESTClient
Hi Kas,
thanks for support. At first: Yes I changed the API-Key and I used the provided Key from DHL. Only for the Forum I changed it to xxXXXxxXXXXXxxXX. I tried it on the DHL-Page, but also there I get the same result:
Code:
I wrote an ticket to the support. Maybe the problem is not on my site...
{
"status": 401, "title": "Unauthorized", "detail": "Unauthorized for given resource." } |
AW: DHL-API mit RESTClient
Perhaps the rate limit kicks in, if all failed attemps will be counted too?
Maybe tomorrow is another day :-D |
AW: DHL-API mit RESTClient
Zitat:
|
AW: DHL-API mit RESTClient
Wenn alle Stricke reißen, gäbe es noch Drittanbieter. Wir haben Sendcloud in unserer Delphi-Anwendung integriert, weil die in jedem Tarif eigene Verträge und API können. Kostet natürlich Geld. Bei DPD haben sie öfter Probleme mit Verfügbarkeit, aber andere Versanddienstleister funktionieren zuverlässiger.
|
AW: DHL-API mit RESTClient
The rate limit can not be the problem, because it never worked. And it should work by 50 times per day, so that I am sure, that the rate is not the reason...
A third part solution is not a alternative for us, because there are to much parcel per day, that the costs are to high. I hope that it can be fixed, because it is only the first step. The next one should be the creation of shipment labels... Patrick |
AW: DHL-API mit RESTClient
Funfact: Ich hatte aus Spaß versucht die OpenAI-Schnittstelle mit Delphi per TRestClient-Komponenten anzusprechen.
Das geht in der alten Delphi-Version die ich zu Hause habe (10.?) nicht. Ich musste die THTTPClient-Komponenten benutzen. Da hatte ich mir auch die Karten gelegt. Liebe Grüße Incocncito |
AW: DHL-API mit RESTClient
Zitat:
Code:
(Das ist unter Linux.)
curl -X GET 'https://api-eu.dhl.com/track/shipments?trackingNumber=00341434296527125347' -H 'DHL-API-Key:xxXXXxxXXXXXxxXX'
{"status":401,"title":"Unauthorized","detail":"Unauthorized for given resource."} |
AW: DHL-API mit RESTClient
Sollten bei Curls unter Windows nicht Double-Quotes verwendet werden?
Code:
curl -X GET "https://api-eu.dhl.com/track/shipments?trackingNumber=00341434296527125347" -H "DHL-API-Key:xxXXXxxXXXXXxxXX"
|
AW: DHL-API mit RESTClient
Zitat:
Code:
Bei Double-Quotes wird es korrekt ausgeführt. Wenn man gar keine Quotes verwendet wird es auch korrekt ausgeführt.
curl: (3) URL rejected: Port number was not a decimal number between 0 and 65535
Wobei korrekt ausgeführt bedeutet:
Code:
{"status":401,"title":"Unauthorized","detail":"Unauthorized for given resource."}
|
Alle Zeitangaben in WEZ +1. Es ist jetzt 22:10 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz