प्रोटोकॉल गाइड

Google Sites के क्लासिक वर्शन का एपीआई, आपके ऐप्लिकेशन को Google साइट में मौजूद कॉन्टेंट को ऐक्सेस करने, उसे पब्लिश करने, और उसमें बदलाव करने की अनुमति देता है. इसके अतिरिक्त, आपका ऐप्लिकेशन हाल की गतिविधि की सूची का अनुरोध कर सकता है, संशोधन इतिहास ला सकता है और अटैचमेंट और फ़ाइलें अपलोड/डाउनलोड कर सकता है.

दर्शक

इस दस्तावेज़ में यह माना गया है कि आपको Google Data API प्रोटोकॉल के सामान्य आइडिया पता हैं.

यह दस्तावेज़ उन प्रोग्रामर के लिए है जो Google Sites के साथ इंटरैक्ट करने वाले क्लाइंट ऐप्लिकेशन लिखना चाहते हैं. यह रॉ एक्सएमएल/एचटीटीपी का इस्तेमाल करके, बेसिक Data API के इंटरैक्शन के उदाहरण के साथ पूरी जानकारी देता है. इस दस्तावेज़ को पढ़ने के बाद, तो हमारी क्लाइंट लाइब्रेरी का इस्तेमाल करके, एपीआई के साथ इंटरैक्ट करने के बारे में ज़्यादा जानने के लिए, भाषा के आधार पर उदाहरण देखने के लिए, बाईं ओर नेविगेशन बार में दी गई दूसरी गाइड पर जाएं.

इस गाइड में मौजूद कॉन्टेंट के रेफ़रंस के लिए, रेफ़रंस गाइड देखें.

अनुमति के अनुरोध

जब आपका ऐप्लिकेशन ऐसे उपयोगकर्ता डेटा का अनुरोध करता है जो सार्वजनिक नहीं है, तो उसमें अनुमति वाला टोकन शामिल होना चाहिए. इस टोकन से Google आपके ऐप्लिकेशन की पहचान भी करता है.

अनुमति देने के प्रोटोकॉल के बारे में जानकारी

अनुरोधों को अनुमति देने के लिए, आपके ऐप्लिकेशन में OAuth 2.0 का इस्तेमाल किया जाना चाहिए. अनुमति देने वाले दूसरे प्रोटोकॉल इस्तेमाल नहीं किए जा सकते. अगर आपका ऐप्लिकेशन Google से साइन इन करने की सुविधा इस्तेमाल करता है, तो अनुमति देने से जुड़े कुछ पहलुओं को Google आपके लिए खुद मैनेज करता है.

OAuth 2.0 से अनुरोधों को अनुमति देना

गैर-सार्वजनिक उपयोगकर्ता डेटा के लिए Google Sites Data API के अनुरोधों को पुष्टि किए गए किसी उपयोगकर्ता से अनुमति मिलनी चाहिए.

OAuth 2.0 के लिए अनुमति देने की प्रक्रिया या "तरीका" अलग-अलग हो सकता है. यह इस बात पर निर्भर करता है कि ऐप्लिकेशन किस तरह का है. सभी तरह के ऐप्लिकेशन के लिए नीचे दी गई सामान्य प्रक्रिया लागू होती है:

  1. ऐप्लिकेशन बनाने के बाद, उसे Google API (एपीआई) कंसोल का इस्तेमाल करके, रजिस्टर किया जाता है. इसके बाद, Google आपको क्लाइंट आईडी और क्लाइंट सीक्रेट जैसी जानकारी देगा.
  2. Google API कंसोल में Google Sites Data API चालू करें. (अगर एपीआई को 'API कंसोल' की सूची में नहीं जोड़ा गया है, तो यह चरण छोड़ दें.)
  3. जब आपके ऐप्लिकेशन को उपयोगकर्ता के डेटा को ऐक्सेस करने की ज़रूरत होती है, तब वह Google से, डेटा के खास लिंक का अनुरोध करता है.
  4. Google, उपयोगकर्ता को सहमति वाली स्क्रीन दिखाता है, जिसमें उनसे आपके ऐप्लिकेशन को उनके कुछ डेटा को ऐक्सेस करने की अनुमति मांगी जाती है.
  5. अगर उपयोगकर्ता इसकी अनुमति दे देता है, तो Google आपके ऐप्लिकेशन को कुछ समय के लिए इस्तेमाल किए जा सकने वाला ऐक्सेस टोकन देता है.
  6. आपका ऐप्लिकेशन, ऐक्सेस टोकन से उपयोगकर्ता के डेटा को ऐक्सेस करने का अनुरोध करता है.
  7. अगर Google को पता चलता है कि आपका अनुरोध और टोकन मान्य है, तो वह आपके ऐप्लिकेशन को अनुरोध किए गए डेटा का ऐक्सेस दे देता है.

कुछ तरीकों में दूसरे चरण भी शामिल हो सकते हैं, जैसे कि रिफ़्रेश टोकन इस्तेमाल करके, नया ऐक्सेस टोकन पाना. अलग-अलग तरह के ऐप्लिकेशन के लिए डेटा ऐक्सेस करने के तरीकों के बारे में ज़्यादा जानकारी पाने के लिए, Google का OAuth 2.0 दस्तावेज़ पढ़ें.

यहां Google Sites Data API के लिए, OAuth 2.0 के दायरे की जानकारी दी गई है:

https://sites.google.com/feeds/

OAuth 2.0 का इस्तेमाल करके, डेटा ऐक्सेस करने का अनुरोध करने के लिए, आपके ऐप्लिकेशन को अनुरोध के तरीके की जानकारी देनी होगी. साथ ही, वह जानकारी भी देनी होगी जो आपको ऐप्लिकेशन रजिस्टर करते समय, Google से मिली थी, जैसे कि क्लाइंट आईडी और क्लाइंट सीक्रेट.

वापस सबसे ऊपर जाएं

वर्शन तय करना

Google Sites Data API से किए जाने वाले हर अनुरोध में वर्शन 1.4 होना चाहिए. वर्शन नंबर बताने के लिए, GData-Version एचटीटीपी हेडर का इस्तेमाल करें:

GData-Version: 1.4

इसके अलावा, अगर एचटीटीपी हेडर सेट नहीं किए जा सकते, तो यूआरएल में v=1.4 को क्वेरी पैरामीटर के तौर पर सेट किया जा सकता है. हालांकि, जहां भी हो सके, एचटीटीपी हेडर को प्राथमिकता दी जाती है.

ध्यान दें: क्लाइंट लाइब्रेरी, सही वर्शन हेडर अपने-आप उपलब्ध कराती हैं. इसलिए, ऐसा न करें क्लाइंट लाइब्रेरी का इस्तेमाल करते समय, v=1.4 क्वेरी पैरामीटर का इस्तेमाल करें.

वापस सबसे ऊपर जाएं

साइट फ़ीड

साइट फ़ीड का इस्तेमाल, उन Google साइटों की सूची बनाने के लिए किया जा सकता है जिनका मालिकाना हक किसी उपयोगकर्ता के पास है या जिनके पास देखने की अनुमतियां हैं और मौजूदा साइट के टाइटल में भी बदलाव किया जा सकता है. G Suite डोमेन के लिए, इसका इस्तेमाल पूरी साइट में से एक को चुनें.

लिस्टिंग से जुड़ी साइटें

उपयोगकर्ता के पास जिन साइटों का ऐक्सेस है उनकी सूची बनाने के लिए, इस यूआरएल पर पुष्टि किया गया GET अनुरोध भेजें:

https://sites.google.com/feeds/site/domainName
फ़ीड पैरामीटरब्यौरा
domainName'site' या आपके G Suite से होस्ट किए गए डोमेन का डोमेन (जैसे, example.com).

इस जवाब में एक फ़ीड शामिल होगा, जिसमें साइटों की सूची होगी:

GET /feeds/site/domainName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

HTTP/1.1 200 OK

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
    xmlns:gAcl="http://schemas.google.com/acl/2007" xmlns:sites="http://schemas.google.com/sites/2008"
    xmlns:gs="http://schemas.google.com/spreadsheets/2006" xmlns:dc="http://purl.org/dc/terms"
    xmlns:batch="http://schemas.google.com/gdata/batch" xmlns:gd="http://schemas.google.com/g/2005"
    xmlns:thr="http://purl.org/syndication/thread/1.0">
<id>https://sites.google.com/feeds/site/site</id>
<updated>2009-12-02T17:47:34.406Z</updated>
<title>Site</title>
<link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml"
    href="https://sites.google.com/feeds/site/site"/>
<link rel="http://schemas.google.com/g/2005#post" type="application/atom+xml"
    href="https://sites.google.com/feeds/feeds/site/domainName"/>
<link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName"/>
<link rel="next" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/?start-index=2"/>
<generator version="1" uri="http://sites.google.com/">Google Sites</generator>
<openSearch:startIndex>1</openSearch:startIndex>
<entry gd:etag="W/&quot;CkUAQH4_eil7I2A9WxNaFk4.&quot;">
  <id>https://sites.google.com/feeds/site/site/myTestSite</id>
  <updated>2009-12-01T01:17:21.042Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-01T01:17:21.042Z</app:edited>
  <title>myTestSite</title>
  <summary/>
  <link rel="alternate" type="text/html" href="http://sites.google.com/site/myTestSite/"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/myTestSite"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myTestSite"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myTestSite"/>
  <sites:siteName>myTestSite</sites:siteName>
  <sites:theme>default</sites:theme>
</entry>
<entry gd:etag="W/&quot;DkQGQHczfA9WxNaFk4.&quot;">
  <id>https://sites.google.com/feeds/site/domainName/myOtherTestSite</id>
  <updated>2009-12-01T02:25:21.987Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-01T02:25:21.987Z</app:edited>
  <title>myOtherTestSite</title>
  <summary>A new site to hold memories</summary>
  <category scheme="http://schemas.google.com/sites/2008#tag" term="Memories Site"/>
  <link rel="alternate" type="text/html" href="http://sites.google.com/site/myOtherTestSite"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/myOtherTestSite"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <sites:siteName>myOtherTestSite</sites:siteName>
  <sites:theme>iceberg</sites:theme>
</entry>
...
</feed>

