Error handling
400, Bearer token malformed - Check that you have a slash at the end of the URL
404, page not found - requesting a wrong path
405, Method Not Allowed - request path or method isn’t correct
403, Key not authorized - invalid access key
403, Key has expired, please renew - you need to request a new access key
403, Invalid request, The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed - the encoded key used to request an access token isn’t ok, need to make sure you create it correctly
500, GENERAL_ERROR, the request to external server didn't work correctly - check that your request is built correctly. If this persists, contact support
Please note that if the API requests passed correctly you might still have problems with the file you tried to upload using the feed API. The error should be shown in the status request and in the results file.
If the encountered issue is not covered, please contact - support@feedvisor.com
Best coding practices
The exported file, whether CSV or XLSX, contains columns with headers specifying which field it contains, and rows for each entity.
As our product evolves, we might add new columns to the file. That is why you should not depend on the index of a specific column, as it may change with the addition of new columns.
You should read the first line that contains the list of column headers, and according to that, take or edit the columns you need.
Sample code
https://github.com/feedvisor/api-sample
First, you need to make sure that your client credentials are set in the constants that are at the top of AuthenticationExample class, then you can run the main function in the same class
or after running install in maven, run:
java -jar target/external-example-1.0-SNAPSHOT-jar-with-dependencies.jar
|
Installation
After making sure that your client credentials are set in the constants that are at the top of AuthenticationExample class, run:
mvn clean install
|
Comments
0 comments
Please sign in to leave a comment.