POST request returns error 403

1
Hello! I have a problem when i try to post. I read the answer to another same question where the problem was fixed (https://community.mendix.com/link/questions/88801) and did everything it said, but I still have the same problem. Please, could anybody help?  
asked
5 answers
1

I see an issue in your request. After you get a response with a header called

set-cookie

you should be passing it as a header in the next request as just

cookie

 

answered
0

Hey Judith,

 

I don’t have an answer right away, but when debugging REST services, I find it helpful to recreate everything in Postman. That way i can manually set all keys and values and also solely focus on the REST call.

Once managed to get it running manually, I reproduce it in Mendix.

 

Hope that helps,

Tom

answered
0

If possible, contact the party that you are posting to. 403 is the http-standard response for authentication issues, but they can actually set it themselves (I agree, it’s unlikely). Also, they will probably be able to verify if your credentials are valid or not.

And Tom’s way is also good. Next to that, you might prefer SOAP over Postman, or (I don’t know your background) even prefer curl.

***Edited, since your call is fine from Postman. ***

Now check out the log by in StudioPro going to Console=>Advanced=>Set log levels. Find ‘Rest Consume’ and set the level to ’Trace’. Do the rest-call again and you will see extra lines in the log. See if they tell you more.

answered
0

Doing the rest-call, I get the following results. It seems that the problem is in the token, but I don’t understand why.

Request content:

 

Response content:

 

This is the Postman request:

 

answered
0

The HTTP error 403 - Forbidden indicates that the server understands the request made by the client, but is refusing to fulfill it. This error typically occurs when the server receives a request for a resource that the client is not authorized to access. The server denies access to the requested resource due to permissions, authentication, or other security-related reasons. The HTTP error 403 message serves as a notification to the client that they are not permitted to access the requested content or perform the requested action. To resolve this error, the client may need to authenticate themselves, adjust their permissions, or contact the server administrator for further assistance.

 

answered