link

Search Link customers

Searches active (not removed) customers in the caller's Link tenant. Use exactly one search mode per request, otherwise the request fails with 400 BAD_REQUEST:

  • name — Link's own partial match on first or last name.
  • identifier — exact match on the customer identifier (for example a Swedish personal identity number). Vetnio also tries the common spellings with and without century digits and hyphen, and merges the results.
  • firstName and/or lastName — at least one with two or more characters. Vetnio queries Link with the longer term and keeps only customers whose first and last names contain the supplied values (case-insensitive).

Results are paginated with page (default 1) and perPage (1–100, default 100). total and sourceTotal count upstream Link rows, not filtered matches: the final field-aware match count is known only after all source pages are scanned, so keep requesting pages while hasNextPage is true to see every match.

get/workspaces/{workspaceId}/link/customers

Request

  • Base URL
    https://vetnio.com/api/v2
  • URL
    https://vetnio.com/api/v2/workspaces/{workspaceId}/link/customers
  • Auth
    HTTP bearer

Path parameters

workspaceIdstring required

Identifier 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.

Example:furunculotic-loud-chihuahua

Query parameters

namestring

Legacy search: partial, case-insensitive match on the customer's first or last name, performed by Link. Use exactly one search mode: name, identifier, or firstName/lastName.

Example:Morgan
identifierstring

Exact customer identifier, typically a Swedish personal identity number. Vetnio also tries the common spellings (with or without century digits and hyphen) and merges the results.

Example:19850101-1234
firstNamestring

Case-insensitive substring of the customer's first name. Combine with lastName; at least one of the two must have two or more characters.

Example:Alex
lastNamestring

Case-insensitive substring of the customer's last name.

Example:Morgan
pageinteger

1-based page of Link results.

Example:1
perPageinteger

Results per page, from 1 to 100.

Example:100

Response

Paginated customer search results.

totalinteger required

Same value as sourceTotal, kept for older clients. It is not the number of matches after Vetnio's own filtering.

sourceTotalinteger required

Number of customers Link reported for the upstream query. In identifier mode it is the sum over all identifier spellings searched.

pageinteger required

The page that was returned (1-based).

perPageinteger required

Page size used for the upstream Link query.

scannedCountinteger required

How many upstream Link rows have been covered up to and including this page.

hasNextPageboolean required

true when Link has more rows for this query. Request page + 1 to continue; a filtered page can be empty while this is true.

Example response

{
  "customers": [
    {
      "id": 54967922,
      "name": "Alex Morgan",
      "firstName": "Alex",
      "lastName": "Morgan",
      "identifier": "198501011234",
      "primaryEmail": "alex.morgan@example.com",
      "primaryPhone": "0701234567"
    }
  ],
  "total": 3,
  "sourceTotal": 3,
  "page": 1,
  "perPage": 100,
  "scannedCount": 3
}

Changes

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