Intermittent Invalid Login Credentials using API

Hello, hoping someone can help.

I am using the QuickFile API v1.2, with a NodeJS application.

It works OK the majority of the time, but on occasion, it returns an error with the value: ‘Invalid Login Credentials’?

I know that the MD5 is generating fine, because it works one minute, and not the next?

What is happening here? Is the API limited to a number of requests per minute (or similar)?

Hi @dcockburn

There are no time limits in that respect, only a daily limit (default 1,000 per day).

Do you have any examples of requests that have failed, and their responses? You’re welcome to send it to @QFSupport in a private message if they contain sensitive data (including your credentials).

{statusCode: 400, body: {…}, headers: {…}, request: {…}}statusCode: 400body: Errors: Error: Array(1)0: "Invalid login credentials"length: 1__proto__: Array(0)proto: Object__proto__: Objectheaders: {date: “Fri, 13 Mar 2020 17:12:01 GMT”, content-type: “application/json; charset=utf-8”, content-length: “50”, connection: “close”, set-cookie: Array(1), …}request: uri: {protocol: “https:”, slashes: true, auth: null, host: “api.quickfile.co.uk”, port: 443, …}method: "POST"headers: {accept: “application/json”, content-type: “application/json”, content-length: 407}proto: Object__proto__: Object

the previous request sent moments earlier with the same code returned:

{statusCode: 200, body: {…}, headers: {…}, request: {…}}statusCode: 200body: {Report_ChartOfAccounts: {…}}headers: {date: “Fri, 13 Mar 2020 17:12:01 GMT”, content-type: “application/json; charset=utf-8”, content-length: “195”, connection: “close”, set-cookie: Array(1), …}request: {uri: {…}, method: “POST”, headers: {…}}proto: Object

@QFMatthew any idea what could be causing this?

@dcockburn - I’ve replied to your private message.

This has been resolved. My submission ID was being generated using the current Date in milliseconds, appended with a random 4 digit number following a decimal point. It would appear that the API doesn’t like the decimal. I have amended my code to remove the decimal point and the issue is resolved. Thank you to QF for the quick support!

1 Like

This topic was automatically closed after 7 days. New replies are no longer allowed.