Supplied date format for parameter from is wrong

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
    9.9 LTS
  • what are you trying to achieve
    I want to automate the logs and I cannot pull out the api/audit_logs/download?from=2023-06-07T00:00:00+02:00&to=2023-06-07T00:00:00+02:00 as it says that the time is not correct. Tried already to google and other examples, but I don’t get what is the correct method of sending this to the API? Much appreciated in advance.

The Web API / error message need to be improved. I’ll flag this for attention.

In the meantime, try working off of this format:

http://localhost:9000/api/audit_logs/download?from=2023-06-07T02:00:00.000Z&to=2023-06-07T02:00:00.000Z

1 Like

Hi @anon35261157,

The date format that you are using should be working. You get this error message because the “+” character means “whitespace” in URLs. If you want to be able to pass a “+” characters, you need to encode it with “%2b”.

HTH,

1 Like

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