Change a field case
The same fields as opening one. A closed case refuses every change (409) until a supervisor reopens it. It is closed with Close, not here. Needs write on Animals.
PATCH
https://{organization}.rescueconsole.com
/
api
/
animals
/
field-services
/
cases
/
{id}
Change a field case
curl --request PATCH \
--url https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"type_id": "<string>",
"description": "<string>",
"address": {},
"location_notes": "<string>",
"jurisdiction_id": "<string>",
"zone_id": "<string>",
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": true,
"assigned_person_id": "<string>"
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
type_id: '<string>',
description: '<string>',
address: {},
location_notes: '<string>',
jurisdiction_id: '<string>',
zone_id: '<string>',
reported_at: '2023-11-07T05:31:56Z',
due_on: '2023-12-25',
reported_anonymously: true,
assigned_person_id: '<string>'
})
};
fetch('https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id}"
payload = {
"title": "<string>",
"type_id": "<string>",
"description": "<string>",
"address": {},
"location_notes": "<string>",
"jurisdiction_id": "<string>",
"zone_id": "<string>",
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": True,
"assigned_person_id": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"case": {
"id": "<string>",
"case_number": "2026-0001",
"title": "<string>",
"priority": 1,
"status": "new",
"type": {
"id": "<string>",
"name": "<string>"
},
"address": {},
"address_line": "<string>",
"location_notes": "<string>",
"zone": {
"id": "<string>",
"name": "<string>"
},
"jurisdiction": {
"id": "<string>",
"name": "<string>"
},
"assigned": {
"id": "<string>",
"name": "<string>"
},
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": true,
"outcome": "resolved",
"outcome_notes": "<string>",
"opened_at": "2023-11-07T05:31:56Z",
"closed_at": "2023-11-07T05:31:56Z",
"activity_count": 123,
"last_activity_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"danger": {
"id": "<string>",
"reasons": [
"<string>"
],
"address": {},
"address_line": "<string>",
"notes": "<string>",
"flagged_at": "2023-11-07T05:31:56Z",
"flagged_by": {
"id": "<string>",
"name": "<string>"
},
"removed_at": "2023-11-07T05:31:56Z",
"removed_reason": "<string>",
"can_change": true
},
"description": "<string>",
"people": [
{
"id": "<string>",
"role": "reporter",
"person": {
"id": "<string>",
"name": "<string>"
}
}
],
"animals": [
{
"id": "<string>",
"animal": {
"id": "<string>",
"name": "<string>",
"pet_id": "<string>"
}
}
],
"activities": [
{
"id": "<string>",
"kind": "visit",
"happened_at": "2023-11-07T05:31:56Z",
"notes": "<string>",
"by": {
"id": "<string>",
"name": "<string>"
},
"animal": {
"id": "<string>",
"name": "<string>"
},
"photo_file_ids": [
"<string>"
],
"can_change": true
}
],
"can": {
"change": true,
"close": true,
"reopen": true,
"delete": true
},
"violations": [
{
"id": "<string>",
"case_id": "<string>",
"case_number": "<string>",
"case_title": "<string>",
"case_address_line": "<string>",
"ordinance": {
"id": "<string>",
"code": "<string>",
"name": "<string>"
},
"person": {
"id": "<string>",
"name": "<string>",
"address_line": "<string>"
},
"animal": {
"id": "<string>",
"name": "<string>"
},
"happened_at": "2023-11-07T05:31:56Z",
"action": "warning",
"citation_number": "<string>",
"fine_cents": 123,
"fine_due_on": "2023-12-25",
"status": "issued",
"paid_on": "2023-12-25",
"notes": "<string>",
"status_notes": "<string>",
"issued_by": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"can": {
"change": true,
"change_status": true,
"delete": true
}
}
]
}
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}Authorizations
Body
application/json
⌘I
Change a field case
curl --request PATCH \
--url https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"type_id": "<string>",
"description": "<string>",
"address": {},
"location_notes": "<string>",
"jurisdiction_id": "<string>",
"zone_id": "<string>",
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": true,
"assigned_person_id": "<string>"
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
title: '<string>',
type_id: '<string>',
description: '<string>',
address: {},
location_notes: '<string>',
jurisdiction_id: '<string>',
zone_id: '<string>',
reported_at: '2023-11-07T05:31:56Z',
due_on: '2023-12-25',
reported_anonymously: true,
assigned_person_id: '<string>'
})
};
fetch('https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{organization}.rescueconsole.com/api/animals/field-services/cases/{id}"
payload = {
"title": "<string>",
"type_id": "<string>",
"description": "<string>",
"address": {},
"location_notes": "<string>",
"jurisdiction_id": "<string>",
"zone_id": "<string>",
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": True,
"assigned_person_id": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"case": {
"id": "<string>",
"case_number": "2026-0001",
"title": "<string>",
"priority": 1,
"status": "new",
"type": {
"id": "<string>",
"name": "<string>"
},
"address": {},
"address_line": "<string>",
"location_notes": "<string>",
"zone": {
"id": "<string>",
"name": "<string>"
},
"jurisdiction": {
"id": "<string>",
"name": "<string>"
},
"assigned": {
"id": "<string>",
"name": "<string>"
},
"reported_at": "2023-11-07T05:31:56Z",
"due_on": "2023-12-25",
"reported_anonymously": true,
"outcome": "resolved",
"outcome_notes": "<string>",
"opened_at": "2023-11-07T05:31:56Z",
"closed_at": "2023-11-07T05:31:56Z",
"activity_count": 123,
"last_activity_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"danger": {
"id": "<string>",
"reasons": [
"<string>"
],
"address": {},
"address_line": "<string>",
"notes": "<string>",
"flagged_at": "2023-11-07T05:31:56Z",
"flagged_by": {
"id": "<string>",
"name": "<string>"
},
"removed_at": "2023-11-07T05:31:56Z",
"removed_reason": "<string>",
"can_change": true
},
"description": "<string>",
"people": [
{
"id": "<string>",
"role": "reporter",
"person": {
"id": "<string>",
"name": "<string>"
}
}
],
"animals": [
{
"id": "<string>",
"animal": {
"id": "<string>",
"name": "<string>",
"pet_id": "<string>"
}
}
],
"activities": [
{
"id": "<string>",
"kind": "visit",
"happened_at": "2023-11-07T05:31:56Z",
"notes": "<string>",
"by": {
"id": "<string>",
"name": "<string>"
},
"animal": {
"id": "<string>",
"name": "<string>"
},
"photo_file_ids": [
"<string>"
],
"can_change": true
}
],
"can": {
"change": true,
"close": true,
"reopen": true,
"delete": true
},
"violations": [
{
"id": "<string>",
"case_id": "<string>",
"case_number": "<string>",
"case_title": "<string>",
"case_address_line": "<string>",
"ordinance": {
"id": "<string>",
"code": "<string>",
"name": "<string>"
},
"person": {
"id": "<string>",
"name": "<string>",
"address_line": "<string>"
},
"animal": {
"id": "<string>",
"name": "<string>"
},
"happened_at": "2023-11-07T05:31:56Z",
"action": "warning",
"citation_number": "<string>",
"fine_cents": 123,
"fine_due_on": "2023-12-25",
"status": "issued",
"paid_on": "2023-12-25",
"notes": "<string>",
"status_notes": "<string>",
"issued_by": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"can": {
"change": true,
"change_status": true,
"delete": true
}
}
]
}
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}{
"error": "house_trained must be 1, 0 or null (not assessed)"
}
