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

403 Forbidden API /uploadUserRequest

alex1
New Contributor III
New Contributor III

Hi,

We are currently trying to trigger a csv file via uploadUserRequest. We are using the endpoint https:/{Base_url}/ECM/api/v5/uploadUserRequest according to the documentation here: https://documenter.getpostman.com/view/23973797/2s9YC5xBrz#a6d2f398-08cb-4a62-b839-c6640a5ceff1

This works fine, but we also want to include userpreprocessorconfigjson parameter to run transformations before the data is updated. When we add this parameter to the request it fails with a 403 Forbidden message. The user that we are using has the standard admin SAV Role so should have all required access.


So far, I have seen that the problem comes as soon as I add a SELECT statement in the userpreprocessorconfigjson. So for example, 

 

{
    "ADDITIONALTABLES": {
        "USERS": "SELECT username, employeeid, customproperty18, statuskey,startdate,customproperty26,email,systemusername from USERS"
    }
}

 

doesnt work and we get a 403. 

This however, when we change SELECT to some other things, like ST, the request goes through with a status code 200 (but then of course without the preprocessor working)

 

{
    "ADDITIONALTABLES": {
        "USERS": "ST username, employeeid, customproperty18, statuskey,startdate,customproperty26,email,systemusername from USERS"
    }
}

 

By looking at the headers, we can see the response when we get a 403 returns this: 

alex1_0-1705669580462.png

I couldn't find anything related on the documentation or anything related in the forums (as the user has all the webservice access that it should need). The same result is achieved both using a script or via postman with the exact same criteria.

Also, keep in mind, above preprocessors are just some examples, we have tried with the real ones with the exact same result, just tried to make it easier to read as they are quite long. If I try to do the same thing in the user interface by uploading the file manually, everything works as expected and the preprocessor runs without any issues at all.

I can see in the 23.6 release notes, it says that a similar issue has been fixed, but not sure if its relevant to my issue. We are also getting access tokens without any problems, so the login is not the problem

What could be the cause of this? .

alex1_1-1705669689582.png

8 REPLIES 8

rushikeshvartak
All-Star
All-Star

Share postman screenshot and 

Please share curl command [Refer https://codingnconcepts.com/postman/how-to-generate-curl-command-from-postman/ ]


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

Please follow up on this. I also have the same issue.

alex1
New Contributor III
New Contributor III
curl --location 'https://BASE_URL/ECM/api/v5/uploadUserRequest' 
--header 'Authorization: Bearer TOKEN' 
--header 'Cookie: JSESSIONID=SESSION_ID; CCSRF TOKEN=CCSRF_TOKEN; INGRESSCOOKIE=COOKIE_VALUE; token_type=Bearer; user_name=API_SAV4SAV' 
--form 'delimiter="comma"' 
--form 'userReconillationField="employeeid"' 
--form 'userpreprocessorconfigjson="{
    \"ADDITIONALTABLES\": {
        \"USERS\": \"SELECT username, employeeid, customproperty18, statuskey,startdate,customproperty26,email,systemusername from USERS\"
    }
}"' --form 'file=@"PATH_TO_FILE.csv"'

What do you want to see in the screenshot thats not explained above?

Do you see any error in logs when you hit REST API


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

Hi,

There is no logs at all regarding the import, we cant even see that the request is reaching our tenant. If I remove the preprocessing I can see that the request is being processed as expected. But we get no error message when it returns 403 outside except from where we are making the request.

I am also getting same error. and no logs with {} in json getting 500.

rushikeshvartak_0-1706238902238.png

 


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

Hi, 

I had a problem initially getting a 500 response, but now we are only getting 403 forbidden. Still not working for us.

Please raise support ticket it seems defect


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