Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Uploading Entitlements using Schema-Based Upload via API

Sahana_BB
New Contributor
New Contributor

Hi Team,

We are trying to Import Entitlements through API and have an issue with running "File based Entitlement Import (SchemaEntitlementJob)Job through API

I have this SAV file(ENTITLEMENT_VALUES.SAV)

FILE_NAME_STARTS_WITH=Entitlement_Values
SKIP_NO_OF_LINES=1
FILE_IMPORT_DELIMETER=,
#EMAILTEMPLATE="Email Template Name"
CREATE_SECURITYSYSTEM_IF_NOT_EXIST=NOACTION
CREATE_ENDPOINT_IF_NOT_EXIST_IN_SECURITYSYSTEM=NOACTION
CREATE_ENTITLEMENTTYPE_IF_NOT_EXIST_IN_ENDPOINT=CREATE
ENTITLEMENT_VALUES_NOT_IN_FILE_ACTION=NOACTION
#ENTITLEMENT_VALUES_NOT_IN_FILE_ACTION=INACTIVE
securitysystems,endpoints,entitlementtype,entitlement_value,description,customproperty1,customproperty2,customproperty3,owner,rank,status

Similarly, the data file is as follows (Entitlement_Values.csv):

Sahana_BB_5-1664193299500.png

The SAV and data files are loaded to the corresponding directories on the UI /Datafiles and /SAV through API-Postman

When the schema based Entitlement import job is run  through API with the below configuration:

Sahana_BB_2-1664192867082.png

 

Sahana_BB_6-1664193504110.png

The result through API says 200 Ok with the message: Starting job

Sahana_BB_7-1664193586991.png

 

But the job history shows the below error:

Sahana_BB_4-1664193006331.png

 

Even though the job ended with error, the data file (.csv) is still in the Datafiles folder instead of being moved to the /Fail folder.

But if the same Job is run through UI > Job Control Panel, the datafile(.csv) is moved to Success folder and everything works as expected. 

Is something wrong with the API body?

 

Thanks, Sahana

4 REPLIES 4

rushikeshvartak
All-Star
All-Star

Can you share screenshot of files uploaded in Datafiles & sav location

trying changing

FILE_NAME_STARTS_WITH=Entitlement_Values.sav


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

Hi Rushikesh,

Thanks for replying:)

Changed the sav file name to Entitlement_Values.sav and tested it, same issue Job fails when its run through API and csv file stays in /Datafiles itself instead of moving to /success

 

Sahana_BB_3-1664345385213.png

Sahana_BB_4-1664345484612.png

Can you please verify and help in figuring out this issue?

 

 

Please share logs after running job. Or try running job from saviynt first then go with API


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

Hi Rushikesh,

Thanks for replying!

If Job is run from saviynt it works perfectly, the issue is if the same job is run from API it fails. For our use case we want the job to run successfully from API.

Attaching the logs after running Job through API..