Make Reservation For Vault Account
1 min
POST
{{url}}/aioc-rest-web/rest/sc/sapm/makeReservation
Path Parameters
- urlstringDefaulturl
Header Parameters
- X-XSRF-TOKENstringDefault{{csrftoken}}
Body Parameters
- bodyobjectDefault{ "sapmDbId": 464216, "comment": "asdf11g", "startDate": "2026-10-02T19:45:00", "endDate": "2026-10-28T21:45:00", "firstPartUser": { "eid": "test_user2", "id": "e039e179-ba80-4932-b07d-f33db7e38d3a" }, "secondPartUser": { "eid": "test_user3", "id": "f4118975-355b-40f7-a5d5-ed0fdc81a5c2" }, "remindBeforeInMins": 15 }
Responses
200
curl
curl --request POST \
--url {{url}}/aioc-rest-web/rest/sc/sapm/makeReservation \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--header 'x-xsrf-token: {{csrftoken}}' \
--data '"{\n \"sapmDbId\": 464216,\n \"comment\": \"asdf11g\",\n \"startDate\": \"2026-10-02T19:45:00\",\n \"endDate\": \"2026-10-28T21:45:00\",\n \"firstPartUser\": {\n \"eid\": \"test_user2\",\n \"id\": \"e039e179-ba80-4932-b07d-f33db7e38d3a\"\n },\n \"secondPartUser\": {\n \"eid\": \"test_user3\",\n \"id\": \"f4118975-355b-40f7-a5d5-ed0fdc81a5c2\"\n },\n \"remindBeforeInMins\": 15\n}\n"'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
myHeaders.append("x-xsrf-token", "{{csrftoken}}");
var raw = JSON.stringify("{\n \"sapmDbId\": 464216,\n \"comment\": \"asdf11g\",\n \"startDate\": \"2026-10-02T19:45:00\",\n \"endDate\": \"2026-10-28T21:45:00\",\n \"firstPartUser\": {\n \"eid\": \"test_user2\",\n \"id\": \"e039e179-ba80-4932-b07d-f33db7e38d3a\"\n },\n \"secondPartUser\": {\n \"eid\": \"test_user3\",\n \"id\": \"f4118975-355b-40f7-a5d5-ed0fdc81a5c2\"\n },\n \"remindBeforeInMins\": 15\n}\n");
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: raw,
redirect: 'follow'
};
fetch("{{url}}/aioc-rest-web/rest/sc/sapm/makeReservation", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("{{url}}/aioc-rest-web/rest/sc/sapm/makeReservation")
http = Net::HTTP.new(url.host, url.port);
request = Net::HTTP::Post.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
request["x-xsrf-token"] = "{{csrftoken}}"
request.body = JSON.dump("{\n \"sapmDbId\": 464216,\n \"comment\": \"asdf11g\",\n \"startDate\": \"2026-10-02T19:45:00\",\n \"endDate\": \"2026-10-28T21:45:00\",\n \"firstPartUser\": {\n \"eid\": \"test_user2\",\n \"id\": \"e039e179-ba80-4932-b07d-f33db7e38d3a\"\n },\n \"secondPartUser\": {\n \"eid\": \"test_user3\",\n \"id\": \"f4118975-355b-40f7-a5d5-ed0fdc81a5c2\"\n },\n \"remindBeforeInMins\": 15\n}\n")
response = http.request(request)
puts response.read_body
python
import requests
import json
url = "{{url}}/aioc-rest-web/rest/sc/sapm/makeReservation"
payload = json.dumps("{\n \"sapmDbId\": 464216,\n \"comment\": \"asdf11g\",\n \"startDate\": \"2026-10-02T19:45:00\",\n \"endDate\": \"2026-10-28T21:45:00\",\n \"firstPartUser\": {\n \"eid\": \"test_user2\",\n \"id\": \"e039e179-ba80-4932-b07d-f33db7e38d3a\"\n },\n \"secondPartUser\": {\n \"eid\": \"test_user3\",\n \"id\": \"f4118975-355b-40f7-a5d5-ed0fdc81a5c2\"\n },\n \"remindBeforeInMins\": 15\n}\n")
headers = {
'accept': 'application/json',
'content-type': 'application/json',
'x-xsrf-token': '{{csrftoken}}'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
200
SUCCESS