As most people know, the majority of data correction and tests are done from spreadsheets. So Binubuo API can help you to quickly and easily import test data directly from the API into your favorite spreadsheet application.
For this demo, we will create 40 rows of data, simulating purchases of mutual funds. We will use these generators:
We will get the output in CSV to it will be easy to import directly into the spreadsheet. We can use the GET /data/custom/quick_fetch Binubuo endpoint to fetch the data:
The first thing we need to do in Google sheets is install the API Connector add-on. To do this go to the Add-ons menu -> Get add-ons. The search for API Connector and click install. Once the add-on is installed we can create a new sheet and click the Add-ons menu and then open API Connector plugin.
Once the plugin is installed, we can create a new spreadsheet. Go to the API Connector menu (Addons->API Connector) and click Open. Once open in the spreadsheet we can fill in the information that we need to import data from the API. First we put in the URL in the “API URL Path” field. Then we need to add the 2 RapidAPI headers. First the “x-rapidapi-host” which should be set to “binubuo.p.rapidapi.com” and then the “x-rapidapi-key” where the value is your individual API key.
To import data into an Excel spreadsheet, we will use the Data feature. Click the “Data” ribbon or menu, and choose “From Web”. When the dialog opens, click the “Advanced” radio button. Paste the URL above into the first field of the “URL parts”. After that, add the 2 headers required from RapidAPI. First add the “x-rapidapi-host” which should be set to “binubuo.p.rapidapi.com” and then the “x-rapidapi-key” where the value is your individual API key. Excel will then show a preview of the data, at which you click the “Load” button, and then your data is loaded in a new spreadsheet.
Setting up the Binubuo API call:
Previewing the data:
Loading the data to the spreadsheet: