API reference · Core resources
Structured templates: a typed set of fields that Vetnio fills to produce a form-like document instead of free text.
A structured template with its full schema. A structured template defines separate output fields (for example Anamnesis, Examination, Treatment) that Vetnio fills from a consultation, either as a structured clinical note or through Generate a structured document.
idstringrequiredID of the JSON template (a UUID).
namestringrequirednullableName of the structured template as shown in Vetnio. null if it was saved without a name.
jsonTemplateSchemaobjectrequiredThe JSON Schema that generated documents follow: one property per field, with the instructions the AI uses to fill it.
typestringrequiredJSON Schema type of the document root. object for every structured template; a schema saved without a valid type is reported as object.
Default object
titlestringoptionalOptional schema title.
descriptionstringoptionalOptional description of the whole document.
propertiesobjectoptionalThe template's fields, keyed by the exact key that appears in generated documents. Each value is a JSON Schema property: type (string, number, integer, boolean, array or object), a description telling the AI what to extract and what to do when it is missing, and optionally title, enum (permitted answers, the Single choice and Multiple choice section types in Vetnio), items for arrays and nested properties for objects. Always present (possibly empty) when type is object.
requiredarray of stringsoptionalKeys of properties that generated documents must always contain. When a field is required but nothing relevant was said, generation leaves it empty rather than inventing a value.
enumarray of string | number | booleansoptionalPermitted values for the document root. Not used by structured templates in practice, which put enum on individual properties instead.
createdAtstringrequiredWhen the template was created, as an ISO-8601 UTC timestamp. Built-in templates report 1970-01-01T00:00:00.000Z.
{
"id": "2a859133-0e04-4f63-88d2-aa0ee318cd8d",
"name": "Soap Note for Dog",
"jsonTemplateSchema": {
"type": "object",
"title": "Canine Medical Report",
"properties": {
"subjectiveInformation": {
"type": "object",
"properties": {
"reasonForVisit": {
"type": [
"string",
"null"
]
},
"symptoms": {
"type": [
"string",
"null"
]
},
"pastIllnesses": {
"type": [
"string",
"null"
]
},
"medications": {
"type": [
"string",
"null"
]
}
},
"required": [
"reasonForVisit",
"symptoms",
"pastIllnesses",
"medications"
],
"additionalProperties": false
},
"objectiveInformation": {
"type": "object",
"properties": {
"generalCondition": {
"type": [
"string",
"null"
]
},
"vitalSigns": {
"type": "object",
"properties": {
"temperature": {
"type": [
"number",
"null"
]
},
"pulse": {
"type": [
"number",
"null"
]
},
"respiratoryRate": {
"type": [
"number",
"null"
]
}
},
"required": [
"temperature",
"pulse",
"respiratoryRate"
],
"additionalProperties": false
},
"physicalExamination": {
"type": [
"string",
"null"
]
},
"laboratoryResults": {
"type": [
"string",
"null"
]
}
},
"required": [
"generalCondition",
"vitalSigns",
"physicalExamination",
"laboratoryResults"
],
"additionalProperties": false
},
"assessment": {
"type": "object",
"properties": {
"diagnosis": {
"type": [
"string",
"null"
]
},
"differentialDiagnoses": {
"type": "array",
"items": {
"type": [
"string",
"null"
]
}
},
"prognosis": {
"type": [
"string",
"null"
]
}
},
"required": [
"diagnosis",
"differentialDiagnoses",
"prognosis"
],
"additionalProperties": false
},
"plan": {
"type": "object",
"properties": {
"treatment": {
"type": [
"string",
"null"
]
},
"followUp": {
"type": [
"string",
"null"
]
},
"ownerInformation": {
"type": [
"string",
"null"
]
}
},
"required": [
"treatment",
"followUp",
"ownerInformation"
],
"additionalProperties": false
}
},
"required": [
"subjectiveInformation",
"objectiveInformation",
"assessment",
"plan"
],
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false
},
"createdAt": "1970-01-01T00:00:00.000Z"
}GET/workspaces/{workspaceId}/json-templates
Returns the ID and name of every JSON template (called structured templates in Vetnio) available in the workspace: the workspace's own, followed by Vetnio's built-in ones. Use the ID with Generate a structured document, or fetch the fields with Get JSON template detail.
Every workspace member sees every JSON template; there are no per-user visibility rules. The list is not paginated and the order of the workspace's own templates is not guaranteed. Requires a personal API key.
AcceptsPersonal key
workspaceIdstringrequiredIdentifier of the clinic (workspace), as returned by GET /workspaces. The key's user must be a member of the clinic, or an admin of the organization it belongs to.
[ ]array of objectsrequiredThe workspace's own JSON templates (in no guaranteed order) followed by Vetnio's built-in JSON templates, which are available in every workspace.
idstringrequiredID of the JSON template (a UUID). Pass it as jsonTemplateId to Get JSON template detail, Generate a structured document or Create a template. Built-in templates have the same ID in every workspace.
namestringrequirednullableName of the structured template as shown in Vetnio. null if it was saved without a name.
descriptionstringoptionalShort description of the template's purpose. Only built-in templates have one; the field is absent for templates created in the workspace.
curl "https://vetnio.com/api/v2/workspaces/demo-north-clinic/json-templates" \
-H "Authorization: Bearer $VETNIO_API_KEY"[
{
"id": "2a859133-0e04-4f63-88d2-aa0ee318cd8d",
"name": "Soap Note for Dog",
"description": "A template for a soap note for a dog."
},
{
"id": "3891bd52-61d4-41c6-89d0-49dab63d0a39",
"name": "Hälta",
"description": "Hältaundersökning för häst."
}
]GET/workspaces/{workspaceId}/json-templates/{jsonTemplateId}
Returns a JSON template with its full JSON Schema. jsonTemplateSchema.properties lists the fields a generated document will contain, keyed exactly as in the output, so you can map them to your own system or render a structured clinical note.
Available to any workspace member for the workspace's own and the built-in JSON templates. An ID from another workspace, or one that does not exist, returns 404. Requires a personal API key.
AcceptsPersonal key
workspaceIdstringrequiredIdentifier of the clinic (workspace), as returned by GET /workspaces. The key's user must be a member of the clinic, or an admin of the organization it belongs to.
jsonTemplateIdstringrequiredID of the JSON template (a UUID), from List JSON templates. Either one of this workspace's JSON templates or a built-in one; anything else returns 404.
idstringrequiredID of the JSON template (a UUID).
namestringrequirednullableName of the structured template as shown in Vetnio. null if it was saved without a name.
jsonTemplateSchemaobjectrequiredThe JSON Schema that generated documents follow: one property per field, with the instructions the AI uses to fill it.
typestringrequiredJSON Schema type of the document root. object for every structured template; a schema saved without a valid type is reported as object.
Default object
titlestringoptionalOptional schema title.
descriptionstringoptionalOptional description of the whole document.
propertiesobjectoptionalThe template's fields, keyed by the exact key that appears in generated documents. Each value is a JSON Schema property: type (string, number, integer, boolean, array or object), a description telling the AI what to extract and what to do when it is missing, and optionally title, enum (permitted answers, the Single choice and Multiple choice section types in Vetnio), items for arrays and nested properties for objects. Always present (possibly empty) when type is object.
requiredarray of stringsoptionalKeys of properties that generated documents must always contain. When a field is required but nothing relevant was said, generation leaves it empty rather than inventing a value.
enumarray of string | number | booleansoptionalPermitted values for the document root. Not used by structured templates in practice, which put enum on individual properties instead.
createdAtstringrequiredWhen the template was created, as an ISO-8601 UTC timestamp. Built-in templates report 1970-01-01T00:00:00.000Z.
curl "https://vetnio.com/api/v2/workspaces/demo-north-clinic/json-templates/2a859133-0e04-4f63-88d2-aa0ee318cd8d" \
-H "Authorization: Bearer $VETNIO_API_KEY"{
"id": "2a859133-0e04-4f63-88d2-aa0ee318cd8d",
"name": "Soap Note for Dog",
"jsonTemplateSchema": {
"type": "object",
"title": "Canine Medical Report",
"properties": {
"subjectiveInformation": {
"type": "object",
"properties": {
"reasonForVisit": {
"type": [
"string",
"null"
]
},
"symptoms": {
"type": [
"string",
"null"
]
},
"pastIllnesses": {
"type": [
"string",
"null"
]
},
"medications": {
"type": [
"string",
"null"
]
}
},
"required": [
"reasonForVisit",
"symptoms",
"pastIllnesses",
"medications"
],
"additionalProperties": false
},
"objectiveInformation": {
"type": "object",
"properties": {
"generalCondition": {
"type": [
"string",
"null"
]
},
"vitalSigns": {
"type": "object",
"properties": {
"temperature": {
"type": [
"number",
"null"
]
},
"pulse": {
"type": [
"number",
"null"
]
},
"respiratoryRate": {
"type": [
"number",
"null"
]
}
},
"required": [
"temperature",
"pulse",
"respiratoryRate"
],
"additionalProperties": false
},
"physicalExamination": {
"type": [
"string",
"null"
]
},
"laboratoryResults": {
"type": [
"string",
"null"
]
}
},
"required": [
"generalCondition",
"vitalSigns",
"physicalExamination",
"laboratoryResults"
],
"additionalProperties": false
},
"assessment": {
"type": "object",
"properties": {
"diagnosis": {
"type": [
"string",
"null"
]
},
"differentialDiagnoses": {
"type": "array",
"items": {
"type": [
"string",
"null"
]
}
},
"prognosis": {
"type": [
"string",
"null"
]
}
},
"required": [
"diagnosis",
"differentialDiagnoses",
"prognosis"
],
"additionalProperties": false
},
"plan": {
"type": "object",
"properties": {
"treatment": {
"type": [
"string",
"null"
]
},
"followUp": {
"type": [
"string",
"null"
]
},
"ownerInformation": {
"type": [
"string",
"null"
]
}
},
"required": [
"treatment",
"followUp",
"ownerInformation"
],
"additionalProperties": false
}
},
"required": [
"subjectiveInformation",
"objectiveInformation",
"assessment",
"plan"
],
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false
},
"createdAt": "1970-01-01T00:00:00.000Z"
}