How do I use curl to execute an Invantive Cloud OData4 request?

Go to Dutch version

Some issues are specifically tied to Power BI Desktop, Excel or powerbi.com. Therefore, you may be asked to perform a download also via the program curl.

Curl comes standard with Microsoft Windows PCs and MacOS. This topic explains how to reproduce a download using curl.

Preparations

The first step is to retrieve the hyperlink of the download you want to reproduce in Bridge Online Monitoring. First, search the list for the request in question for you; usually this is a request with a select statement in the ‘SQL statement’ column.

Click anywhere on the request to open Bridge Online’s Monitoring Details screen.

Then right-click and copy the hyperlink from the Path to the clipboard:

Invoke curl

The steps for curl are almost identical for MacOS and Windows.

Perform the following steps to replay the download using curl:

  • Under Windows: start the command prompt
  • Under MacOS: start the terminal
  • Enter:
curl --output tijdelijk.json --user <CLOUD_USER_ACCOUNT>:<CLOUD_PASSWORD> <URL>

where you replace as follows:

  • <CLOUD_USER_ACCOUNT>: the email address you use to log in to Invantive Cloud or Bridge Online to retrieve the data.
  • <CLOUD_PASSWORD>: the password you use to log in.
  • <URL>: the hyperlink you put on the clipboard in the previous step.
  • Note MacOS: put single quotes (') before and after the hyperlink to avoid, for example, the dollar sign ($) being interpreted as a reference to an environment variable.

Execute the statement:

curl --output temporary.json --user john.doe@acme.eu:secret --url https://bridge-online.invantive.com/acme-dummy/odata4/Dummy.Demo.Invoices@dmy
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  7930    0  7930    0     0  76494      0 --:--:-- --:--:-- --:--:-- 77745

Within Bridge Online Monitoring, you can then see the request:

Under the ‘Phases’ tab, you will see the different sequential steps:

The data exchange between curl and Invantive Bridge Online, and between Invantive Bridge Online and the underlying platform, can be found within the Session I/Os screen on Invantive Cloud for all requests since 0:00 UTC.