साइटों की सूची अंग्रेज़ी वर्णमाला के क्रम में दी जाती है.

नई साइटें बनाना

ध्यान दें: यह सुविधा सिर्फ़ G Suite डोमेन के लिए उपलब्ध है.

साइट फ़ीड में एचटीटीपी POST बनाकर, नई साइटों का प्रावधान किया जा सकता है. उदाहरण के लिए:

POST /feeds/site/example.com HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008">
  <title>Source Site</title>
  <summary>A new site to hold memories</summary>
  <sites:theme>slate</sites:theme>
</entry>

ऊपर दिया गया अनुरोध 'स्लेट' के साथ एक नई Google साइट बनाएगा थीम सेट करें example.com. यह साइट का यूआरएल होगा: http://sites.google.com/a/example.com/source-site/.

अगर साइट बन जाती है, तो सर्वर 201 Created की मदद से जवाब देगा. रिस्पॉन्स एंट्री में, सर्वर से जोड़े गए एलिमेंट शामिल होंगे. जैसे, साइट, साइट के ACL फ़ीड का एक लिंक, साइट का नाम, शीर्षक, और सारांश.

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl="http://schemas.google.com/acl/2007"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0"
    gd:etag="W/&quot;DEECR38l7I2A9WxNaF0Q.&quot;">
  <id>https://sites.google.com/feeds/site/example.com/source-site</id>
  <updated>2009-12-02T23:31:06.184Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-02T23:31:06.184Z</app:edited>
  <title>New Test Site</title>
  <summary>A new site to hold memories</summary>
  <link rel="alternate" type="text/html" href="http://sites.google.com/a/example.com/source-site/"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/example.com/source-site"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/source-site"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/source-site"/>
  <sites:siteName>source-site</sites:siteName>
  <sites:theme>slate</sites:theme>
</entry>

किसी साइट को कॉपी करना

ध्यान दें: यह सुविधा सिर्फ़ G Suite डोमेन के लिए उपलब्ध है.

किसी मौजूदा साइट की डुप्लीकेट कॉपी उसी तरह बनाई जा सकती है जिस तरह नई साइट बनाई जाती है. हालांकि, POST अनुरोध की ऐटम एंट्री में, एक <link> शामिल करें, जिसमें rel='source' को कॉपी करने के लिए, साइट के साइट फ़ीड पर पॉइंट किया गया हो. ऐसी कोई भी साइट जिसमें कॉपी की गई फ़ाइल में यह लिंक होगा. यहां किसी साइट का डुप्लीकेट बनाने का एक उदाहरण दिया गया है:

POST /feeds/site/example.com HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom">
  <link rel="http://schemas.google.com/sites/2008#source" type="application/atom+xml"
      href="https://sites.google.com/feeds/site/example.com/source-site"/>
  <title>Copy of New Test Site</title>
  <summary>A newer site to hold memories</summary>
</entry>

ऊपर दिया गया अनुरोध, http://sites.google.com/a/example.com/source-site/ पर मौजूद साइट को कॉपी करेगा.

अहम पॉइंट:

  • सिर्फ़ उन साइटों और साइट टेंप्लेट को कॉपी किया जा सकता है जिनका मालिकाना हक पुष्टि किए गए उपयोगकर्ता के पास है.
  • साइट टेंप्लेट को भी कॉपी किया जा सकता है. अगर "इस साइट को एक टेंप्लेट के रूप में पब्लिश करें", तो साइट को एक टेंप्लेट माना जाता है सेटिंग की जाँच की गई है.
  • अगर सोर्स साइट पर आपको मालिक के तौर पर शामिल किया गया है, तो आपके पास किसी दूसरे डोमेन से साइट को कॉपी करने का विकल्प होगा.

किसी साइट का मेटाडेटा अपडेट करना

किसी साइट का शीर्षक या खास जानकारी अपडेट करने के लिए, साइट में जोड़ी गई एंट्री के edit लिंक पर एचटीटीपी PUT भेजें. उदाहरण के लिए, नीचे दिए गए उदाहरण में, पिछली साइट के टाइटल को अपडेट करके New Test Site2 किया जाएगा. साथ ही, इसके लिए Newer description में ब्यौरा.

PUT /feeds/site/example.com/source-site HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl="http://schemas.google.com/acl/2007"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0"
    gd:etag="W/&quot;DEECR38l7I2A9WxNaF0Q.&quot;">
  <id>https://sites.google.com/feeds/site/example.com/source-site</id>
  <updated>2009-12-02T23:31:06.184Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-02T23:31:06.184Z</app:edited>
  <title>New Test Site2</title>
  <summary>Newer description</summary>
  <category scheme="http://schemas.google.com/sites/2008#tag" term="Category"/>
  <link rel="alternate" type="text/html" href="http://sites.google.com/a/example.com/source-site/"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/example.com/source-site"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/source-site"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/source-site"/>
  <sites:siteName>source-site</sites:siteName>
</entry>

श्रेणियां जोड़ना

ध्यान दें: यह सुविधा सिर्फ़ G Suite डोमेन के लिए उपलब्ध है.

आपकी डोमेन साइटों के लिए G Suite में श्रेणी मेटा डेटा शामिल है जो आपके डोमेन में साइटों को वर्गीकृत करने के लिए उपयोगी है. कैटगरी का मेटा डेटा जोड़ने या अपडेट करने के लिए, अपनी साइट एंट्री के edit लिंक पर एक एचटीटीपी PUT भेजें. इस लिंक में, category टैग शामिल होता है. नीचे दिए गए उदाहरण में बोल्ड लाइन देखें:

PUT /feeds/site/example.com/source-site HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl="http://schemas.google.com/acl/2007"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0"
    gd:etag="W/&quot;DEECR38l7I2A9WxNaF0Q.&quot;">
  <id>https://sites.google.com/feeds/site/example.com/source-site</id>
  <updated>2009-12-02T23:31:06.184Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-02T23:31:06.184Z</app:edited>
  <title>My Team website</title>
  <summary>This site contains contact information and a summary of major efforts our team owns</summary>
  <category scheme="http://schemas.google.com/sites/2008#tag" term="Team Site"/>
  <link rel="alternate" type="text/html" href="http://sites.google.com/a/example.com/my-team-site/"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/example.com/my-team-site"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/my-team-site"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/my-team-site"/>
  <sites:siteName>my-team-site</sites:siteName>
</entry>

यह उदाहरण एक मौजूदा साइट में बदलाव करता है और "टीम साइट" की कैटगरी जोड़ता है.

अतिरिक्त <category> टैग जोड़कर, कई कैटगरी भी जोड़ी जा सकती हैं. नीचे दिए गए उदाहरण में बोल्ड लाइन देखें:

PUT /feeds/site/example.com/my-team-site HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl="http://schemas.google.com/acl/2007"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0"
    gd:etag="W/&quot;DEECR38l7I2A9WxNaF0Q.&quot;">
  <id>https://sites.google.com/feeds/site/example.com/my-team-site</id>
  <updated>2009-12-02T23:31:06.184Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-02T23:31:06.184Z</app:edited>
  <title>My Team website</title>
  <summary>This site contains contact information and a summary of major efforts our team owns</summary>
  <category scheme="http://schemas.google.com/sites/2008#tag" term="Team Site/">
  <category scheme="http://schemas.google.com/sites/2008#tag" term="Legal Department/">
  <link rel="alternate" type="text/html" href="http://sites.google.com/a/example.com/my-team-site/"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/example.com/my-team-site"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/my-team-site"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/example.com/my-team-site"/>
  <sites:siteName>my-team-site</sites:siteName>
</entry>

इस उदाहरण में दो कैटगरी जोड़ी गई हैं: "टीम साइट" और "कानूनी विभाग"

वेब पता मैपिंग

वेब पते की मैपिंग से, Sites के उपयोगकर्ता अपने डोमेन को Google साइट पर मैप कर सकते हैं. उदाहरण के लिए, http://www.mydomainsite.com http://sites.google.com/a/domain.com/mysite की जगह इस्तेमाल किया जा सकता है. आपकी साइट कहां होस्ट की गई है, इसके आधार पर आप मैन्युअल रूप से के वेब पते को मैप किया जाता है. ज़्यादा जानकारी के लिए, हमारे सहायता केंद्र का लेख पढ़ें.

किसी साइट के वेब पते की मैपिंग फ़ेच की जा रही है

किसी साइट के लिए वेब पते की मैपिंग दिखाने के लिए, with-mappings=true पैरामीटर के साथ साइट एंट्री/फ़ीड फ़ेच करें:

GET /feeds/site/domainName?with-mappings=true HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

HTTP/1.1 200 OK

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
    xmlns:gAcl="http://schemas.google.com/acl/2007" xmlns:sites="http://schemas.google.com/sites/2008"
    xmlns:gs="http://schemas.google.com/spreadsheets/2006" xmlns:dc="http://purl.org/dc/terms"
    xmlns:batch="http://schemas.google.com/gdata/batch" xmlns:gd="http://schemas.google.com/g/2005"
    xmlns:thr="http://purl.org/syndication/thread/1.0">
...
<entry gd:etag="W/&quot;DkQGQHczfA9WxNaFk4.&quot;">
  <id>https://sites.google.com/feeds/site/domainName/myOtherTestSite</id>
  <updated>2009-12-01T02:25:21.987Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-01T02:25:21.987Z</app:edited>
  <title>myOtherTestSite</title>
  <summary>A new site to hold memories</summary>
  <link rel="alternate" type="text/html" href="http://sites.google.com/site/myOtherTestSite"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/myOtherTestSite"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <link rel='webAddressMapping' href='http://www.mysitemapping.com'>
  <link rel='webAddressMapping' href='http://www.mysitemapping2.com'>
  <link rel='webAddressMapping' href='http://www.myothermapping.org'>
</entry>
...
</feed>

मौजूदा मैपिंग, rel='webAddressMapping' के साथ link के तौर पर दिखेंगी. उदाहरण के लिए, ऊपर दिए गए उदाहरण में इस साइट पर ले जाने वाले तीन webAddressMapping हैं http://sites.google.com/site/myOtherTestSite.

वेब पता मैपिंग में बदलाव करना

