Add a catalogue item
curl --request POST \
--url https://{organization}.rescueconsole.com/api/animals/medical-catalogue \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "test",
"label": "Heartworm antigen (in-house)",
"fields": [
{
"label": "Result",
"type": "select",
"options": [
"Negative",
"Positive"
]
},
{
"label": "Kit lot",
"type": "text"
}
],
"notes": "Run at intake for every dog over six months."
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'test',
label: 'Heartworm antigen (in-house)',
fields: [
{label: 'Result', type: 'select', options: ['Negative', 'Positive']},
{label: 'Kit lot', type: 'text'}
],
notes: 'Run at intake for every dog over six months.'
})
};
fetch('https://{organization}.rescueconsole.com/api/animals/medical-catalogue', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{organization}.rescueconsole.com/api/animals/medical-catalogue"
payload = {
"kind": "test",
"label": "Heartworm antigen (in-house)",
"fields": [
{
"label": "Result",
"type": "select",
"options": ["Negative", "Positive"]
},
{
"label": "Kit lot",
"type": "text"
}
],
"notes": "Run at intake for every dog over six months."
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"item": {
"id": "<string>",
"kind": "diagnosis",
"key": "<string>",
"label": "<string>",
"fields": [
{
"key": "<string>",
"label": "<string>",
"type": "text",
"options": [
"<string>"
],
"unit": "<string>"
}
],
"notes": "<string>",
"is_active": true,
"sort_order": 123,
"alters": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
}{
"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)"
}Medical catalogue
Add a catalogue item
Adds an item at the end of its kind. Its key is made from the label unless you give one, and must be unique within the kind. At most 500 items of one kind. Needs write on Animals.
POST
/
api
/
animals
/
medical-catalogue
Add a catalogue item
curl --request POST \
--url https://{organization}.rescueconsole.com/api/animals/medical-catalogue \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "test",
"label": "Heartworm antigen (in-house)",
"fields": [
{
"label": "Result",
"type": "select",
"options": [
"Negative",
"Positive"
]
},
{
"label": "Kit lot",
"type": "text"
}
],
"notes": "Run at intake for every dog over six months."
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
kind: 'test',
label: 'Heartworm antigen (in-house)',
fields: [
{label: 'Result', type: 'select', options: ['Negative', 'Positive']},
{label: 'Kit lot', type: 'text'}
],
notes: 'Run at intake for every dog over six months.'
})
};
fetch('https://{organization}.rescueconsole.com/api/animals/medical-catalogue', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{organization}.rescueconsole.com/api/animals/medical-catalogue"
payload = {
"kind": "test",
"label": "Heartworm antigen (in-house)",
"fields": [
{
"label": "Result",
"type": "select",
"options": ["Negative", "Positive"]
},
{
"label": "Kit lot",
"type": "text"
}
],
"notes": "Run at intake for every dog over six months."
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"item": {
"id": "<string>",
"kind": "diagnosis",
"key": "<string>",
"label": "<string>",
"fields": [
{
"key": "<string>",
"label": "<string>",
"type": "text",
"options": [
"<string>"
],
"unit": "<string>"
}
],
"notes": "<string>",
"is_active": true,
"sort_order": 123,
"alters": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
}{
"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
An API key from Settings, API keys. It starts with rc_live_.
Body
application/json
A condition is a lasting fact about the animal, such as FIV positive; a diagnosis is an episode with a date.
Available options:
diagnosis, test, vaccine, treatment, procedure, condition Cut to 120 characters.
Made from the label unless you give one. Turned into lowercase letters, digits and underscores, at most 40 characters.
Maximum array length:
40Show child attributes
Show child attributes
Cut to 1,000 characters.
Response
The item, as it was created.
Show child attributes
Show child attributes