Get Your Pet API Documentation

PLEASE NOTE: AS OF OCTOBER 1, 2020, WE WILL NO LONGER BE PROVIDING API KEYS UNTIL FURTHER NOTICE.


We expose a subset of our platform’s functionality to partners through a JSON-based Web API. Currently this functionality is limited to searching for and looking up the details of pets available for adoption on getyourpet.com.

Submitting a POST or GET request to an API endpoint requires the Content-Type http request header to be set to application/json. See the code examples under the subheading Using an API key.

To obtain an API key, provide one or more IP addresses to be whitelisted, or if you have any questions, please send an email to [email protected].

API Authentication and Authorization

Authentication to the API endpoint is accomplished in two ways. Requests will be authenticated if:

  1. they include a valid API key
  2. they originate from a whitelisted IP address

Different rate limits apply depending on which authentication method(s) are used. See Rate Limiting.

Using an API key

Obtain an API key by sending a request to [email protected]. Please include the following:

  • your name
  • the name and address of your organization
  • your phone number
  • the domain name of the web site or the name of the app that will use the API
  • a brief description of how you intend to use the API

You do not need to provide IP addresses to be whitelisted when making your initial request for an API key.

Once we provide you with an API key, include it with API requests by adding an HTTP request header with the name api-key.

C# Example

using (HttpClient httpClient = new HttpClient())
{
httpClient.DefaultRequestHeaders.Accept.Clear();
httpClient.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
httpClient.DefaultRequestHeaders.Add("api-key", "3A53B6621BC042669AC9129A48F727EF");
…
}

Java Example

HttpPost httpPost = new HttpPost("https://getyourpet.com/api/partnerpetsearch");
httpPost.setHeader("Content-Type", "application/json");
httpPost.setHeader("api-key", "3A53B6621BC042669AC9129A48F727EF");
…

Whitelisting IP Addresses

The maximum limit on the rate of requests is allowed when requests originate from an IP address that we have on file for your organization. See Rate Limiting.

To whitelist one or more IP addresses, send an email to [email protected].

Rate Limiting

Access to the API endpoint is unrestricted, but a limit on the rate of requests is imposed based on the presence of a valid API key and whether or not the requests originate from a whitelisted IP address.

API key is provided Originating IP address is whitelisted Requests are Limited to
No No 1 every 15 seconds
Yes No 1 per second
Yes Yes 100 per second

Note whitelisted IP addresses are only recognized as such in the presence of an API key (hence the No/Yes combination is not represented in the table above).

Internal Server Errors

If an internal server error is encountered, you can contact us and we can investigate. Please email the response body content showing LogCorrelationGuid and Message for each error to be investigated to [email protected].

The logs we use for investigation are only available for a limited time. If you’re interested in us doing an investigation, be sure to contact us as soon as possible after the internal server error is encountered.

Partner Pet Search API

The Partner Pet Search API consists of two methods. One performs a search, and the other provides a direct lookup by PetId.

This section describes the Search and Get by PetId endpoints, and also includes a data dictionary.

Search

The search endpoint allows you to perform a search based on, minimally, a zip code and a search radius. Additional filters can be applied, and the results are returned ordered by either adoption deadline (descending) or distance from the searched zip code (ascending). Results are provided in “pages,” 24 pets per page.

Endpoint Details

Method URL
POST
https://getyourpet.com/api/partnerpetsearch

 

Request Body Examples:

 

{
    "ZipCode": "20015",
    "SearchRadiusInMiles": 50,
    "PageNumber": 1
}

 

{
    "ZipCode": "20015",
    "SearchRadiusInMiles": 50,
    "PageNumber": 1,
    "PetType": "dog",
    "Gender": "female",
    "Colors": ["Black", "White"],
    "OrderBy": "distance"
}

 

Additional parameters may be included. See Parameters.

Parameters

In the list of parameters below, for those indicated as optional, pets returned in the response will only be limited by that filter when a non-null value is provided in the request.