ध्यान दें: सभी GET/POST/PUT ऑपरेशन में काम करते समय, with-mappings=true पैरामीटर होना चाहिए के लिए डिज़ाइन किया गया है. अगर पैरामीटर मौजूद नहीं है, तो साइट एंट्री (GET) में webAddressMapping को नहीं लौटाया जाएगा का इस्तेमाल करते हैं.

मैपिंग जोड़ने, अपडेट करने या मिटाने के लिए, नई साइटें बनाते समय ऐसा लिंक दें, उसे बदलें या हटाएं या किसी साइट का मेटाडेटा अपडेट करना. साइट फ़ीड के यूआरआई में with-mappings=true पैरामीटर शामिल करना ज़रूरी है. ध्यान दें: पते की मैपिंग अपडेट करने के लिए, आपको साइट का एडमिन होना चाहिए या G Suite से होस्ट की गई साइट के मामले में डोमेन एडमिन होना चाहिए.

उदाहरण के लिए, नीचे दिया गया अनुरोध, http://www.mysitemapping.com की मैपिंग को http://www.my-new-sitemapping.com में अपडेट करता है, और लिंक को एंट्री से बाहर रखकर, http://www.mysitemapping2.com को हटा देता है:

PUT /feeds/site/domainName?with-mappings=true HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry gd:etag="W/&quot;DkQGQHczfA9WxNaFk4.&quot;">
  <id>https://sites.google.com/feeds/site/domainName/myOtherTestSite</id>
  <updated>2009-12-01T02:25:21.987Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-01T02:25:21.987Z</app:edited>
  <title>myOtherTestSite</title>
  <summary>A new site to hold memories</summary>
  <link rel="alternate" type="text/html" href="http://sites.google.com/site/myOtherTestSite"/>
  <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/myOtherTestSite"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <link rel="edit" type="application/atom+xml" href="https://sites.google.com/feeds/site/domainName/myOtherTestSite"/>
  <link rel='webAddressMapping' href='www.my-new-sitemapping.com'>
  <!-- missing mapping2 will be deleted -->
  <link rel='webAddressMapping' href='http://www.myothermapping.org'>
</entry>

ध्यान दें, किसी साइट को बनाते/कॉपी करते समय भी वेब पते की मैपिंग को तय किया जा सकता है.

वापस सबसे ऊपर जाएं

गतिविधि फ़ीड

गतिविधि फ़ीड को फ़ेच करके, किसी साइट की हाल की गतिविधि (बदलाव) को फ़ेच किया जा सकता है. इसमें प्रत्येक प्रविष्टि गतिविधि फ़ीड में साइट में किए गए बदलाव की जानकारी होती है.

गतिविधि फ़ीड के बारे में क्वेरी करने के लिए, गतिविधि फ़ीड के यूआरएल पर एक एचटीटीपी GET भेजें:

https://sites.google.com/feeds/activity/domainName/siteName
फ़ीड पैरामीटरब्यौरा
domainName'site' या आपके G Suite से होस्ट किए गए डोमेन का डोमेन (जैसे, example.com).
siteNameआपकी साइट का वेबस्पेस नाम; जो साइट के यूआरएल में मौजूद है (जैसे, myCoolSite).

अनुरोध और जवाब का उदाहरण:

GET /feeds/activity/site/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

HTTP/1.1 200 OK

<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/">
<id>https://sites.google.com/feeds/activity/site/siteName</id>
<updated>2009-09-10T05:24:23.120Z</updated>
<title>Activity</title>
<link rel="alternate" type="text/html" href="http://sites.google.com/site/siteName/system/app/pages/recentChanges"/>
<link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml"
  href="https://sites.google.com/feeds/activity/site/siteName"/>
<link rel="self" type="application/atom+xml"
  href="https://sites.google.com/feeds/activity/site/siteName"/>
<generator version="1" uri="http://sites.google.com">Google Sites</generator>
<openSearch:startIndex>1</openSearch:startIndex>
<entry xmlns:gd="http://schemas.google.com/g/2005" gd:etag="W/&quot;CU4GQ3szfSl7ImA9WxNRFUg.&quot;">
<id>https://sites.google.com/feeds/activity/site/siteName/940375996952876062</id>
<updated>2009-09-10T03:38:42.585Z</updated>
<category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/sites/2008#deletion" label="deletion"/>
<title>home</title>
<summary type="xhtml">
  <div xmlns="http://www.w3.org/1999/xhtml">User deleted <a href="http://sites.google.com/site/siteName/home">home</a>
</div>
</summary>
<link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
  href="https://sites.google.com/feeds/revision/site/siteName/5409745539831916487"/>
<link rel="http://schemas.google.com/sites/2008#current" type="application/atom+xml"
  href="https://sites.google.com/feeds/content/site/siteName/5409745539831916487"/>
<link rel="self" type="application/atom+xml"
  href="https://sites.google.com/feeds/activity/site/siteName/940375996952876062"/>
<author>
  <name>User</name>
  <email>user@gmail.com</email>
</author>
</entry>
<entry xmlns:gd="http://schemas.google.com/g/2005" gd:etag="W/&quot;CU8DQn45fyl7ImA9WxNRFUg.&quot;">
  <id>https://sites.google.com/feeds/activity/site/siteName/7165439066235480082</id>
  <updated>2009-09-10T03:37:53.027Z</updated>
  <category scheme="http://schemas.google.com/g/2005#kind"
    term="http://schemas.google.com/sites/2008#edit" label="edit"/>
  <title>home</title>
  <summary type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">User2 edited <a href="http://sites.google.com/site/siteName/home">home</a>
  </div>
  </summary>
  <link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/site/siteName/5409745539831916487"/>
  <link rel="http://schemas.google.com/sites/2008#current" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/site/siteName/5409745539831916487"/>
  <link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/activity/site/siteName/7165439066235480082"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
</entry>
<entry xmlns:gd="http://schemas.google.com/g/2005" gd:etag="W/&quot;CU8AR3s4cSl7ImA9WxNRFUg.&quot;">
  <id>https://sites.google.com/feeds/activity/site/siteName/127448462987345884</id>
  <updated>2009-09-10T03:37:26.539Z</updated>
  <category scheme="http://schemas.google.com/g/2005#kind"
    term="http://schemas.google.com/sites/2008#creation" label="creation"/>
  <title>home</title>
  <summary type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">User3 created <a href="http://sites.google.com/site/siteName/home">home</a>
  </div>
  </summary>
  <link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/site/siteName/5409745539831916487"/>
  <link rel="http://schemas.google.com/sites/2008#current" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/site/siteName/5409745539831916487"/>
  <link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/activity/site/siteName/127448462987345884"/>
  <author>
    <name>User3</name>
    <email>user3@gmail.com</email>
  </author>
</entry>
</feed>

ध्यान दें: इस फ़ीड को ऐक्सेस करने के लिए ज़रूरी है कि आप साइट के सहयोगी या मालिक हों. आपको क्लाइंट को सही Authorization हेडर भेजना होगा और मिले टोकन का रेफ़रंस देना होगा अनुरोधों को अनुमति देना में जाएं.

वापस सबसे ऊपर जाएं

बदलाव फ़ीड

किसी भी कॉन्टेंट एंट्री के लिए बदलावों का इतिहास फ़ेच करने के लिए, एंट्री के बदलाव करने के लिंक पर एक एचटीटीपी GET भेजें:

https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID
फ़ीड पैरामीटरब्यौरा
domainName'site' या आपके G Suite से होस्ट किए गए डोमेन का डोमेन (जैसे, example.com).
siteNameआपकी साइट का वेबस्पेस नाम; जो साइट के यूआरएल में मौजूद है (जैसे, myCoolSite).

किसी दिए गए पेज/टिप्पणी/अटैचमेंट/सूची में मौजूद आइटम में बदलाव करने का लिंक ढूंढने के लिए, पहले इनसे एंट्री वापस पाएं सामग्री फ़ीड के लिए CONTENT_ENTRY_ID का इस्तेमाल कर रहा है. वापस लाई गई एंट्री में, संशोधन फ़ीड का <atom:link> शामिल होगा. उदाहरण के लिए:

<link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID"/>

अनुरोध और जवाब का उदाहरण:

GET /feeds/revision/domainName/siteName/CONTENT_ENTRY_ID HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

HTTP/1.1 200 OK

<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0">
<id>https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID</id>
<updated>2009-09-10T04:33:35.337Z</updated>
<title>Revisions</title>
<link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID"/>
<link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID"/>
<generator version="1" uri="http://sites.google.com">Google Sites</generator>
<openSearch:startIndex>1</openSearch:startIndex>
<entry gd:etag="W/&quot;CU4GQmA9WxNRFUg.&quot;">
  <id>https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID/2</id>
  <updated>2009-09-10T03:38:42.045Z</updated>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>Home</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">Latest content here</div>
  </content>
  <link rel="alternate" type="text/html"
    href="http://sites.google.com/domainName/siteName/CONTENT_ENTRY_ID/system/app/pages/admin/compare?wuid=wuid%3Agx%3A4f67c7&amp;rev1=2"/>
  <link rel="self" type="application/atom+xml" href="https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID/2"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
  <sites:pageName>home</sites:pageName>
  <sites:revision>2</sites:revision>
</entry>
<entry gd:etag="W/&quot;CU8DQ388eSl7ImA9WxNRFUg.&quot;">
  <id>https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID/1</id>
  <updated>2009-09-10T03:37:52.171Z</updated>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>Home</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">Older content here</div>
  </content>
  <link rel="alternate" type="text/html"
    href="http://sites.google.com/domainName/siteName/CONTENT_ENTRY_ID/system/app/pages/admin/compare?wuid=wuid%3Agx%3A4bc7&amp;rev1=1"/>
  <link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/revision/domainName/siteName/CONTENT_ENTRY_ID/1"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
  <sites:pageName>home</sites:pageName>
  <sites:revision>1</sites:revision>
</entry>
</feed>

ध्यान दें: इस फ़ीड को ऐक्सेस करने के लिए ज़रूरी है कि आप साइट के सहयोगी या मालिक हों. आपके क्लाइंट को सही Authorization हेडर भेजना होगा और मिले टोकन का रेफ़रंस देना होगा अनुरोधों को अनुमति देना में जाएं.

वापस सबसे ऊपर जाएं

कॉन्टेंट फ़ीड

