Method: albums.create
उपयोगकर्ता की Google Photos लाइब्रेरी में एल्बम बनाता है.
एचटीटीपी अनुरोध
POST https://photoslibrary.googleapis.com/v1/albums
यूआरएल में gRPC ट्रांसकोडिंग सिंटैक्स का इस्तेमाल किया गया है.
अनुरोध का मुख्य भाग
अनुरोध के मुख्य भाग में नीचे दिए गए स्ट्रक्चर वाला डेटा होता है:
JSON के काेड में दिखाना |
{
"album": {
object (Album )
}
} |
फ़ील्ड |
album |
object (Album )
ज़रूरी है. वह एल्बम जिसे बनाना है.
|
जवाब का मुख्य भाग
कामयाब रहने पर, जवाब के मुख्य हिस्से में Album
का नया इंस्टेंस शामिल किया जाता है.
अनुमति के दायरे
इसके लिए, OAuth के इनमें से किसी एक स्कोप की ज़रूरत होती है:
https://www.googleapis.com/auth/photoslibrary.appendonly
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-04-01 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-04-01 (UTC) को अपडेट किया गया."],[[["This documentation outlines the process for creating an album in a user's Google Photos library using the Photos Library API."],["The API request involves sending a POST request to a specific endpoint with a JSON body containing the album details."],["A successful response will return the newly created album object, including its properties and metadata."],["Authentication requires one of the provided OAuth scopes to grant necessary permissions."],["Beginning March 31, 2025, the scopes will change to limit functionality to media items created by the user's application, as outlined in the Photos APIs updates document."]]],["This document details creating albums in a user's Google Photos library via the API. It uses a `POST` request to `https://photoslibrary.googleapis.com/v1/albums`. The request body, formatted as JSON, requires an `album` object. Successful requests return the newly created `Album` instance. Authorization necessitates specific OAuth scopes: `photoslibrary`, `photoslibrary.appendonly`, or `photoslibrary.sharing`. Note that scopes will limit interactions with media items, created by the app, after March 31, 2025.\n"]]