SDK Reference
Last updated
Was this helpful?
Last updated
Was this helpful?
Xomlo.io SDK contains functions specified below. All are accessible via functions object which you can import with the following code:
This function is called every time the connector is started. It has only one argument required, a void function with the payload as an argument and all of your logic in the body.
Arguments:
fn
async function
Async function with the connector's payload as an argument. All code should be inside this function.
Returns:
void
Everything in the application should be logged via our custom logger instead of using console.log()
. This is because all logs are stored while the connector is run in the Xomlo.io runtime. For more information, please follow the . Usage example:
You should use our .saveOutput()
function every time you work with the filesystem. It creates your file in the ./output
folder. When you run your connector in the Xomlo.io runtime every file inside the ./output
folder will be uploaded to the Xomlo.io storage bucket.
Arguments:
fileName
string
Name of the created file (you can also contain the subfolder)
data
string
Content of the created file
Returns:
void
You should use our HTTP bundle every time you work with HTTP requests. Check the for more information.