ज़रूरी है. लुकअप करने के लिए साइट टैग का नाम. ध्यान दें कि साइट टैग सिंगलटोन होते हैं और उनके यूनीक आईडी नहीं होते. फ़ॉर्मैट: प्रॉपर्टी/{property_id}/dataStreams/{stream_id}/globalSiteTag
किसी वेबसाइट से DataStream में डेटा भेजने के लिए, टैग के साथ रीड-ओनली रिसॉर्स. यह सिर्फ़ वेब के DataStream संसाधनों के लिए मौजूद है.
अगर एपीआई सही से जुड़ जाता है, ताे जवाब के मुख्य भाग में नीचे दिए गए स्ट्रक्चर शामिल होता है.
JSON के काेड में दिखाना
{"name": string,"snippet": string}
फ़ील्ड
name
string
सिर्फ़ आउटपुट के लिए. इस GlobalSiteTag संसाधन के लिए संसाधन का नाम. फ़ॉर्मैट: प्रॉपर्टी/{property_id}/dataStreams/{stream_id}/globalSiteTag का उदाहरण: "property/123/dataStreams/456/globalSiteTag"
snippet
string
इम्यूटेबल. JavaScript कोड स्निपेट को मापने के लिए, हर वेबपेज के हेड टैग में पहले आइटम के तौर पर चिपकाया जाना चाहिए.
[[["समझने में आसान है","easyToUnderstand","thumb-up"],["मेरी समस्या हल हो गई","solvedMyProblem","thumb-up"],["अन्य","otherUp","thumb-up"]],[["वह जानकारी मौजूद नहीं है जो मुझे चाहिए","missingTheInformationINeed","thumb-down"],["बहुत मुश्किल है / बहुत सारे चरण हैं","tooComplicatedTooManySteps","thumb-down"],["पुराना","outOfDate","thumb-down"],["अनुवाद से जुड़ी समस्या","translationIssue","thumb-down"],["सैंपल / कोड से जुड़ी समस्या","samplesCodeIssue","thumb-down"],["अन्य","otherDown","thumb-down"]],["आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eRetrieves the Site Tag, an immutable singleton, associated with a specific web stream.\u003c/p\u003e\n"],["\u003cp\u003eUtilizes an HTTP GET request with the format \u003ccode\u003eGET https://analyticsadmin.googleapis.com/v1alpha/{name=properties/*/dataStreams/*/globalSiteTag}\u003c/code\u003e to fetch the tag.\u003c/p\u003e\n"],["\u003cp\u003eRequires providing the web stream's name using the path parameter \u003ccode\u003ename\u003c/code\u003e in the format \u003ccode\u003eproperties/{property_id}/dataStreams/{stream_id}/globalSiteTag\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eReturns a JSON response containing the site tag's name and the JavaScript snippet for website implementation.\u003c/p\u003e\n"],["\u003cp\u003eNeeds authorization with either \u003ccode\u003ehttps://www.googleapis.com/auth/analytics.readonly\u003c/code\u003e or \u003ccode\u003ehttps://www.googleapis.com/auth/analytics.edit\u003c/code\u003e scope.\u003c/p\u003e\n"]]],["This outlines retrieving a web stream's Site Tag via a `GET` request to a specified URL. The required `name` parameter, formatted as `properties/{property_id}/dataStreams/{stream_id}/globalSiteTag`, identifies the Site Tag. The request body must be empty. The successful response, in JSON format, provides a `name` (resource identifier) and an immutable `snippet` (JavaScript code) for website data measurement. This can be achieved through authorization with either `analytics.readonly` or `analytics.edit` OAuth scopes.\n"],null,[]]