PlaceDog API: free में placeholder dog images कैसे पाएँ
Key: No key needed · HTTPS: Yes · CORS: yes · Topic: Animals
PlaceDog एक सरल API है जो आपको रैंडम कुत्ते की तस्वीरें देता है। यह वेबसाइट या ऐप में placeholder images जोड़ने के लिए बहुत उपयोगी है।
Free में क्या मिलता है
- कुंजी की जरूरत नहीं है।
- सभी endpoints free हैं।
- free plan की limits official docs में देखें।
कैसे शुरू करें
- 1. आधिकारिक docs खोलें: https://place.dog
- 2. किसी भी endpoint पर request भेजें, जैसे /dog
- 3. JSON या image URL response पढ़ें।
Example
fetch('https://place.dog/dog')
.then(res => res.json())
.then(data => {
const img = document.createElement('img');
img.src = data.url; // image URL
document.body.appendChild(img);
})
.catch(err => console.error(err));यह उदाहरण /dog endpoint से एक रैंडम कुत्ते की तस्वीर लेता है और उसे पेज पर दिखाता है।
किस project में काम आएगा
- 1. वेबसाइट पर placeholder dog images डालना।
- 2. मोबाइल ऐप में random dog pictures दिखाना।
- 3. प्रोजेक्ट में fun image gallery बनाना।
- 4. छात्र प्रोजेक्ट में API integration demo करना।
ध्यान रखने वाली बातें
- कुंजी नहीं है, इसलिए secret रखने की जरूरत नहीं।
- response को cache करें ताकि बार-बार request न हो।
- CORS allowed है, इसलिए browser से सीधे fetch कर सकते हैं।
अक्सर पूछे जाने वाले सवाल
क्या यह API मुफ्त है?
हाँ, यह पूरी तरह से free है।
क्या API key चाहिए?
नहीं, auth फ़ील्ड खाली है, इसलिए key की जरूरत नहीं।
क्या कॉलेज प्रोजेक्ट में इस्तेमाल कर सकता हूँ?
बिल्कुल, यह शैक्षणिक और व्यक्तिगत प्रोजेक्ट दोनों के लिए उपयुक्त है।
इसी तरह की free APIs
- Cat Facts: Random cat facts
- Dog Facts: Random dog facts
- Dog Facts: Random facts of Dogs
- Dogs: Based on the Stanford Dogs Dataset
- FishWatch: Information and pictures about individual fish species
- HTTP Cat: Cat for every HTTP Status
Official docs · List: public-apis (MIT)