cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

403 Forbidden when POSTING from c# application

0 Likes
801

I'm writing an application which calls a SAP Gateway service. but I'm facing some problems related with my post requisition. I'll describe the steps I'm following.

First, I'm making a get requisition with username and password to take the token by x-csrf-token. Then I try to make a post requisition passing this token, but the problem is that I have been receiving the 403 Forbidden error.

I don't know why, but using the postman app to make the post requisition, both steps cited above works fine.

Another thing is that my application takes a different token for each get requisition, this is a thing that doesn't happen using postman.

To finish, I found a post of a colleague in the scn with the same problem I'm facing, but i didn't feel satisfied with the answer.

https://archive.sap.com/discussions/thread/3956649

If someone could help me, i'll be very glad.

thank you.

Accepted Solutions (0)

Answers (1)

Answers (1)

The problem was solved by adding the header "cookie = SAP_SESSIONID_GWD_100=foNn4m5...." which is returned in the get requisition.