SaaS Connector test-connection failing in IDN

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.

Hi Matthew,

The reason for this is because you are fetching directly from GitHub instead of from NPM. To use the most up to date package from NPM for the connector, in your package.json, make sure your dependency is pulling from NPM instead of github. Here is what you should have:

"@sailpoint/connector-sdk": "^1.0.0",

The older CLI was creating the dependency directly to github, so please update that line, issue the npm install command and your response should be correct.