Digitail API
Authentication
Get the logged-in User (Vet)
1min
code examples curl location 'https //developer digitail io/api/v1/auth/me' \\ \ header 'accept application/json' \\ \ header 'content type 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/auth/me", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));import requests import json url = "https //developer digitail io/api/v1/auth/me" payload = {} headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("get", url, headers=headers, data=payload) print(response text) \<?php $curl = curl init(); curl setopt array($curl, array( curlopt url => 'https //developer digitail io/api/v1/auth/me', curlopt returntransfer => true, curlopt encoding => '', curlopt maxredirs => 10, curlopt timeout => 0, curlopt followlocation => true, curlopt http version => curl http version 1 1, curlopt customrequest => 'get', curlopt httpheader => array( 'accept application/json', 'content type application/json' ), )); $response = curl exec($curl); curl close($curl); echo $response; responses // successful operation { "data" { "id" 1, "first name" "sarah", "last name" "connolly", "full name" "sarah connolly", "email" "vet\@example com", "name with title" "dvm sarah connolly", "video link" "", "profile picture" "https //dev 1 public digitail s3 eu central 1 amazonaws com/ionut/uploads/kxy8rlv2vluizyqwrcy2", "employee" { "id" 2, "chat user" {} }, "clinic" { "id" 766, "name" "animal hospital of all pets", "logo" "https //dev 1 public digitail s3 eu central 1 amazonaws com/ionut/uploads/kxy8rlv2vluizyqwrcy2", "preferences" { "language locale" "en us", "timezone" "america/new york", "date format" "m d y", "datetime format" "m d y g\ i a", "discount reason required" "" }, "hascliniclegalinfo" true, "hasonlinepaymentenabled" true, "chat user" { "name" "dvm sarah connolly", "uid" "e58ed763 928c 4155 bee9 fdbaaadc15f3", "is active" true, "is verified" true, "user" {} }, "care credit merchant" { "id" 1, "is active" true }, "default payment provider account" { "id" 1, "provider" "" } } } }// the request was invalid or contained data that was not allowed { "message" "requested filter(s) `filter1` are not allowed allowed filter(s) are date, query, " }// the authorization token is missing or invalid // the user is not authorized to perform the requested operation // the user has sent too many requests in a given amount of time ("rate limiting") max 200 requests per minute