Delete a leave
curl --request DELETE \
--url https://api.scholarlysoftware.com/api/v1/leaves/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.scholarlysoftware.com/api/v1/leaves/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.scholarlysoftware.com/api/v1/leaves/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}Leaves
Delete a leave
Deletes a specific leave
An important note on deleting leaves
This resource is effective-dated in the Scholarly data model, which means you should almost-never delete a leave.
Instead, you should update the effective_to property via updating a leave to signify that the leave has ended.
DELETE
/
api
/
v1
/
leaves
/
{id}
Delete a leave
curl --request DELETE \
--url https://api.scholarlysoftware.com/api/v1/leaves/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.scholarlysoftware.com/api/v1/leaves/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.scholarlysoftware.com/api/v1/leaves/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}{
"errors": [
{
"status": "<string>",
"title": "<string>",
"detail": "<string>"
}
]
}⌘I