Hey Team,
I’ve been working on a SaaS Connector for the first time and have got the connector packaged and uploaded it to IDN without any issues, but after filling in the config and running a test-connect, I’m getting the following error:
[ConnectorError] invalid output format: Schema validation error in path: [/: {"data":{},"type":"o... additional properties are not allowed] (requestId: 90d9e108a17a48549236a7e4ad4e0343)
I am able to run sail conn validate -c lever -p .\config.json -r --check test-connection-success
with a pass and sail conn logs
shows that the command output was completed:
INFO | commandOutcome ▶︎ {"commandType":"std:test-connection","completed":true,"elapsed":513,"message":"command completed","requestId":"90d9e108a17a48549236a7e4ad4e0343","version":4}
The code for the test connect is pretty much unchanged:
const config = await readConfig()
const lever = new Lever(config)
return createConnector()
.stdTestConnection(async (context: Context, input: undefined, res: Response<StdTestConnectionOutput>) => {
logger.info("Running test connection")
res.send(await lever.testConnection())
})
async testConnection(): Promise<StdTestConnectionOutput> {
await this.client
.get('/users')
.catch(err => { throw new ConnectorError('lever connection failed') })
return {}
}
Testing with REST Client returns the following object:
{
"data": {},
"type": "output"
}
It all looks correct to me, but I might be missing something. Any help would be greatly appreciated.