कॉन्टेंट वापस लाया जा रहा है

कॉन्टेंट फ़ीड में साइट का मौजूदा कॉन्टेंट होता है. इस यूआरएल पर पुष्टि किया गया GET अनुरोध भेजें:

https://sites.google.com/feeds/content/domainName/siteName
फ़ीड पैरामीटरब्यौरा
domainName'site' या आपके G Suite से होस्ट किए गए डोमेन का डोमेन (जैसे, example.com).
siteNameआपकी साइट का वेबस्पेस नाम; जो साइट के यूआरएल में मौजूद है (जैसे, myCoolSite).

नतीजा एक ऐसा फ़ीड है जो साइट पर कॉन्टेंट एंट्री के पहले पेज की सूची बनाता है. फ़ीड की हर एंट्री में एक अलग तरह का कॉन्टेंट शामिल होगा, जैसे कि webpage, filecabinet, attachment, comment वगैरह. <category scheme="http://schemas.google.com/g/2005#kind"> एलिमेंट, एंट्री का टाइप तय करता है. रेफ़रंस गाइड देखें सहायता kind वैल्यू की सूची के लिए.

ध्यान दें: इस फ़ीड के लिए पुष्टि करने की ज़रूरत भी पड़ सकती है और नहीं भी; शेयर करने की अनुमतियों के आधार पर. अगर साइट सार्वजनिक नहीं है, तो आपके क्लाइंट को सही Authorization हेडर भेजना होगा (जैसा कि ऊपर दिए गए उदाहरण में दिखाया गया है) और अनुरोधों को अनुमति देना में मिले टोकन का रेफ़रंस लें.

GET /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

HTTP/1.1 200 OK

<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
  xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
  xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
  xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0">
<id>https://sites.google.com/feeds/content/domainName/siteName</id>
<updated>2009-08-31T01:39:20.286Z</updated>
<title>Content</title>
<link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/domainName/siteName"/>
<link rel="http://schemas.google.com/g/2005#post" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/domainName/siteName"/>
<link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/domainName/siteName"/>
<link rel="http://schemas.google.com/g/2005#batch" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/domainName/siteName/batch""/>
<link rel="next" type="application/atom+xml" href="https://sites.google.com/feeds/content/domainName/siteName/?start-index=2"/>
<generator version="1" uri="http://sites.google.com">Google Sites</generator>
<openSearch:startIndex>1</openSearch:startIndex>
<entry gd:etag="W/&quot;Ck8GQXk7fil7ImA9WxNSFk0.&quot;">
  <id>https://sites.google.com/feeds/content/domainName/siteName/7322156894</id>
  <updated>2009-08-30T02:53:40.706Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-30T02:53:40.706Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>Subpage</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">Page html content here</div>
  </content>
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/6492205817"/>
  <link rel="alternate" type="text"
      href="http://sites.google.com/site/siteName/subpage"/>
  <link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
      href="https://sites.google.com/feeds/revision/domainName/siteName/7322156894"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/7322156894"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/7322156894"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
  <sites:pageName>subpage</sites:pageName>
  <sites:revision>5</sites:revision>
</entry>
<entry gd:etag="W/&quot;CkMBQH08fCl7ImA9WxNSFk0.&quot;">
  <id>https://sites.google.com/feeds/content/domainName/siteName/5930635231</id>
  <updated>2009-08-30T02:47:31.374Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-30T02:47:31.374Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#listitem" label="listpage"/>
  <title/>
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/5930635231"/>
  <link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
      href="https://sites.google.com/feeds/revision/domainName/siteName/5930635231"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/5930635231"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/5930635231"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
  <sites:revision>1</sites:revision>
  <gs:field index="A" name="Issue/Feature">Implement cool feature X</gs:field>
  <gs:field index="B" name="Priority">P2</gs:field>
  <gs:field index="C" name="Owner"/>
  <gs:field index="D" name="Resolved"/>
</entry>
<entry gd:etag="W/&quot;AkYHQ3ozcCl7ImA9WxJaE08.&quot;">
  <id>https://sites.google.com/feeds/content/domainName/siteName/1265948545471894517</id>
  <updated>2009-08-03T19:35:32.488Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-03T19:35:32.488Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#filecabinet" label="filecabinet"/>
  <title>files</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">Page html content here</div>
  </content>
  <link rel="alternate" type="text"
      href="https://sites.google.com/domainName/siteName/files"/>
  <link rel="http://schemas.google.com/sites/2008#revision" type="application/atom+xml"
      href="https://sites.google.com/feeds/revision/domainName/siteName/12671894517"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/12671894517"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/12671894517"/>
  <author>
    <name>User</name>
    <email>user@gmail.com</email>
  </author>
  <gd:feedLink href="httpn://sites.google.com/feeds/content/domainName/siteName?parent=12671894517"/>
  <sites:pageName>files</sites:pageName>
  <sites:revision>1</sites:revision>
</entry>
...
</feed>

ध्यान दें: यह सिर्फ़ पहले कुछ नतीजे हैं. पूरा कॉन्टेंट फ़ीड देखने के लिए, फ़ॉलो करें फ़ीड का 'अगला' है लिंक:

<link rel="next" type="application/atom+xml" href="https://sites.google.com/feeds/content/domainName/siteName/?start-index=2"/>

ऐटम के सामान्य एलिमेंट की जानकारी के लिए, Google डेटा प्रोटोकॉल का संदर्भ देखें. क्लासिक Sites API में जिन एलिमेंट का इस्तेमाल किया जाता है उनके बारे में यहां बताया गया है. कुछ खास तरह की एंट्री में और प्रॉपर्टी होंगी (इनके बारे में नीचे बताया गया है) अन्य को नहीं. उदाहरण के लिए, listitem एंट्री में <gs:field> एलिमेंट हो सकता है, जबकि webpage एंट्री में नहीं.

एलिमेंटब्यौरा
<content ...>अंदरूनी टेक्स्ट, पेज का एचटीएमएल मुख्य हिस्सा होता है. कुछ एंट्री (जैसे कि अटैचमेंट) के लिए, इस एलिमेंट में फ़ाइल के बारे में बताने वाला एक src एट्रिब्यूट होगा.
<link rel="alternate" ...>Google Sites में पेज या आइटम से लिंक करें.
<link rel="http://schemas.google.com/sites/2008#revision" ...>href एट्रिब्यूट, एंट्री के रिविज़न फ़ीड को दिखाता है.
<link rel="http://schemas.google.com/sites/2008#parent" ...>href एट्रिब्यूट, एंट्री की पैरंट एंट्री पर ले जाता है.
<link rel="http://schemas.google.com/sites/2008#template" ...>href एट्रिब्यूट, एंट्री के टेंप्लेट पेज पर ले जाता है.
<category scheme="http://schemas.google.com/g/2005#kind" ...>एंट्री का टाइप label है.
<category term="http://schemas.google.com/g/2005#template" ...>label=template का मतलब है कि एंट्री एक टेंप्लेट है.
<gd:feedLink>href एट्रिब्यूट, एंट्री के पैरंट के बच्चों की ओर इशारा करता है.
<sites:pageName>पेज का वेबस्पेस नाम; पेज के यूआरएल में मौजूद नाम से मेल खाती हो.
<sites:revision>मौजूदा संशोधन नंबर.

कॉन्टेंट फ़ीड से जुड़ी क्वेरी के उदाहरण

कुछ स्टैंडर्ड Google Data API क्वेरी पैरामीटर का इस्तेमाल करके, कॉन्टेंट फ़ीड को खोजा जा सकता है जो खास तौर पर क्लासिक Sites API से जुड़े होते हैं. ज़्यादा जानकारी और काम करने वाले पैरामीटर की पूरी सूची के लिए, यहां देखें: रेफ़रंस गाइड.

खास एंट्री टाइप को फिर से पाना

किसी खास तरह की एंट्री को फ़ेच करने के लिए, kind पैरामीटर का इस्तेमाल करें. यह उदाहरण सिर्फ़ webpage एंट्री दिखाता है:

GET /feeds/content/domainName/siteName?kind=webpage

एक से ज़्यादा तरह की एंट्री दिखाने के लिए, हर kind को ',' से अलग करें. इस उदाहरण में, filecabinet और listpage एंट्री:

GET /feeds/content/domainName/siteName?kind=filecabinet,listpage

इसके अलावा, आपके पास kind पैरामीटर के बजाय, Google Data /-/category क्वेरी के लिए स्टैंडर्ड फ़ॉर्मैट का इस्तेमाल करने का विकल्प भी है:

GET /feeds/content/domainName/siteName/-/filecabinet|listpage

पेज टेंप्लेट वापस लाए जा रहे हैं

इस उदाहरण में सिर्फ़ template पेज दिखते हैं:

GET /feeds/content/domainName/siteName/-/template

सभी एंट्री टाइप दिखाने और template पेजों को शामिल करने के लिए, इसका इस्तेमाल करें:

GET /feeds/content/domainName/siteName/-/template|-template

पाथ के हिसाब से पेज वापस पाना

अगर आपको Google साइट में किसी पेज का रिलेटिव पाथ पता है, तो उस खास पेज को फ़ेच करने के लिए, path पैरामीटर का इस्तेमाल किया जा सकता है. यह उदाहरण http://sites.google.com/site/siteName/path/to/the/page:

GET /feeds/content/domainName/siteName?path=/path/to/the/page

किसी पैरंट पेज के तहत सभी एंट्री वापस लाना

अगर आपको किसी पेज का एंट्री आईडी पता है, तो इसकी सभी चाइल्ड एंट्री (अगर कोई हो) फ़ेच करने के लिए, parent पैरामीटर का इस्तेमाल करें:

GET /feeds/content/domainName/siteName?parent=CONTENT_ENTRY_ID

ड्राफ़्ट या मिटाई गई एंट्री शामिल हैं

ड्राफ़्ट या मिटाई गई एंट्री को शामिल करने के लिए, include-drafts या include-deleted पैरामीटर का इस्तेमाल करें. इस उदाहरण में कॉन्टेंट फ़ीड में ड्राफ़्ट की गई एंट्री शामिल हैं:

GET /feeds/content/domainName/siteName?include-drafts=true

पूरे टेक्स्ट से खोजें