Parameter Value(s) Description
ZipCode a valid 5-digit USPS zip code Required. The center of the area to search.
SearchRadiusInMiles [ 10, 500 ] Required. The radial distance outward from the zip code to be searched.
PageNumber [ 1, 50 ] Required. The page number of search results to be returned.
OrderBy “ad”, “adoptiondeadline”, “d”, “distance”, null Optional. When provided, the response will contain pets ordered by either each pet’s adoption deadline (descending) or the distance the pet is from ZipCode (ascending). When not provided, pets are ordered by adoption deadline (descending).
PetType “c”, “cat”, “cats”, “d”, “dog”, “dogs”, null Optional. When provided, the response will contain a specific type of pet.
Gender “f”, “female”, “females”, “m”, “male”, “males”, null Optional. When provided, the response will contain pets of a specific gender.
AgeYearsMin [ 0, 18 ] Optional. When provided, the response will contain pets at least the specified number of years old.
AgeYearsMax [ 1, 20 ] Optional. When provided, the response will contain pets no more than the specified number of years old.
ActivityLevelMin

ActivityLevelMax

“l”, “low”, “a”, “average”, “h”, “high”, null Optional. When provided, the response will contain pets in the activity level range specified by ActivityLevelMin and ActivityLevelMax. Either both must be provided, each with a non-null value, or neither provided, or both provided with a value of null.
GoodWithChildrenUnder5

GoodWithChildren5to10

GoodWithChildrenOver10

GoodWithCats

GoodWithDogs

“t”, “true”, “f”, “false”, null Optional. When provided, the response will contain pets that are good with children under 5 years old, children 5 to 10 years old, children over 10 years old, cats, and dogs. Logical “and” across non-null “GoodWith” parameters found in the request.
SizeMin

SizeMax

“xs”, “extrasmall”, “s”, “small”, “m”, “medium”, “l”, “large”, “xl”, “extralarge” Optional. When provided, the response will contain dogs in the size range specified by SizeMin and SizeMax. Either both must be provided, each with a non-null value, or neither provided, or both provided with a value of null.
CoatShort

CoatMedium

CoatLong

CoatHairless

CoatWire

CoatCurly

“t”, “true”, “f”, “false”, null Optional. When provided, the response will contain pets whose coat is short, medium, long, hairless, wire or curly. Logical “or” across non-null “Coat” parameters found in the request.
Claws “a”, “all”, “n”, “none”, “ro”, “rearonly”, “noro”, “noneorrearonly” Optional. When provided, the response will contain cats with claws, without claws, with only rear claws, or a combination of cats with no claws or with only rear claws.
Colors An array containing one or more of the following: “BLACK”, “Black”, “black”, “BLUE”, “Blue”, “blue”, “BRINDLE”, “Brindle”, “brindle”, “BROWN”, “Brown”, “brown”, “BUFF”, “Buff”, “buff”, “CHOCOLATE”, “Chocolate”, “chocolate”, “FAWN”, “Fawn”, “fawn”, “GOLD”, “Gold”, “gold”, “GREY”, “Grey”, “grey”, “HARLEQUIN”, “Harlequin”, “harlequin”, “LIVER”, “Liver”, “liver”, “MERLE”, “Merle”, “merle”, “PARTICOLOR”, “Particolor”, “particolor”, “RED”, “Red”, “red”, “SABLE”, “Sable”, “sable”, “SILVER”, “Silver”, “silver”, “TAN”, “Tan”, “tan”, “TRICOLOR”, “Tricolor”, “tricolor”, “WHEATON”, “Wheaton”, “wheaton”, “WHITE”, “White”, “white”, “YELLOW”, “Yellow”, “yellow” Optional. When provided, the response will contain pets whose color(s) match the color(s) provided.
NewlyAvailable “t”, “true”, “f”, “false”, null Optional. When provided, the response will contain pets whose profile has been published in the past 3 days.

Response

