I'm trying to use the new Teltonika API which is working perfectly for everything other than a file download :)
When I try and download a file I call the URL in format:
https://api.teltonika.lt/files/download/xxxxxx (id from files list API response)
I pass the Authorization header with Bearer xxxxxx as per other requests but get a response of:
400 Bad request:
<?xml version="1.0" encoding="UTF-8"?> <Error><Code>InvalidArgument</Code><Message>Only one auth mechanism allowed; only the X-Amz-Algorithm query parameter, Signature query string parameter or the Authorization header should be specified</Message><ArgumentName>Authorization</ArgumentName><ArgumentValue>Bearer 397|Gvjfls7ZoFNrJ0pukGI9PnzXMtdF2rmQTN5cgoh4</ArgumentValue><RequestId>2A6E2BD062DC0C1A</RequestId><HostId>BUga1xx0OSCcIeE5ZLeRQuqMjhYFoSyey0YsFx+etnzUcT9d7PwvVgNtN0MCVlMrycyjTeLow2Y=</HostId></Error>
I've tried adding the other Headers as shown in the documenation and also
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Encoding: gzip, deflate, br
Which I noticed are passed on requests from fm.teltonika.lt interface but with the same outcome.
Any pointers would be greatly appreciated!