किसी साइट के पूरे कॉन्टेंट में खोजने के लिए, पूरे टेक्स्ट वाली खोज जारी करने के लिए q पैरामीटर का इस्तेमाल करें:

GET /feeds/content/domainName/siteName?q=Text%20I%20am%20looking%20for

वापस सबसे ऊपर जाएं



कॉन्टेंट बनाना

एक एचटीटीपी POST भेजकर नया कॉन्टेंट (वेबपेज, लिस्टपेज, फ़ाइल कैबिनेट पेज, घोषणा पेज वगैरह) बनाया जा सकता है कॉन्टेंट फ़ीड में:

https://sites.google.com/feeds/content/domainName/siteName

इस्तेमाल किए जा सकने वाले एंट्री टाइप की सूची देखने के लिए, रेफ़रंस गाइड में kind पैरामीटर देखें.

नए आइटम / पेज बनाना

यह उदाहरण साइट के टॉप-लेवल के तहत एक नया webpage बनाता है, जिसमें पेज के मुख्य हिस्से के लिए कुछ XL शामिल हैं, और शीर्षक के शीर्षक को 'नए वेबपेज का टाइटल' पर सेट करता है:

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 328
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>New Webpage Title</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">HTML body goes here</div>
  </content>
</entry>

कामयाब होने पर, सर्वर 201 Created और एंट्री की कॉपी के साथ जवाब देता है.

कस्टम यूआरएल पाथ में आइटम/पेज बनाना

डिफ़ॉल्ट रूप से, पिछला उदाहरण यूआरएल के नीचे http://sites.google.com/domainName/siteName/new-webpage-title और 'नया वेबपेज टाइटल' का पेज टाइटल होगा. इसका मतलब है कि यूआरएल के लिए, <atom:title> को new-webpage-title के तौर पर नॉर्मलाइज़ किया गया है. किसी पेज के यूआरएल पाथ को अपनी पसंद के मुताबिक बनाने के लिए, <sites:pageName> एलिमेंट को सेट किया जा सकता है.

यह उदाहरण 'फ़ाइल स्टोरेज' के पेज हेडिंग के साथ एक नया filecabinet बनाता है, लेकिन पेज को बनाता है यूआरएल http://sites.google.com/domainName/siteName/files के तहत <sites:pageName> एलिमेंट तय करके.

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 393
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#filecabinet" label="filecabinet"/>
  <title>File Storage</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">A list of files is below.</div>
  </content>
  <sites:pageName>files</sites:pageName>
</entry>

किसी पेज के यूआरएल पाथ को नाम देने के लिए, सर्वर इन प्राथमिकता नियमों का इस्तेमाल करता है:

  1. <sites:pageName>, अगर मौजूद है. a-z, A-Z, 0-9, -, _ को पूरा करना ज़रूरी है.
  2. <atom:title>, pageName मौजूद न होने पर शून्य नहीं होना चाहिए. नॉर्मलाइज़ेशन के लिए, खाली सफ़ेद जगह में काट-छांट करके उसे छोटा करके '-' किया जाता है और a-z, A-Z, 0-9, -, _ से मेल न खाने वाले वर्ण निकालें.

उदाहरण के लिए, 'Custom_Page2' उसे सर्वर स्वीकार करेगा.

सबपेज बनाए जा रहे हैं

किसी पैरंट पेज के तहत सबपेज (बच्चे) बनाने के लिए, अपने<link rel="http://schemas.google.com/sites/2008#parent"> ऐटम की नई एंट्री. लिंक के href एट्रिब्यूट को पैरंट एंट्री के सेल्फ़ लिंक पर सेट करें.

यह उदाहरण एंट्री वाले पैरंट सूचना पेज पर, 'घोषणा' शीर्षक के साथ एक नया announcement बनाता है आईडी PARENT_ENTRY_ID. पेज के मुख्य हिस्से के लिए एक्सटर्नल कॉन्टेंट भी शामिल किया जाता है:

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 470
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#announcement" label="announcement"/>
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
      href="https://sites.google.com/feeds/content/domainName/siteName/PARENT_ENTRY_ID"/>
  <title>announcement</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">This weekend. My place.</div>
  </content>
</entry>

पेज के टेंप्लेट

पेज के टेंप्लेट बनाना

पेज टेंप्लेट बनाने की प्रोसेस, नए आइटम/पेज बनाने और सबपेज बनाना.अंतर यह है कि category में शब्द और लेबल को 'http://schemas.google.com/g/2005#template' पर सेट किया गया है और 'template' शामिल हैं.

इस उदाहरण से, नया webpage टेंप्लेट बनाया जा रहा है.

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 464
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <category scheme="http://schemas.google.com/g/2005#labels" term="http://schemas.google.com/g/2005#template" label="template"/>
  <title>Webpage Template</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">This weekend. My place.</div>
  </content>
</entry>

किसी टेंप्लेट से पेज बनाना

पेज टेंप्लेट बनाने की तरह ही, किसी टेंप्लेट से नया पेज इंस्टैंशिएट किया जा सकता है. इसके लिए, rel='http://schemas.google.com/sites/2008#template' के साथ <link> शामिल करना होगा पॉइंटिंग सेल्फ़ लिंक पर क्लिक करें.

इस उदाहरण में, मौजूदा पेज टेंप्लेट से एक नया filecabinet पेज बनाया गया है, जो फ़ाइल कैबिनेट को तय करता है.

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 464
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#filecabinet" label="filecabinet"/>
  <title>File Cabinet Page From Template</title>
  <link rel='http://schemas.google.com/sites/2008#template' type='application/atom+xml'
    href='https://sites.google.com/feeds/content/domainName/siteName/ENTRY_ID'/>
</entry>

ध्यान दें: <category> की जानकारी देने वाले टेंप्लेट के बावजूद, इसमें आपके एंट्री अब भी ज़रूरी है. यह भी ध्यान रखें कि <content> एलिमेंट को शामिल करने पर, सर्वर उसे अस्वीकार कर देगा.

फ़ाइलें अपलोड की जा रही हैं

Google Sites की तरह ही, यह एपीआई आपको फ़ाइल कैबिनेट पेजों और पैरंट पेजों में अटैचमेंट अपलोड करने की सुविधा देता है.

किसी पैरंट के लिए अटैचमेंट अपलोड करने के लिए, कॉन्टेंट फ़ीड के यूआरएल पर एचटीटीपी POST का अनुरोध भेजें:

https://sites.google.com/feeds/content/domainName/siteName

फ़ाइल के कॉन्टेंट को एक से ज़्यादा हिस्सों में बांटने के लिए, POST का मुख्य हिस्सा एक से ज़्यादा हिस्सों में होना चाहिए एक <atom:entry> जिसमें अटैचमेंट का मेटाडेटा है. <atom:entry> में रेफ़रंस होना चाहिए पैरंट एंट्री का सेल्फ़ लिंक. इससे यह तय किया जा सकता है कि अटैचमेंट कहां बनाया जाएगा. ज़्यादा जानकारी के लिए सबपेज बनाना देखें.

अटैचमेंट अपलोड हो रहे हैं

PARENT_ENTRY_ID आईडी वाले फ़ाइल कैबिनेट में PDF फ़ाइल अपलोड करने का एक उदाहरण यहां दिया गया है. अटैचमेंट बनाया जाएगा 'PDF फ़ाइल' शीर्षक के साथ और एक (वैकल्पिक) जानकारी, 'HR पैकेट'.

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 7221984
Content-Type: multipart/related; boundary=END_OF_PART
--END_OF_PART
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom">
  <category scheme="http://schemas.google.com/g/2005#kind"
          term="http://schemas.google.com/sites/2008#attachment" label="attachment"/>
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
        href="https://sites.google.com/feeds/content/domainName/siteName/PARENT_ENTRY_ID"/>
  <title>PDF File</title>
  <summary>HR packet</summary>
</entry>

--END_OF_PART
Content-Type: application/pdf

... pdf contents here ...

--END_OF_PART--

फ़ाइल अपलोड होने के बाद सर्वर, 201 Created के साथ-साथ अटैचमेंट की नई कॉपी के साथ जवाब देगा.

फ़ोल्डर में अटैचमेंट अपलोड किया जा रहा है

filecabinet में मौजूद फ़ोल्डर में कोई अटैचमेंट अपलोड करने के लिए, 'शब्द' वाली कैटगरी शामिल करें विशेषता को फ़ोल्डर के नाम पर सेट किया गया:

<category scheme="http://schemas.google.com/sites/2008#folder" term="FolderName">

वेब अटैचमेंट

वेब अटैचमेंट खास तरह के अटैचमेंट होते हैं. मूल रूप से, वे वेब पर मौजूद दूसरी फ़ाइलों के लिंक होती हैं जिसे अपनी फ़ाइल कैबिनेट सूची में जोड़ा जा सकता है. यह सुविधा 'यूआरएल से फ़ाइल जोड़ें' जैसी है अपलोड करने का तरीका जानना होगा.

ध्यान दें: वेब अटैचमेंट सिर्फ़ फ़ाइल कैबिनेट के तहत बनाए जा सकते हैं. इन्हें दूसरी तरह के पेजों पर अपलोड नहीं किया जा सकता.

इस उदाहरण से, आईडी FILECABINET_ENTRY_ID से रेफ़रंस लिए जाने वाले फ़ाइल कैबिनेट के तहत, webattachment बन जाता है. इसका टाइटल और जानकारी (ज़रूरी नहीं) 'GoogleLogo' पर सेट है और 'अच्छे रंग'.

POST /feeds/content/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Type: application/atom+xml
Content-Length: 531

<entry xmlns="http://www.w3.org/2005/Atom">
  <category scheme="http://schemas.google.com/g/2005#kind"
          term="http://schemas.google.com/sites/2008#webattachment" label="webattachment"/>
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
        href="https://sites.google.com/feeds/content/domainName/siteName/FILECABINET_ENTRY_ID"/>
  <title>GoogleLogo</title>
  <summary>nice colors</summary>
  <content type="image/gif" src="http://www.google.com/images/logo.gif"></content>
</entry>

POST, उपयोगकर्ता के फ़ाइल कैबिनेट में एक लिंक बनाता है, जो 'http://www.google.com/images/logo.gif' पर इमेज पर ले जाता है.

