Using the IdentityNow TypeScript SDK with SaaS Connectors

Hi All,

I’m a beginner with JS/TS development, so sorry if this question is very basic. I’m trying to create a SaaS connector that calls IdentityNow’s APIs for some automation tasks leveraging our TypeScript SDK.

Checking the SDK docs (TypeScript SDK | SailPoint Developer Community), I see the two ways of configuring the client are either through env variables or a manual config.yaml file.

In the SaaS connector, I will get the apiUrl, clientID and clientSecret through the source config. Does anyone have an example of programmatically configuring the api client, then perhaps calling one of the V3/Beta APIs?

Hi @mostafa_helmy,

You can use the IdentityNow Management SaaS Connector as a reference to complete the requirements.
Link:- GitHub - fernando-delosrios/IdentityNowManagement: IdentityNow Management custom connector

Thanks Animesh! Yes I saw Fernando’s example and I am keeping it as my plan B. Was hoping I would be able to use our TypeScript SDK instead of having to build the API calls manually using Axios.

Just to reiterate for clarification, there are two ‘TypeScript SDKs’ from SailPoint out there:

  1. SaaS connectors SDK, which allows you to build your own custom SaaS connector
  2. IdentityNow SDK, which allows you to call the IdentityNow APIs using different functions and methods.

I’ve done some personal development (nothing to be shared yet), which combines both for a loopback connector.

To share some code snippets, which are part of my class constructor:

This will get the config from my source and use that as ConfigurationParameters

    const ConfigurationParameters: ConfigurationParameters = {
      baseurl: config?.baseUrl,
      clientId: config?.client_id,
      clientSecret: config?.client_secret,
      tokenUrl: config?.baseUrl + "/oauth/token"
    }

This builds an apiConfig, which can be used for the different APIs that are supported

    this.apiConfig = new Configuration(ConfigurationParameters)
    this.apiConfig.retriesConfig = {
      retries: 2
    }

This is one of the APIs that I’m using, in this case to change the IdentityNow permissions of an identity.

this.UserCCApi = new UserCCApi(this.apiConfig)

So combining both, without using axios is possible for sure!

1 Like

Perfect! Thanks Edwin, this is exactly what I was after.

Just testing and it works :slight_smile: Creating the ConfigurationParameters is what was missing on my side as the SDK seemed to be still pulling some environment details from sailpoint-cli.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.