@swydo/custom-integrations
v1.0.274
Published
Custom integrations enable any online platform to be integrated with Swydo to use in your reports
Downloads
97
Readme
custom-integrations
Swydo custom integrations enables any online platform to connect to Swydo. Join us on Gitter.
Get started
To get started with building custom integrations for the Swydo platform we recommend going through the following steps to get accustomed to the terminology and workflow.
Next: Adapt and connect your data.
- Have a look at the Star Wars custom integration.
- Read our tips and tricks.
- Be inspired and explore our common fields.
- Learn all about data scopes.
References: Detailed references to explore all possibilities.
Quick start
The supported Node.js version is 12.x
LTS.
Install
npm install @swydo/custom-integrations
Create your adapter configuration
Have a look at the Adapter configuration specification for all options and possibilities.
src/adapter.js
const adapter = {
id: 'my-custom-integration',
authentication: {
// Your authentication method
},
endpoints: [
// Your endpoints.
],
};
module.exports = {
adapter,
};
Export your custom integration
src/index.js
const { buildCustomIntegration } = require('@swydo/custom-integrations');
const config = require('./adapter');
const customIntegration = buildCustomIntegration(config);
module.exports = {
customIntegration,
};
Your module defines the file the custom integration is exported from (the entrypoint) as "main" in your package.json file.
package.json
{
"name": "my-swydo-integration",
"version": "0.0.1",
"main": "src/index.js",
"dependencies": {
"@swydo/custom-integrations ": "latest"
}
}
Learn more about package.json
on npmjs.com.
Example implementation
A complete custom integration example integrating the Star Wars API can be found here: github.com/Swydo/star-wars-integration