HTTP Status Code Example Response(s)
200 dog, minimally populated:
[
    {
        "PetId": 3635,
        "Name": "Sweetpea/ Big Boy",
        "PetType": "dog",
        "Breeds": null,
        "BreedsForDisplay": "unknown / mixed breed",
        "Gender": "male",
        "SpayedNeutered": true,
        "AgeYears": 3,
        "AgeMonths": 0,
        "ActivityLevel": "high",
        "GoodWith": null,
        "ZipCode": "92371",
        "Latitude": 34.4290417,
        "Longitude": -117.5261025,
        "DistanceInMiles": 6.0437137013199163,
        "DistanceInMilesForDisplay": "6 mi",
        "City": "Phelan",
        "State": "CA",
        "AdoptionDeadline": "2018-08-23",
        "PrimaryPhotoUrl": "https://getyourpet.com/photos/ae4a302d-e1ff-4245-9a2e-343075c77f05/pet-photo-9571.png",
        "AdditionalPhotoUrls": null,
        "HasVideo": false,
        "VideoContentType": null,
        "VideoUrl": null,
        "NewlyAvailable": false,
        "Size": "xl (over 75lbs.)",
        "Coat": "short",
        "Claws": null,
        "Color": "black",
        "Story": null,
        "ProfileUrl": "https://getyourpet.com/pet-profile/3635?acquisitionCode=APIXYZ"
    },
    …
]
dog, maximally populated:
[
    {
        "PetId": 58384,
        "Name": "Smudge",
        "PetType": "dog",
        "Breeds": [
            {
                "BreedId": 294187987,
                "BreedName": "Pit Bull Type"
            },
            {
                "BreedId": 56554472,
                "BreedName": "American Staffordshire Terrier"
            },
            {
                "BreedId": 42155205,
                "BreedName": "Bulldog"
            }
        ],
        "BreedsForDisplay": "Pit Bull Type, American Staffordshire Terrier, Bulldog",
        "Gender": "male",
        "SpayedNeutered": true,
        "AgeYears": 1,
        "AgeMonths": 1,
        "ActivityLevel": "low",
        "GoodWith": [
            "cats",
            "dogs",
            "children under 5",
            "children 5 to 10",
            "children over"
        ],
        "ZipCode": "29627",
        "Latitude": 34.5215816,
        "Longitude": -82.4969331,
        "DistanceInMiles": 6.0437137013199163,
        "DistanceInMilesForDisplay": "6 mi",
        "City": "Belton",
        "State": "SC",
        "AdoptionDeadline": "2018-07-26",
        "PrimaryPhotoUrl": "https://getyourpet.com/photos/6a31504c-2445-41cb-a3e6-f4b8a277e9d5/pet-photo-132709.png",
        "AdditionalPhotoUrls": null,
        "HasVideo": true,
        "VideoContentType": null,
        "VideoUrl": null,
        "NewlyAvailable": false,
        "Size": "m (21lbs. to 40lbs.)",
        "Coat": "short",
        "Claws": null,
        "Color": "black",
        "Story": null,
        "ProfileUrl": "https://getyourpet.com/pet-profile/58384?acquisitionCode=APIXYZ"
    },
    …
]
cat, minimally populated:
[
    {
        "PetId": 48308,
        "Name": "Sundae",
        "PetType": "cat",
        "Breeds": null,
        "BreedsForDisplay": "unknown / mixed breed",
        "Gender": "female",
        "SpayedNeutered": false,
        "AgeYears": 11,
        "AgeMonths": 3,
        "ActivityLevel": "low",
        "GoodWith": null,
        "ZipCode": "11221",
        "Latitude": 40.6903213,
        "Longitude": -73.9271644,
        "DistanceInMiles": 6.0437137013199163,
        "DistanceInMilesForDisplay": "6 mi",
        "City": "Brooklyn",
        "State": "NY",
        "AdoptionDeadline": "2018-08-13",
        "PrimaryPhotoUrl": "https://getyourpet.com/photos/29a6f45b-2583-495e-89e6-41ad169fb4b1/pet-photo-106404.png",
        "AdditionalPhotoUrls": null,
        "HasVideo": false,
        "VideoContentType": null,
        "VideoUrl": null,
        "NewlyAvailable": false,
        "Size": null,
        "Coat": "short",
        "Claws": "all",
        "Color": "black",
        "Story": null,
        "ProfileUrl": "https://getyourpet.com/pet-profile/48308?acquisitionCode=APIXYZ"
        },
        …
]
cat, maximally populated:
[
    {
        "PetId": 49481,
        "Name": "Momo",
        "PetType": "cat",
        "Breeds": [
            {
                "BreedId": 160893420,
                "BreedName": "Maine Coon"
            },
            {
                "BreedId": 137119476,
                "BreedName": "American / Domestic Bobtail"
            }
        ],
        "BreedsForDisplay": "Maine Coon, American / Domestic Bobtail",
        "Gender": "female",
        "SpayedNeutered": true,
        "AgeYears": 7,
        "AgeMonths": 0,
        "ActivityLevel": "average",
        "GoodWith": [
            "cats",
            "dogs",
            "children under 5",
            "children 5 to 10",
            "children over 10"
        ],
        "ZipCode": "85226",
        "Latitude": 33.2872209,
        "Longitude": -111.9403254,
        "DistanceInMiles": 6.0437137013199163,
        "DistanceInMilesForDisplay": "6 mi",
        "City": "Chandler",
        "State": "AZ",
        "AdoptionDeadline": "2018-07-30",
        "PrimaryPhotoUrl": "https://getyourpet.com/photos/63c82151-e0d5-49ce-b118-43c0f472027b/pet-photo-109421.png",
        "AdditionalPhotoUrls": null,
        "HasVideo": true,
        "VideoContentType": null,
        "VideoUrl": null,
        "NewlyAvailable": false,
        "Size": null,
        "Coat": "long",
        "Claws": "all",
        "Color": "black",
        "Story": null,
        "ProfileUrl": "https://getyourpet.com/pet-profile/49481?acquisitionCode=APIXYZ"
    },
    …
]
400 Invalid ZipCode and PetType example:
{
    "PetType": [
        "PetType is invalid (must be 'c', 'cat', 'cats', 'd', 'dog', 'dogs' or null)."
    ],
    "ZipCode": [
        "ZipCode is invalid (not a valid USPS zip code).”
    ]
}
401 Response Header:
WWW-Authenticate: Basic realm="The value of the api-key request header is invalid."
Response Body:
{
    "ErrorMessages": [
        "The value of the api-key request header is invalid."
    ]
}
429 Returned if the frequency of requests is too high. See Rate Limiting.
{
    "ErrorMessages": [
        "Too many requests."
    ]
}
500 Returned if there is an unexpected error occurs while processing the request. See Internal Server Errors.
{
    "LogCorrelationGuid": "07a0ce39-a838-4edf-8f1d-671236687497",
    "ErrorMessages": [
        "Unexpected exception (request: {"ZipCode":"20015","IpAddress":null,"SearchRadiusInMiles":50.0, "PetType":"dog","Gender":null,"AgeYearsMin":null,"AgeYearsMax":null,"ActivityLevelMin":null, "ActivityLevelMax":null,"GoodWithChildrenUnder5":null,"GoodWithChildren5to10":null,"GoodWithChildrenOver10":null, "GoodWithCats":null,"GoodWithDogs":null,"SizeMin":null,"SizeMax":null,"CoatShort":null,"CoatMedium":null, "CoatLong":null,"CoatHairless":null,"CoatWire":null,"CoatCurly":null,"NewlyAvailable":null,"Claws":null,"Colors":null,"OrderBy":null, "PageNumber":1})."
    ]
}