वापस सबसे ऊपर जाएं



कॉन्टेंट अपडेट किया जा रहा है

किसी भी पेज के मेटाडेटा (टाइटल, pageName वगैरह) और पेज के कॉन्टेंट में बदलाव करने के लिए, edit लिंक पर जाने के लिए, सिर्फ़ एक PUT अनुरोध करें. अनुरोध के मुख्य हिस्से में, अपडेट किए गए पेज के बारे में जानकारी देने वाली ऐटम एंट्री होनी चाहिए. इस नियम का अपवाद एक अटैचमेंट एंट्री है, जिसमें एंट्री का इस्तेमाल सिर्फ़ अटैचमेंट के मेटाडेटा को अपडेट करने के लिए किया जा सकता है. अटैच की गई फ़ाइल का कॉन्टेंट बदलने के लिए, सिर्फ़ रॉ डेटा को PUT अनुरोध के मुख्य हिस्से के तौर पर अटैचमेंट का edit-media लिंक. मेटाडेटा और अटैच की गई फ़ाइल के कॉन्टेंट, दोनों को एक साथ अपडेट करने के लिए, MIME एक से ज़्यादा हिस्सों में अनुरोध.

यह पक्का करने के लिए कि आपका अपडेट किसी दूसरे क्लाइंट के बदलावों को ओवरराइट नहीं करता है, मूल एंट्री की ETag वैल्यू शामिल करें. ऐसा करने के लिए एचटीटीपी If-Match हेडर में ETag वैल्यू देकर या ओरिजनल एंट्री की gd:etag एट्रिब्यूट को अपडेट की गई एंट्री. ओरिजनल एंट्री की ETag वैल्यू पता करने के लिए, <entry> एलिमेंट के gd:etag एट्रिब्यूट की जांच करें. मीडिया एंट्री के लिए, मीडिया का ETag, edit-media लिंक के gd:etag एट्रिब्यूट में उपलब्ध हो सकता है.

यदि आप प्रविष्टि को अपडेट करना चाहते हैं, भले ही आपके द्वारा इसे पुनर्प्राप्त करने के बाद किसी और ने उसे अपडेट किया हो या नहीं, तो इसका उपयोग करें If-Match: * और ETag शामिल न करें. ईटैग के बारे में ज़्यादा जानकारी के लिए, देखें Google Data API की रेफ़रंस गाइड.

किसी आइटम का मेटाडेटा या एचटीएमएल कॉन्टेंट अपडेट करना

किसी एंट्री के मेटाडेटा या एचटीएमएल कॉन्टेंट को अपडेट करने के लिए, एंट्री के edit लिंक पर एक एचटीटीपी PUT भेजें.

listpage एंट्री (जिसे इसके आईडी ENTRY_ID से दिखाया जाता है) को इन बदलावों के साथ अपडेट करने का एक उदाहरण नीचे दिया गया है:

  • इसके टाइटल में बदलाव करके, 'अपडेट किया गया कॉन्टेंट' किया गया
  • अपडेट किया गया एचटीएमएल कॉन्टेंट
  • सूची के पहले कॉलम का टाइटल, 'मालिक' पर अपडेट कर दिया गया है
  • पेज के यूआरएल पाथ में <sites:pageName> एलिमेंट की वजह से बदलाव हुआ है
PUT /feeds/content/domainName/siteName/ENTRY_ID
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 816
Content-Type: application/atom+xml

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008"
    xmlns:gs="http://schemas.google.com/spreadsheets/2006" xmlns:gd="http://schemas.google.com/g/2005"
    gd:etag="W/&quot;CEEBRn0ymA9WxJWEUw.&quot;">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#listpage" label="listpage"/>
  <title>Updated Title</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">Updated Content</div>
  </content>
  <gs:worksheet name="listpage"/>
  <gs:header row="1"/>
  <gs:data startRow="2">
    <gs:column index="A" name="Owner"/>
    <gs:column index="B" name="Decription"/>
    <gs:column index="C" name="Completed"/>
  </gs:data>
  <sites:pageName>newPagePath</sites:pageName>
</entry>

ध्यान दें: एंट्री में (जैसा कि सर्वर के ज़रिए दिखाया गया है) में ऊपर दिए गए उदाहरण से ज़्यादा एलिमेंट होंगे.

किसी अटैचमेंट का कॉन्टेंट बदलना

नीचे एक अटैचमेंट के कॉन्टेंट को बदलने का उदाहरण दिया गया है, लेकिन इसके मेटाडेटा में कोई बदलाव नहीं किया गया है. अनुरोध में नया कॉन्टेंट शामिल है, अटैचमेंट एंट्री के edit-media लिंक का इस्तेमाल किया गया है.

PUT /feeds/media/content/domainName/siteName/ATTACHMENT_ENTRY_ID
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Length: 70581
Content-Type: application/msword

... doc contents here ...

अटैचमेंट मेटाडेटा और कॉन्टेंट अपडेट किया जा रहा है

नीचे किसी अटैचमेंट के मेटाडेटा और उसके कॉन्टेंट को एक साथ अपडेट करने का एक उदाहरण दिया गया है. अटैचमेंट का नाम अपडेट कर दिया जाएगा 'नए टाइटल' में और इसकी सामग्री को .zip फ़ाइल की सामग्री से बदल दिया जाएगा. अनुरोध में नई फ़ाइल कॉन्टेंट शामिल है, इसलिए अटैचमेंट एंट्री के edit-media लिंक का इस्तेमाल किया गया है.

ध्यान दें कि मेटाडेटा के लिए ETag शामिल करने से, मीडिया कॉन्टेंट के लिए भी एक इंप्लिसिट If-Match मिलता है, क्योंकि मीडिया कॉन्टेंट की वजह से मेटाडेटा का ETag बदल जाता है.

PUT /feeds/media/content/domainName/siteName/ATTACHMENT_ENTRY_ID
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
Content-Type: multipart/related; boundary="END_OF_PART"
--END_OF_PART
Content-Type: application/atom+xml

<?xml version='1.0' encoding='UTF-8'?>
<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gd="http://schemas.google.com/g/2005" gd:etag="BxAaTxRZAyp7ImBq">
  <link rel="http://schemas.google.com/sites/2008#parent" type="application/atom+xml"
        href="https://sites.google.com/feeds/content/domainName/siteName/ATTACHMENT_ENTRY_ID"/>
  <title>New Title</title>
</entry>

--END_OF_PART
Content-Type: application/zip

... zip contents here ...

--END_OF_PART

वापस सबसे ऊपर जाएं



कॉन्टेंट मिटाया जा रहा है

Google साइट से कोई आइटम हटाने के लिए, सबसे पहले एंट्री फिर से पाएं, फिर DELETE भेजें प्रविष्टि के edit URL के लिए अनुरोध. यह वही यूआरएल है जिसका इस्तेमाल किसी आइटम के मेटाडेटा या एचटीएमएल कॉन्टेंट को अपडेट करने के लिए किया जाता है.

DELETE /feeds/content/domainName/siteName/ENTRY_ID
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>
If-Match: <ETag or * here>

अगर एंट्री मिटा दी गई है, तो सर्वर एचटीटीपी 200 OK के साथ जवाब देता है.

अगर आपको यह पक्का करना है कि कोई ऐसी एंट्री न मिट जाए जिसे आपके वापस आने के बाद किसी दूसरे क्लाइंट ने बदल दिया है, तो एचटीटीपी If-Match हेडर, जिसमें ओरिजनल एंट्री की ETag वैल्यू शामिल है. ओरिजनल एंट्री की ETag वैल्यू इसके हिसाब से तय की जा सकती है <entry> एलिमेंट के gd:etag एट्रिब्यूट की जांच की जा रही है.

यदि आप प्रविष्टि हटाना चाहते हैं तो भले ही आपके द्वारा इसे पुनर्प्राप्त करने के बाद किसी और ने अपडेट किया हो या नहीं, तो इसका उपयोग करें If-Match: * और ETag शामिल न करें. (इस मामले में, आपको एंट्री मिटाने से पहले उसे वापस पाने की ज़रूरत नहीं है.)

ई-टैग के बारे में ज़्यादा जानकारी के लिए, Google Data API से जुड़ी रेफ़रंस गाइड देखें.

वापस सबसे ऊपर जाएं



अटैचमेंट डाउनलोड किए जा रहे हैं

अटैचमेंट एंट्री मिल जाने के बाद, एंट्री के लिए पुष्टि किया गया एचटीटीपी GET भेजकर फ़ाइल डाउनलोड की जा सकती है <content> के सोर्स का लिंक. PDF के कॉन्टेंट के लिंक का उदाहरण:

<content type="application/pdf"
  src="http://502377765-a-google-com-s-sites.googlegroups.com/feeds/media/content/domainName/siteName/678942036"/>

वापस सबसे ऊपर जाएं

ACL फ़ीड

शेयर करने की अनुमतियों (एसीएल) के बारे में खास जानकारी

एसीएल फ़ीड की हर एसीएल एंट्री किसी खास इकाई की ऐक्सेस भूमिका दिखाती है. इसमें उपयोगकर्ता, उपयोगकर्ताओं का ग्रुप, डोमेन, या डिफ़ॉल्ट ऐक्सेस (जो एक सार्वजनिक साइट है). एंट्री सिर्फ़ उन इकाइयों के लिए दिखाई जाएंगी जिनके पास साफ़ तौर पर ऐक्सेस है. एक एंट्री दिखेगी हर ईमेल पते के लिए, "ऐक्सेस वाले लोग" सेक्शन में पैनल पर जाएं. इसलिए, डोमेन के एडमिन नहीं दिखाए जाएंगे, भले ही उनके पास किसी साइट का इंप्लिसिट ऐक्सेस हो.

भूमिकाएं

रोल एलिमेंट, किसी इकाई के ऐक्सेस लेवल के बारे में बताता है. gAcl:role एलिमेंट की चार वैल्यू हो सकती हैं:

  • रीडर — दर्शक (रीड ओनली ऐक्सेस के बराबर).
  • लेखक — सहयोगी (पढ़ने/लिखने का ऐक्सेस) के बराबर है.
  • मालिक — आम तौर पर, साइट का एडमिन (पढ़ने/लिखने के ऐक्सेस के बराबर).

स्कोप

