Closed HannesMorre closed 1 month ago
This issue is solved, the mouser cart is working, but we have an issue with digikey now.
{"ErrorCode" : "invalid_request", "Error" :"Invalid redirection uri https://{url}/plugin/suppliercart/digikeytoken/"}
This probably happens because our inventree instance is not accessible from outside our organization? How can we solve this?
Hi, Did you set the base URL in the InvenTree settings?
Hi, yes the base url is set in the InvenTree settings The previous error was on our staging environment of inventree where we test new updates and plugins. Now I am trying on our production environment and I get the same error when I try to request a token
Update: Now it works, but I get redirected to our inventree home page and the tokens are not set for Digikey
Update: I made it work now, all default plugin settings were disabled
Good to hear that it works in your environment.
Just a question about part creation, is it possible to create parts with this plugin like kintree does?
No. We create parts manually using some kind of review process. It is not done that often. So automation is not required in our case. The plugin can create supplierparts for existing parts if you know the exact SKU of the supplier.
yes, the supplier part creation is very convenient Thanks for the extra info.
@SergeoLacruz just after my last comment I am trying to add supplier parts from digikey but unfortunately this is not working properly. For mouser parts there is no problem, but i cannot add digikey supplierparts.
Is the token created and valid? Does the Digikey shopping cart transfer work? The logs show a green message each time the token is checked and a red one when the token is invalid. Any error message in the message bar?
How can I check if the token is valid? It is created, so should be valid I guess. Shopping cart transfer works. No logs when trying to create supplier part. No error messages either.
If the shopping cart transfer to Digikey works, the token is valid. You should see in the log
https://api.digikey.com:443 "POST /v1/oauth2/token HTTP/1.1" 200 273
Token refresh SUCCESS
This shows get_digikey_partdata has been called. You should further see
Remaining requests:
This tells you how many requests Digikey still allows you for the actual time period The message header should be blue and show 200. This is the response status code. If the status code is not 200 the bar is red and shows an error message e.g. Part not found at Digikey.
Hi @SergeoLacruz I just tried again to add a supplier part, but now I get this error:
What can be done to fix this?
This is a message caused by Digikey. Please supply the log for that request. Where are you located? Which currency did you set?
And where exactly can I find these logs? Today I got a different error code btw:
I am located in Belgium and the currency of inventree is set to Euro
The InvenTree server creates logs. The second message is obvious, your Client ID is invalid.
It is weird that the Client ID is invalid since it does work to transfer the cart and create a token. I asked my colleague for the logs
I tried to reproduce this again to generate new logs and this is what i get:
Try a page reload.
How can we fix the invalid Client ID problem?
When i create a mouser purchase order in inventree I get this error, but have no idea how to solve this.