Get by PetId

The get by pet id endpoint allows you to get the details of a specific pet. The same format is used for the response here as is used in searching. The difference is that these additional fields are populated:

  • AdditionalPhotoUrls (populated if a pet’s profile has additional photos)
  • VideoContentType (populated if a pet’s profile has a video)
  • VideoUrl (populated if a pet’s profile has a video)
  • Story (always populated)

Endpoint Details

Method URL
GET
https://getyourpet.com/api/partnerpetsearch/PetId?zipCode=ZipCode

Examples:

https://getyourpet.com/api/partnerpetsearch/49481
https://getyourpet.com/api/partnerpetsearch/49481?zipCode=20015

Parameters

Parameter Value Description
PetId a valid PetId found in the response of to a search request Required. Indicates the pet whose details are to be returned.
ZipCode a valid 5-digit USPS zip code Optional. The zip code to use in computing DistanceInMiles. If omitted then DistanceInMiles will be null.

Response

HTTP Status Code Example Response
200 dog, minimally populated:
{
    "PetId": 3635,
    "Name": "Sweetpea/ Big Boy",
    "PetType": "dog",
    "Breeds": null,
    "BreedsForDisplay": "unknown / mixed breed",
    "Gender": "male",
    "SpayedNeutered": true,
    "AgeYears": 3,
    "AgeMonths": 0,
    "ActivityLevel": "high",
    "GoodWith": null,
    "ZipCode": "92371",
    "Latitude": 34.4290417,
    "Longitude": -117.5261025,
    "DistanceInMiles": null,
    "DistanceInMilesForDisplay": null,
    "City": "Phelan",
    "State": "CA",
    "AdoptionDeadline": "2018-08-23",
    "PrimaryPhotoUrl": "https://getyourpet.com/photos/ae4a302d-e1ff-4245-9a2e-343075c77f05/pet-photo-9571.png",
    "AdditionalPhotoUrls": null,
    "HasVideo": false,
    "VideoContentType": null,
    "VideoUrl": null,
    "NewlyAvailable": false,
    "Size": "xl (over 75lbs.)",
    "Coat": "short",
    "Claws": null,
    "Color": "black",
    "Story": "He is a very people friendly dog. Very playful and fun and goofy (not to mention clumsy!). Also quite protective.",
    "ProfileUrl": "https://getyourpet.com/pet-profile/3635?acquisitionCode=APIXYZ"
}
dog, maximally populated:
{
    "PetId": 58384,
    "Name": "Smudge",
    "PetType": "dog",
    "Breeds": [
        {
            "BreedId": 294187987,
            "BreedName": "Pit Bull Type"
        },
        {
            "BreedId": 56554472,
            "BreedName": "American Staffordshire Terrier"
        },
        {
            "BreedId": 42155205,
            "BreedName": "Bulldog"
        }
    ],
    "BreedsForDisplay": "Pit Bull Type, American Staffordshire Terrier, Bulldog",
    "Gender": "male",
    "SpayedNeutered": true,
    "AgeYears": 1,
    "AgeMonths": 1,
    "ActivityLevel": "low",
    "GoodWith": [
        "cats",
        "dogs",
        "children under 5",
        "children 5 to 10",
        "children over 10"
    ],
    "ZipCode": "29627",
    "Latitude": 34.5215816,
    "Longitude": -82.4969331,
    "DistanceInMiles": 6.0437137013199163,
    "DistanceInMilesForDisplay": "6 miles away",
    "City": "Belton",
    "State": "SC",
    "AdoptionDeadline": "2018-07-26",
    "PrimaryPhotoUrl": "https://getyourpet.com/photos/6a31504c-2445-41cb-a3e6-f4b8a277e9d5/pet-photo-132709.png",
    "AdditionalPhotoUrls": [
        "https://getyourpet.com/photos/6a31504c-2445-41cb-a3e6-f4b8a277e9d5/pet-photo-132711.png",
        "https://getyourpet.com/photos/6a31504c-2445-41cb-a3e6-f4b8a277e9d5/pet-photo-132713.png"
    ],
    "HasVideo": true,
    "VideoContentType": "video/mp4",
    "VideoUrl": "https://getyourpet.com/photos/6a31504c-2445-41cb-a3e6-f4b8a277e9d5/video-58384-334773a4-f99d-4577-a4ff-b4df5379b743.mp4",
    "NewlyAvailable": false,
    "Size": "m (21lbs. to 40lbs.)",
    "Coat": "short",
    "Claws": null,
    "Color": "black",
    "Story": "Smudge is a cuddly, calm, and quiet boy. He is very submissive and follows you around the house and the yard since he has so much love to give! He is housebroken, crate trained, and very easy to walk on and off a leash! He would make a good therapy animal due to his loving nature. He is also receptive to training.",
    "ProfileUrl": "https://getyourpet.com/pet-profile/58384?acquisitionCode=APIXYZ"
}
cat, minimally populated:
{
    "PetId": 48308,
    "Name": "Sundae",
    "PetType": "cat",
    "Breeds": null,
    "BreedsForDisplay": "unknown / mixed breed",
    "Gender": "female",
    "SpayedNeutered": false,
    "AgeYears": 11,
    "AgeMonths": 3,
    "ActivityLevel": "low",
    "GoodWith": null,
    "ZipCode": "11221",
    "Latitude": 40.6903213,
    "Longitude": -73.9271644,
    "DistanceInMiles": null,
    "DistanceInMilesForDisplay": null,
    "City": "Brooklyn",
    "State": "NY",
    "AdoptionDeadline": "2018-08-13",
    "PrimaryPhotoUrl": "https://getyourpet.com/photos/29a6f45b-2583-495e-89e6-41ad169fb4b1/pet-photo-106404.png",
    "AdditionalPhotoUrls": null,
    "HasVideo": false,
    "VideoContentType": null,
    "VideoUrl": null,
    "NewlyAvailable": false,
    "Size": null,
    "Coat": "short",
    "Claws": "all",
    "Color": "black",
    "Story": "Sundae loves when we pet her. We would be on the couch conversing and Sundae would come right next to us just to be in the fun. She would also meow at us and stare at us until we pet her.",
    "ProfileUrl": "https://getyourpet.com/pet-profile/48308?acquisitionCode=APIXYZ"
}
cat, maximally populated:
{
    "PetId": 49481,
    "Name": "Momo",
    "PetType": "cat",
    "Breeds": [
        {
            "BreedId": 160893420,
            "BreedName": "Maine Coon"
        },
        {
            "BreedId": 137119476,
            "BreedName": "American / Domestic Bobtail"
        }
    ],
    "BreedsForDisplay": "Maine Coon, American / Domestic Bobtail",
    "Gender": "female",
    "SpayedNeutered": true,
    "AgeYears": 7,
    "AgeMonths": 0,
    "ActivityLevel": "average",
    "GoodWith": [
        "cats",
        "dogs",
        "children under 5",
        "children 5 to 10",
        "children over 10"
    ],
    "ZipCode": "85226",
    "Latitude": 33.2872209,
    "Longitude": -111.9403254,
    "DistanceInMiles": 7.0649300988178565,
    "DistanceInMilesForDisplay": "7 miles away",
    "City": "Chandler",
    "State": "AZ",
    "AdoptionDeadline": "2018-07-30",
    "PrimaryPhotoUrl": "https://getyourpet.com/photos/63c82151-e0d5-49ce-b118-43c0f472027b/pet-photo-109421.png",
    "AdditionalPhotoUrls": [
        "https://getyourpet.com/photos/63c82151-e0d5-49ce-b118-43c0f472027b/pet-photo-109419.png",
        "https://getyourpet.com/photos/63c82151-e0d5-49ce-b118-43c0f472027b/pet-photo-109420.png"
    ],
    "HasVideo": true,
    "VideoContentType": "video/quicktime",
    "VideoUrl": "https://getyourpet.com/photos/63c82151-e0d5-49ce-b118-43c0f472027b/video-49481-5da9674d-c357-4bbb-bd21-32558e0871fd.MOV",
    "NewlyAvailable": false,
    "Size": null,
    "Coat": "long",
    "Claws": "all",
    "Color": "black",
    "Story": "Momo is a great cat. She is playful, always massaging (making biscuits), and is very well mannered. She loves to cuddle and is very smart. She gets along very well with our small dog. She also has a small little bob tail which is very cute!!",
    "ProfileUrl": "https://getyourpet.com/pet-profile/49481?acquisitionCode=APIXYZ"
}
400 Invalid ZipCode example:
{
    "ZipCode": [
        "ZipCode is invalid (not a valid USPS zip code)."
    ]
}
401 Response Header:
WWW-Authenticate: Basic realm="The value of the api-key request header is invalid."
Request Body:
{
    "ErrorMessages": [
        "The value of the api-key request header is invalid."
    ]
}
404 Returned if the PetId value in the request is not found.
{
    "PetId": [
        "PetId is invalid."
    ]
}
429 Returned if the frequency of requests is too high. See Rate Limiting.
{
    "ErrorMessages": [
        "Too many requests."
    ]
}
500 Returned if there is an unexpected error occurs while processing the request. See Internal Server Errors.
{
    "LogCorrelationGuid": "e00ce77d-ee4d-466d-b732-e775f9760d54",
    "ErrorMessages": [
        "Unexpected exception (petId = 999999, zipCode = 20015)."
    ]
}

