Excellion service that lets you manipulate Excel files via REST APIs.
It is a tool designed for developers where you can upload, write and read excel files on the fly.
There is only one API endpoint which is /api/changeset
and it accepts the format form-data
(as you can see in the example below).
If you get a 401 double-check the existence of all the cell numbers and sheet names.
On a very high level this is what happens when you make a call:
Download this Excel file (does nothing but the sum of some cells, check it out): https://docs.google.com/spreadsheets/d/1WuVi7F1PDpH69JWRa9bDxTHT1JaA5w43/edit?usp=sharing&ouid=113909502023297765536&rtpof=true&sd=true
Get the path of your downloaded file and replace both the TOKEN and the PATH of your file, then try to run this code:
curl --location --request POST 'RAPID_API_ENDPOINT' \
--form 'changes="[{\"cell\": \"A1\", \"sheet\": \"Sheet 1\", \"value\": 4}]"' \
--form 'select="[{\"cell\": \"A7\", \"sheet\": \"Sheet 1\"}]"' \
--form 'file=@"/Yourmachine/yourusername/change/this/excel-example.xlsx"' // download this from the instructions above
In order to change any column in the Excel file, you must know which Sheet you want to operate on, then you can describe the changes to your file in the following format:
[{"cell": CELL_NAME (i.e. A11), "sheet": SHEET_NAME (i.e. "Sheet 1"), "value": anything as long as it works in excel}]
The same exact format goes for the field โselectโ of the form, you need to specify cell name
and sheet
(see the curl example above).
[{"cell": CELL_NAME (i.e. A11), "sheet": SHEET_NAME (i.e. "Sheet 1")}]
Download this Excel file (does nothing but the sum of some cells, check it out): https://docs.google.com/spreadsheets/d/1WuVi7F1PDpH69JWRa9bDxTHT1JaA5w43/edit?usp=sharing&ouid=113909502023297765536&rtpof=true&sd=true and place it under /Users/yourusername/Desktop/excel-example.xlsx
In the following example we are changing the cell A1 of the sheet โSheet 1โ and setting the value to the number 4:
var axios = require('axios');
var FormData = require('form-data');
var fs = require('fs');
var data = new FormData();
data.append('changes', '[{"cell": "A1", "sheet": "Sheet 1", "value": 4}]'); // we want to change only this cell
data.append('select', '[{"cell": "A7", "sheet": "Sheet 1"}]'); // we want to read this value then
data.append('file', fs.createReadStream('/Users/yourusername/Desktop/excel-example.xlsx')); //