data-export
customer-content

Export a workspace's structured (JSON) templates

Lists customer-owned templates for export, one page at a time, with metadata and a short-lived download link for each stored body. Pages are ordered by ascending template ID: pass nextCursor back as cursor until it is null. Download links expire after one hour (expiresAt); request the page again for fresh links. Vetnio's read-only default catalog templates are excluded; workspace-owned copies, including managed ones, are included. Read-only. Covers the workspace's own JSON output schemas, downloadable in their original JSON form. Requires admin rights in the workspace (workspace admin or superadmin, or an admin of an organization the clinic belongs to). Accepts a browser session or a personal API key; organization and workspace API keys (sk_org_…, sk_ws_…) get 403.

get/workspaces/{workspaceId}/data-export/json-templates

Request

  • Base URL
    https://vetnio.com/api/v2
  • URL
    https://vetnio.com/api/v2/workspaces/{workspaceId}/data-export/json-templates
  • Auth
    HTTP bearer

Path parameters

workspaceIdstring required

Identifier of the workspace (clinic) to export. The caller must be an admin of it, directly or as an admin of its organization.

Example:furunculotic-loud-chihuahua

Query parameters

cursorstring

Pagination cursor: the nextCursor value from the previous page. Omit for the first page, and keep the same owner and template category while paging. Items with an ID greater than the cursor are returned.

Example:5b0d7a3e-2c41-4f0e-9a77-1f3c9e6b8d20
limitinteger

Maximum number of templates per page, 1-50.

Example:20

Response

Successful response

nextCursorstring nullable required

Pass this value as cursor to fetch the next page. null when this is the last page.

expiresInSecondsnumber required

Lifetime of every contentUrl on this page, in seconds.

expiresAtstring date-time required

When the contentUrl links on this page stop working (ISO-8601 UTC). Download before then. Expiry does not affect the stored content.

Example response

{
  "expiresInSeconds": 3600,
  "expiresAt": "2026-09-28T09:15:00.000Z",
  "items": [
    {
      "id": "9c2e4f81-6a3b-4d5e-8f70-1b2c3d4e5f60",
      "workspaceId": "furunculotic-loud-chihuahua",
      "name": "Vaccination record",
      "creatorId": "0f8fad5b-d9cb-469f-a165-70867728950e",
      "createdAt": "2026-03-14T10:02:11.000Z",
      "artifact": {
        "contentUrl": "https://storage.example.com/templates/furunculotic-loud-chihuahua/5b0d7a3e-2c41-4f0e-9a77-1f3c9e6b8d20?X-Amz-Expires=3600&X-Amz-Signature=…",
        "contentType": "text/html",
        "size": 2048,
        "lastModified": "2026-09-28T08:15:00.000Z"
      }
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.