Get a list of reminder protocol usage for a pet
1 min
code examples curl request get \\ \ url https //developer digitail io/api/v1/reminder protocol usages \\ \ header 'accept application/json'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var requestoptions = { method 'get', headers myheaders, redirect 'follow' }; fetch("https //developer digitail io/api/v1/reminder protocol usages", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));require "uri" require "json" require "net/http" url = uri("https //developer digitail io/api/v1/reminder protocol usages") https = net http new(url host, url port) https use ssl = true request = net http get new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" response = https request(request) puts response read body import requests import json url = "https //developer digitail io/api/v1/reminder protocol usages" payload = {} headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("get", url, headers=headers, data=payload) print(response text) responses // successful operation { "data" \[ { "id" 1, "clinic id" 1, "reminder protocol template id" 1, "record id" 1, "pet id" 1, "vet id" 1, "treatment type id" 1, "due date" "2022 09 28t00 00 00 000z", "administration date" "2022 09 28t00 00 00 000z", "clinic" {}, "due date utc" "2022 09 28t00 00 00 000z", "administration date utc" "2022 09 28t00 00 00 000z", "overwritten by" 1, "is active" true, "pet" { "id" 0, "nickname" "", "species" { "id" 0, "label" "" }, "breed" { "id" 0, "label" "", "species id" 0 }, "birthday" "", "gender" "", "hormonal status" 0, "profile picture" "" }, "protocol template" { "id" 1, "name" "reminder protocol template", "clinic id" 1, "is enabled" 1, "product categories" \[ { "id" 74, "product category id" 153, "name" "stupefiante", "products" \[ { "id" 36, "name" "vaccine" } ], "created at" "2023 07 11t15 24 15 000z" } ], "visit types" \[ { "id" 0, "visit type id" 0, "name" "", "services" \[ { "id" 0, "name" "" } ], "created at" "2023 07 11t07 41 16 000z" } ], "template overwrites" \[ { "id" 0, "name" "" } ], "template overwritten by" \[ { "id" 0, "name" "" } ], "intervals" \[ { "id" 0, "duration" 0, "unit" "", "time to in days" 0 } ], "created at" "2023 06 27t15 12 43 000000z", "updated at" "2023 06 27t15 12 43 000000z" }, "protocol usage items" \[ { "id" 1, "reminder protocol id" 1, "reminder protocol usage itemable id" 1, "reminder protocol usage itemable type" "app\\\\\\\models\\\\\\\treatment", "reminder protocol usage itemable" { "name" "product #9911", "batch number" "test batch 1123", "manufacturer" "test manufacturer", "rabic tag number" "rabic #12121", "expiration date" "2023 11 22t00 00 00 000z", "printed files" \[ { "id" 1, "name" "test certificate", "title" "test title", "real name" "test real name pdf", "printable file id" 1, "vet id" 6, "patient id" 2, "created at" "2023 09 14t11 26 45 000000z" } ] } } ] } ], "links" {}, "meta" {} }