Hello everyone.
I want to create a case with the rest api.
First I log in ok with http://localhost:8080/bonita/loginservice and get the cookies
Then I try to create the case with a POST to the url
http://localhost:8080/pretty/API/bpm/case
using postman. It returns a status code 401 unauthorized.
This is the postman code
var axios = require('axios');
var data = JSON.stringify({
"processDefinitionId": "7612481195189194033",
"variables": [
{
"name": "performanceContract",
"value": [
{
"name": "montantAvance",
"value": "150"
},
{
"name": "modePerception",
"value": "Virement"
}
]
}
]
});
var config = {
method: 'post',
url: 'http://localhost:8080/bonita/API/bpm/case',
headers: {
'Content-Type': 'application/json',
'Cookie': 'pretty.tenant=1; BOS_Locale=en; JSESSIONID=2B622A17A403683551A58FF87AC47CB3; X-Pretty-API-Token=ccf7c15f-d8ec-4a2c-a0e8-c87e4dd28673'
},
date : date
};
any help available?