KevinTheJedi Thanks for the reply.
We understood that it is not a CORS issue. Actual error is Request is malformed.
Request is as below
{
"name": "John Doe",
"email": "johndoe@gmail.com",
"subject": "Request for something",
"topicId": 2,
"message": "test"
}
We have added the X-API-Key also in the headers. From cURL CLI and PHP Script, we are getting a success response i.e. a ticket is succesfully created in osTicket. However, when we fire the API with data from a React App or a Postman Client (Browser Agent), we are getting 400 Bad Request - Your browser sent a request that this server could not understand.
as error.
Any help or advice would be much appreciated.
--
Hari