Data Dictionary

Successful responses to both the Search and Get by PetId endpoints return information about pets available for adoption. Search returns a list of pets, while Get by PetId returns the information about a single pet. The table below gives some additional information about the information returned.

For string properties, the notation string(#) indicates the maximum length in the parenthetical. For example, string(50) indicates that strings returned for that property are limited to a maximum of 50 characters.

Most properties are returned by both Search and Get by PetId, but a handful of properties are only returned by Get by PetId. This is indicated in the Returned By column in the table below.

For properties that are populated conditionally, an explanation is provided in the description.

Pet

Property Data Type Returned By Populated Description
PetId int Both Always A strictly positive integer that is the unique key for identifying pets in the system.
AdoptionDeadline date Both Always The date by which the pet’s Guardian needs to find the pet a home. Formatted in JSON as yyyy-mm-dd.
NewlyAvailable bool Both Always Indicates if the pet has recently become available for adoption.
Name string(50) Both Always The pet’s name.
PetType string(3) Both Always The type of the pet. Values:

· cat
· dog

Gender string(6) Both Always The gender of the pet. Values:

· female
· male

Breeds array of Breed (see next table) Both Conditionally An array of up to 3 Breeds indicating the breed(s) of the pet. If the pet’s breed is unknown to its Guardian then this property will be null.
BreedsForDisplay string(60) for search results;
string(160) for single pet lookup
Both Always The breed(s) of the pet formatting using getyourpet.com display logic / rules. When Breeds is null then this will be “unknown / mixed breed”. When formatted for search results, at most one breed is included, with “mix” added if there are two or more breeds. For a single pet lookup this is a comma-delimited string of all breed names.
Size string(20) Both Conditionally The size of a dog (only populated for dogs; null for cats). Values:

· xs (up to 10lbs.)
· s (11lbs. to 20lbs.)
· m (21lbs. to 40lbs.)
· l (41lbs. to 75lbs.)
· xl (xl (over 75lbs.))

Coat string(8) Both Always The pet’s coat length / type. Values:

· short
· medium
· long
· hairless
· wire
· curly

Claws string(9) Both Conditionally The status of a cat’s claws (only populated for cats; null for dogs). Values:

· all
· rear only
· none

Color string(20) Both Always The pet’s color. Values:

· black
· black and silver
· black and tan
· black and white
· blue
· blue and white
· brindle
· brindle and white
· brown
· brown and white
· buff
· chocolate
· fawn
· fawn and white
· gold
· grey
· grey and white
· harlequin
· liver
· liver and white
· merle
· particolor
· red
· red and white
· sable
· silver
· tan
· tan and white
· tricolor
· wheaton
· yellow
· white
· blue point
· brown tabby
· brown and grey tabby
· buff tabby
· calico
· chocolate point
· dilute calico
· dilute tortiseshell
· flame point
· grey tabby
· orange
· orange and white
· torbie
· tortoiseshell
· tuxedo

AgeYears int Both Always The age of the pet.
AgeMonths int Both Always
SpayedNeutered bool Both Always Indicates if the pet is spayed (female pets) or neutered (male pets).
ActivityLevel string(7) Both Always The pet’s activity level. Values:

· low
· average
· high

GoodWith array of string(16) Both Conditional The types of children and other pets the pet is good to live with as indicated by the pet’s Guardian. If none apply, GoodWith will be null. Values:

· cats
· dogs
· children under 5
· children 5 to 10
· children over 10

PrimaryPhotoUrl string(100) Both Always The URL to the pet’s primary photo.
AdditionalPhotoUrls array of string(100) Get by PetId Conditional The URLs to the pet’s additional photos. If no additional photos, AdditionalPhotoUrls will be null.
HasVideo bool Both Always Indicates whether the pet’s Guardian has included a video in the pet’s profile.
VideoContentType string(25) Get by PetId Conditional The content type of the pet’s video (if the pet has a video). Values:

· video/mp4
· video/quicktime

VideoUrl string(150) Get by PetId Conditional The URL to the pet’s video (if the pet has a video).
Story string(400) Get by PetId Always A narrative provided by the current Guardian of the pet.
ProfileUrl string(100) Both Always The URL of the pet on getyourpet.com. Use this URL within your implementation to send a user to getyourpet.com where they’ll get to see the pet’s full profile and the option to connect with the pet’s Guardian. Note the value of the acquisitionCode query string parameter is generated based on your API key. Please do not make any assumptions about the format of this URL. We reserve the right to change its format at any time.
ZipCode string(5) Both Always The zip code where the pet lives. Guaranteed to be a valid, 5-digit USPS zip code.
City string(100) Both Always The city where the pet lives.
State string(2) Both Always The state where the pet lives.
Latitude double Both Always The latitude of the zip code where the pet lives.
Longitude double Both Always The longitude of the zip code where the pet lives.
DistanceInMiles double Both* Conditional The distance from the zip code in the request to the zip code where the pet lives.

* ZipCode is optional for Get by PetId. When ZipCode is not provided to Get by PetId then DistanceInMiles will be null.

DistanceInMiles ForDisplay string(6) for search results; string(20) for single pet lookup Both* Conditional DistanceInMiles formatted as “# mi” for search results and “# miles away” or “within 1 mile of ZZZZZ” for single pet lookup (where ZZZZZ is the zip code query string parameter value of a single pet lookup request).

* ZipCode is optional for Get by PetId. When ZipCode is not provided to Get by PetId then DistanceInMilesForDisplay will be null.

Breed

When returned, each breed is always fully populated with a BreedId and a BreedName.

Property Data Type Description
BreedId int A strictly positive integer that is the unique key for identifying breeds in the system.
BreedName string(50) The name of the breed.