स्कोप एलिमेंट उस इकाई के बारे में बताता है जिसके पास यह ऐक्सेस लेवल है. gAcl:scope एलिमेंट पांच तरह के हो सकते हैं:

  • user — ईमेल पते की वैल्यू, जैसे कि "user@gmail.com".
  • group — Google ग्रुप का ईमेल पता, जैसे कि "group@domain.com".
  • domain — G Suite डोमेन नाम, जैसे कि "domain.com".
  • न्योता — एक ऐसा उपयोगकर्ता जिसे साइट पर आने का न्योता दिया गया है, लेकिन उसे अभी तक साइट के लिए एसीएल में नहीं जोड़ा गया है. (अगर gdata 1.3 या इससे पहले के वर्शन के बारे में बताया गया है, तो उपलब्ध नहीं होता.)
  • डिफ़ॉल्ट — "डिफ़ॉल्ट" टाइप का सिर्फ़ एक स्कोप हो सकता है, जिसमें कोई वैल्यू नहीं होती (उदाहरण के लिए, <gAcl:scope type="default">). यह खास स्कोप, डिफ़ॉल्ट रूप से किसी भी उपयोगकर्ता के पास मौजूद ऐक्सेस को कंट्रोल करता है एक सार्वजनिक साइट पर.

ध्यान दें: डोमेन में gAcl:role की वैल्यू नहीं हो सकती "मालिक" के तौर पर सेट करें वे सिर्फ़ पाठक या लेखक हो सकते हैं.

"न्योता" के बारे में जानकारी दायरा.

जब ACL में ऐसे एक या उससे ज़्यादा उपयोगकर्ता जोड़े जाते हैं जिनके पास पहले से Google खाता नहीं है, तो एपीआई न्योते का दायरा दिखाता है. एपीआई, एम्बेड किए गए टोकन वाला यूआरएल दिखाता है. आपको यह टोकन, उन लोगों को उपलब्ध कराना होगा जिन्हें आपने न्योता भेजा है, ताकि वे न्योता स्वीकार कर सकें.

न्योता भेजने के इस तरीके का इस्तेमाल करके, Google से बाहर के उपयोगकर्ताओं को यह जानकारी नहीं दी जा सकती है कि उन्हें कौनसा ईमेल पता इस्तेमाल करना है. जब तक उपयोगकर्ता एम्बेड किए गए टोकन वाले न्योते के यूआरएल पर क्लिक करते हैं, तब तक वे किसी भी ईमेल पते का इस्तेमाल करके, ऐक्सेस पाने के लिए साइन अप कर सकते हैं. इसके अलावा, न्योता स्वीकार करने के लिए एक से ज़्यादा उपयोगकर्ता इस यूआरएल का इस्तेमाल कर सकते हैं. इसलिए, किसी एक उपयोगकर्ता या उपयोगकर्ताओं के ग्रुप को न्योता भेजते समय यह यूआरएल काम आ सकता है.

ध्यान दें: "न्योता" स्कोप सिर्फ़ gdata वर्शन 1.4 और उसके बाद वाले वर्शन में उपलब्ध है. अगर आपने साफ़ तौर पर 1.3 या इससे पहले के वर्शन तय किए हैं, तो यह तरीका काम नहीं करेगा.

ACL फ़ीड फिर से प्राप्त की जा रही है

ACL फ़ीड का इस्तेमाल किसी साइट की शेयर करने की अनुमतियों को कंट्रोल करने के लिए किया जा सकता है और इसे नीचे दिए गए यूआरआई के ज़रिए ऐक्सेस किया जा सकता है:

https://sites.google.com/feeds/acl/site/domainName/siteName
फ़ीड पैरामीटरब्यौरा
domainName'site' या आपके G Suite से होस्ट किए गए डोमेन का डोमेन (जैसे, example.com).
siteNameआपकी साइट का वेबस्पेस नाम; जो साइट के यूआरएल में मौजूद है (जैसे, myCoolSite).

इस बात पर ध्यान देना ज़रूरी है कि साइट फ़ीड की हर एंट्री में इस फ़ीड का लिंक होता है:

 <link rel="http://schemas.google.com/acl/2007#accessControlList" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName"/>

किसी साइट की शेयर करने की अनुमतियां फिर से पाने के लिए, ACL फ़ीड यूआरआई को GET भेजें और एचटीटीपी:

GET /feeds/acl/site/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

सर्वर, 200 OK और ACL एंट्री की फ़ीड के साथ जवाब देगा:

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
    xmlns:gAcl="http://schemas.google.com/acl/2007" xmlns:sites="http://schemas.google.com/sites/2008"
    xmlns:gs="http://schemas.google.com/spreadsheets/2006" xmlns:dc="http://purl.org/dc/terms"
    xmlns:batch="http://schemas.google.com/gdata/batch" xmlns:gd="http://schemas.google.com/g/2005"
    xmlns:thr="http://purl.org/syndication/thread/1.0">
<id>https://sites.google.com/feeds/acl/site/domainName/siteName</id>
<updated>2009-12-03T22:01:05.963Z</updated>
<category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
<title>Acl</title>
<link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml"
    href="https://sites.google.com/feeds/acl/site/domainName/siteName"/>
<link rel="http://schemas.google.com/g/2005#post" type="application/atom+xml"
    href="https://sites.google.com/feeds/acl/site/domainName/siteName"/>
<link rel="self" type="application/atom+xml"
    href="https://sites.google.com/feeds/acl/site/domainName/siteName"/>
<generator version="1" uri="http://sites.google.com">Google Sites</generator>
<openSearch:startIndex>1</openSearch:startIndex>
<entry>
  <id>https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserA%40gmail.com</id>
  <updated>2009-12-03T22:01:05.963Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T22:01:05.963Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserA%40google.com"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserA%40google.com"/>
  <gAcl:scope type="user" value="userA@google.com"/>
  <gAcl:role value="owner"/>
</entry>
<entry>
  <id>https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserB%40gmail.com</id>
  <updated>2009-12-03T22:01:05.963Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T22:01:05.963Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserB%40gmail.com"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserB%40gmail.com"/>
  <gAcl:scope type="user" value="userB@gmail.com"/>
  <gAcl:role value="writer"/>
</entry>
<entry>
  <id>https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserC%40gmail.com</id>
  <updated>2009-12-03T22:01:05.963Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T22:01:05.963Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserC%40gmail.com"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3AuserC%40gmail.com"/>
  <gAcl:scope type="user" value="userC@gmail.com"/>
  <gAcl:role value="reader"/>
</entry>
...
</feed>

वापस सबसे ऊपर जाएं

साइट शेयर करना

ACL फ़ीड को GET, POST, और PUT अनुरोध स्वीकार किए जाते हैं. ACL फ़ीड में नई भूमिका शामिल करने के लिए, साइट के ACL फ़ीड में एक POST अनुरोध जारी करें.

ध्यान दें: कुछ एसीएल सिर्फ़ तब शेयर किए जा सकते हैं, जब डोमेन कॉन्फ़िगर किया गया हो ऐसी अनुमतियां देने के लिए (उदाहरण के लिए, अगर G Suite डोमेन के लिए डोमेन के बाहर शेयर करने की सुविधा चालू हो वगैरह).

इस उदाहरण में, साइट पर एक नया सहयोगी (लेखक) जोड़ा गया है:

POST /feeds/acl/site/domainName/siteName HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl='http://schemas.google.com/acl/2007'>
  <category scheme='http://schemas.google.com/g/2005#kind'
    term='http://schemas.google.com/acl/2007#accessRule'/>
  <gAcl:role value='writer'/>
  <gAcl:scope type='user' value='new_writer@example.com'/>
</entry>

शामिल करने पर, 201 Created और नई एंट्री दिखती हैं:

<entry>
  <id>https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com</id>
  <updated>2009-12-03T22:01:05.963Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T22:01:05.963Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com"/>
  <gAcl:role value='writer'/>
  <gAcl:scope type='user' value='new_writer@example.com'/>
</entry>

"न्योता" के ज़रिए उपयोगकर्ताओं को न्योता देना दायरा

अगर ऐसे उपयोगकर्ताओं को जोड़ा जाता है जिनके पास Google खाते नहीं हैं, तो एपीआई एक ऐसा यूआरएल भेजता है जिसे आपको उन उपयोगकर्ताओं को उपलब्ध कराना होगा जिन्हें न्योता भेजना है. यूआरएल पर क्लिक करने के बाद, वह मौजूदा खाते से साइन इन करके या नया खाता बनाकर, साइट को ऐक्सेस कर सकेगा.

न्योता स्वीकार होने पर, 201 Created के साथ एक नई एंट्री दिखती है. इसमें वह यूआरएल शामिल होता है जिसे आपको उपयोगकर्ता को पास करना होगा:

<entry>
  <id>https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_invite%40example.com</id>
  <updated>2009-12-03T22:01:05.963Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-12-03T22:01:05.963Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/acl/2007#accessRule"/>
  <link rel="http://schemas.google.com/sites/2008#invite" type="text/html"href="domainName/siteName?invite=inviteToken"/>
  <link rel="self" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_invite%40example.com"/>
  <link rel="edit" type="application/atom+xml"
      href="https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_invite%40example.com"/>
  <gAcl:role value='writer'/>
  <gAcl:scope type='invite' value='new_invite%40example.com'/>
</entry>

ग्रुप और डोमेन लेवल पर शेयर करना

एक उपयोगकर्ता के साथ साइट शेयर करने की तरह ही, आप उस साइट को Google ग्रुप या G Suite डोमेन. ज़रूरी scope वैल्यू नीचे दी गई हैं.

किसी ग्रुप के ईमेल पते के साथ शेयर करना:

<gAcl:scope type="group" value="group@example.com"/>

पूरे डोमेन के साथ शेयर करना:

<gAcl:scope type="domain" value="example.com"/>

डोमेन स्तर पर शेयर करना सिर्फ़ G Suite डोमेन के लिए काम करता है और सिर्फ़ उस डोमेन के लिए काम करता है जिस पर साइट होस्ट की गई है. उदाहरण के लिए, http://sites.google.com/a/domain1.com/siteA पर पूरी साइट का ऐक्सेस सिर्फ़ Domains1.com के साथ शेयर किया जा सकता है, डोमेन2.com के साथ नहीं. जो साइटें G Suite डोमेन (उदाहरण के लिए, http://sites.google.com/site/siteB) पर होस्ट नहीं की गई हैं, वे डोमेन को न्योता नहीं भेज सकतीं.

