Pular para o conteúdo principal

API Enhancements: Sub-IDs, Localization, and Health Tips

· Leitura de 2 minutos
Aden Forshaw
Founder/CEO of ThatAPICompany

We're constantly working to make The Dog API more robust and easier to integrate into your applications. Today, we're excited to announce a series of quality-of-life API enhancements that give you more control over your data and provide richer content for your users.

Here's a breakdown of the new features available now:

🏷️ Organizing Pets with Sub-IDs

Managing pets created by different users within your application just got a lot easier. We've introduced the sub_id field to the Pets API!

When creating or updating a pet, you can now pass a string to the sub_id field (such as your internal user ID). You can then filter the list of pets by this sub_id, making it incredibly simple to isolate and retrieve only the pets belonging to a specific user in your system.

# Creating a pet with a sub_id
curl -X POST -H "x-api-key: YOUR-API-KEY" \
-F "name=Rex" \
-F "sub_id=user-98765" \
https://api.thedogapi.com/v1/pets

# Retrieving pets for a specific user
curl -H "x-api-key: YOUR-API-KEY" \
"https://api.thedogapi.com/v1/pets?sub_id=user-98765"

🇬🇧 British English (en-gb) Localization

We're expanding our internationalization support! By popular demand, we have fully translated our extensive database of dog (and cat!) facts into British English (en-gb).

You can now specify your preferred locale when requesting facts, ensuring that the spelling and terminology feel natural to your UK audience (expect to see "colours" instead of "colors", and "behaviour" instead of "behavior"!).

💡 Categorized Health Tips

Providing actionable and personalized advice is a great way to engage your users. We've completely revamped our Health Tips feature.

Health tips are now strictly categorized, making it easier to query specific types of advice—whether it's regarding nutrition, exercise, grooming, or preventative care. These tips have been enriched to provide deeper, more personalized guidance based on a dog's specific physical characteristics and breed.

🌟 Breed Pro Features

For our Premium tier users, we've unlocked a new set of "Breed Pro" features. These endpoints return highly detailed, structured schemas containing extensive breed information that goes far beyond the standard physical traits.

These enhancements are available immediately across all supported endpoints. We hope these updates make building with The Dog API an even better experience!