शेयर करने की अनुमतियों में बदलाव किया जा रहा है

ACL एंट्री अपडेट करने के लिए, ज़रूरत के हिसाब से एंट्री में बदलाव करें औरPUT का edit लिंक है, जो एक <link> एलिमेंट, जिसका 'rel' एट्रिब्यूट को 'बदलाव करें' पर सेट किया गया है. पिछले उदाहरण के लिए, वह लिंक यह है:

<link rel='edit' type='application/atom+xml'
    href='https://sites.google.com/feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com'/>

नीचे दिया गया स्निपेट, new_writer@gmail.com की भूमिका को 'रीडर' में बदल देता है:

PUT /feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

<entry xmlns="http://www.w3.org/2005/Atom" xmlns:gAcl='http://schemas.google.com/acl/2007'>
  <category scheme='http://schemas.google.com/g/2005#kind' term='http://schemas.google.com/acl/2007#accessRule'/>
  <gAcl:role value='reader'/>
  <gAcl:scope type='user' value='new_writer@gmail.com'/>
</entry>

शेयर करने की अनुमतियां हटाई जा रही हैं

इस उपयोगकर्ता की अनुमतियां हटाने के लिए, उसी edit लिंक पर DELETE अनुरोध जारी करें जिसका इस्तेमाल PUT अनुरोध के लिए किया गया था:

DELETE /feeds/acl/site/domainName/siteName/user%3Anew_writer%40example.com HTTP/1.1
Host: sites.google.com
GData-Version: 1.4
Authorization: <your authorization header here>

सर्वर, 200 OK में जवाब देगा.

वापस सबसे ऊपर जाएं

खास विषय

किसी फ़ीड या एंट्री को फिर से वापस पाना

अगर आपको किसी ऐसे फ़ीड या एंट्री को फिर से वापस लाना है जिसे आपने पहले वापस लिया था, तो यह जानकारी देकर परफ़ॉर्मेंस को बेहतर बनाया जा सकता है सूची या एंट्री भेजने के लिए सर्वर का इस्तेमाल सिर्फ़ तब करें, जब पिछली बार जब आपने इसे फ़ेच किया था, तब से अब तक इसमें बदलाव हुआ हो.

इस तरह की शर्तों के साथ डेटा वापस पाने के लिए, एक एचटीटीपी GET अनुरोध भेजें, जिसमें एक एचटीटीपी हो If-None-Match हेडर. हेडर में, सूची या एंट्री का ETag बताएं. यह ETag आपको <feed> एलिमेंट या <entry> एलिमेंट का gd:etag एट्रिब्यूट.

साइट फ़ीड का इस्तेमाल करने का उदाहरण:

GET /feeds/site/domainName/myOtherTestSite/
GData-Version: 1.4
If-None-Match: W/"Ck8GQXk7fil7ImA9WxNSFk0."

जब सर्वर को यह अनुरोध मिलता है, तो यह जांच करता है कि आपने जिस आइटम का अनुरोध किया है उसका ETag है या नहीं आपके द्वारा बताया गया ETag है. अगर ईटैग मेल खाता है, तो आइटम में बदलाव नहीं होता है और सर्वर एचटीटीपी 304 Not Modified स्टेटस कोड या एचटीटीपी 412 Precodition Failed स्टेटस कोड. वे दोनों स्थिति कोड से पता चलता है कि आपने जो आइटम पहले ही वापस लाया है वह अप-टू-डेट है.

अगर ई-टैग मेल नहीं खाता है, तो इसका मतलब है कि पिछली बार आपके अनुरोध करने के बाद, आइटम में बदलाव किए गए हैं. साथ ही, सर्वर उस आइटम को दिखाता है.

ई-टैग के बारे में ज़्यादा जानकारी के लिए, Google Data API से जुड़ी रेफ़रंस गाइड देखें.

बैच प्रोसेसिंग

बैच रिक्वेस्ट से आपके क्लाइंट को हर ऑपरेशन को अलग-अलग सबमिट करने के बजाय एक ही अनुरोध में कई ऑपरेशन करने की सुविधा मिलती है.

सर्वर अनुरोध किए गए ज़्यादा से ज़्यादा बदलाव करेगा और स्थिति की ऐसी जानकारी दिखाएगा जिसका इस्तेमाल आप कर सकते हैं हर संचालन की सफलता या असफलता का आकलन कर सकते हैं. Google Data API में बैच प्रोसेसिंग के बारे में ज़्यादा जानकारी के लिए, Google Data API के साथ बैच प्रोसेसिंग देखें

बैच फ़ीड में मौजूद हर कार्रवाई में एक &lt;id&gt; एलिमेंट होता है. इसमें इंसर्ट करने की कार्रवाइयां शामिल नहीं होती हैं. यह एलिमेंट अनुरोध यूआरएल की तरह ही है. आम तौर पर, इसका इस्तेमाल कॉन्टेंट फ़ीड को अपडेट करने, मिटाने या क्वेरी करने के लिए किया जाता है. उदाहरण के लिए, अगर कोई बदलाव अपडेट किया जा रहा है, तो उस एंट्री के लिए &lt;id&gt; को edit लिंक पर सेट करें जिसकी शिकायत की गई है. इसका इस्तेमाल टारगेट एंट्री की पहचान करने के लिए किया जाता है. नई एंट्री में &lt;id&gt; एलिमेंट नहीं होते, क्योंकि वे अभी तक नहीं बनाए गए हैं. इसके बजाय आप &lt;batch:id&gt; में स्ट्रिंग मान निर्धारित कर सकते हैं, जो सर्वर के रिस्पॉन्स में लौटाया जाता है और इससे जुड़ी एंट्री खोजने के लिए इस्तेमाल किया जाता है.

बैच में अनुरोध करने के लिए, बैच फ़ीड बनाएं और फ़ीड के बैच के लिंक पर एक एचटीटीपी POST भेजें:

<link rel="http://schemas.google.com/g/2005#batch" type="application/atom+xml"
    href="https://sites.google.com/feeds/content/site/siteName/batch"/>

नीचे दिए गए उदाहरण में वेबपेज एंट्री के बारे में क्वेरी करने, उसे शामिल करने, अपडेट करने, और मिटाने का तरीका बताया गया है:

POST /feeds/content/site/siteName/batch HTTP/1.1
Host: sites.google.com
Accept: */*
If-Match: *
GData-Version: 1.4
Authorization: <your authorization header here>

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:sites="http://schemas.google.com/sites/2008"
      xmlns:gd="http://schemas.google.com/g/2005" xmlns:batch='http://schemas.google.com/gdata/batch'>
  <entry>
    <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID1</id>
    <batch:operation type="query"/>
  </entry>
  <entry>
    <batch:id>1</batch:id>
    <batch:operation type='insert'/>
    <category scheme="http://schemas.google.com/g/2005#kind"
        term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
    <title>New Webpage1</title>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">HTML body goes here</div>
    </content>
  </entry>
  <entry gd:etag="&quot;YDgpeyI.&quot;">
    <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID2</id>
    <batch:operation type='update'/>
    <category scheme="http://schemas.google.com/g/2005#kind"
        term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
    <title>Updated Title for Webpage2</title>
    ...
    <batch:operaation type="update"/>
  </entry>
  <entry gd:etag="&quot;YassseyI.&quot;">
    <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID3</id>
    <batch:operation type='delete'/>
  </entry>
</feed>

लौटाए गए फ़ीड में, हर कार्रवाई के लिए नतीजे की एक एंट्री होगी:

 
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/"
    xmlns:sites="http://schemas.google.com/sites/2008" xmlns:gs="http://schemas.google.com/spreadsheets/2006"
    xmlns:dc="http://purl.org/dc/terms" xmlns:batch="http://schemas.google.com/gdata/batch"
    xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0">
<id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID1</id>
<updated>2009-11-10T22:44:08.369Z</updated>
<title>Batch Feed</title>
<entry gd:etag="&quot;YDgpsdfeyI.&quot;">
  <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID1</id>
  <published>2009-08-31T04:42:45.251Z</published>
  <updated>2009-10-25T22:46:13.729Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-10-25T22:46:13.671Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>Page Title</title>
  ...
  <batch:status code="200" reason="Success"/>
  <batch:operation type="query"/>
</entry>
<entry gd:etag="&quot;YDsseyI.&quot;">
  <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID4</id>
  <published>2009-11-10T22:44:08.531Z</published>
  <updated>2009-11-10T22:44:08.560Z</updated>
  <app:edited xmlns:app="http://www.w3.org/2007/app">2009-11-10T22:44:08.531Z</app:edited>
  <category scheme="http://schemas.google.com/g/2005#kind" term="http://schemas.google.com/sites/2008#webpage" label="webpage"/>
  <title>New Webpage1</title>
  <content type="xhtml">
    <div xmlns="http://www.w3.org/1999/xhtml">
    <table cellspacing="0" class="sites-layout-name-one-column sites-layout-hbox">
      <tbody>
        <tr>
          <td class="sites-layout-tile sites-tile-name-content-1">
            <div>HTML body goes here</div>
          </td>
        </tr>
      </tbody>
    </table>
  </div>
</content>
...
<batch:id>1</batch:id>
<batch:status code="201" reason="Created"/>
<batch:operation type="insert"/>
</entry>
<entry gd:etag="&quot;YDkpeyI.&quot;">
  <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID2</id>
  <updated>2009-11-10T22:44:09.296Z</updated>
  <title>Updated Title for Webpage2</title>
  ...
  <sites:pageName>updated-title-for-webpage2</sites:pageName>
  <sites:revision>5</sites:revision>
  <batch:status code="200" reason="Success"/>
  <batch:operation type="update"/>
</entry>
<entry>
  <id>https://sites.google.com/feeds/content/site/siteName/ENTRY_ID3</id>
  <title>Deleted</title>
  <content>Deleted</content>
  <batch:status code="200" reason="Success"/>
  <batch:operation type="delete"/>
</entry>
</feed>

वापस सबसे ऊपर जाएं