Remove ACL from document

99 views
Skip to first unread message

iPepito

unread,
Jan 4, 2012, 11:34:05 AM1/4/12
to Google Documents List API
I receive an error removing an ACLEntry from a document.
The only difference between my code and the one from the Calendar
sample is that I restore the GDataEntryDocBase object from the xml.
The entry was fetched originally from the default feed using the
expandACL option, for same reason the identifier of the aclEntry is:
https://docs.google.com/feeds/default/private/expandAcl/user%3AmyMail%40gmail.com.
Why the identifier is not correct? Any idea?

This is the code:

GDataEntryDocBase *theDocument = [documentEntity gdataDocument];
NSArray *aclEntries = [[[theDocument ACLFeedLink] feed] entries];
GDataEntryACL *entryACL;
for (entryACL in aclEntries) {
if ([[[entryACL scope] value] isEqualToString: mail]) {
GDataServiceTicket *ticket = [[GDataDocumentManager service]
deleteACLEntry:entryACL delegate:self
didFinishSelector:@selector(_defaultCallbackForFeed:finishedWithFeed:error:)];
break;
}
}

This is the log

2012-01-04 16:24:12 +0000
Request: DELETE https://docs.google.com/feeds/default/private/expandAcl/user%3AmyMail%40gmail.com
Request headers:
Accept: application/atom+xml, text/xml
Authorization: Bearer _snip_
Cache-Control: no-cache
Content-Type: application/atom+xml; charset=utf-8
GData-Version: 3.0
If-Match: *
User-Agent: net.******-1.0 GData-ObjectiveC/1.12 MacOSX/10.7.2
(gzip)

Response: status 400
Response headers:
Cache-Control: private, max-age=0
Content-Encoding: gzip
Content-Type: application/vnd.google.gdata.error+xml
Date: Wed, 04 Jan 2012 16:24:12 GMT
Expires: Wed, 04 Jan 2012 16:24:12 GMT
Server: GSE
Transfer-Encoding: Identity
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block

Response body: (206 bytes)
<errors xmlns='http://schemas.google.com/g/2005'><error><domain>GData</
domain><code>InvalidEntryException</code><internalReason>Invalid
document id: user:myM...@gmail.com</internalReason></error></errors>
-----------------------------------------------------------

Ali Afshar

unread,
Jan 4, 2012, 11:40:31 AM1/4/12
to google-docum...@googlegroups.com
Hi,

That URI is not correct for removing ACL [1], it should be more like:

DELETE /feeds/default/private/full/resource_id/acl/user:new_w...@example.com

Regards

[1] http://code.google.com/apis/documents/docs/3.0/developers_guide_protocol.html#ACLRemoveSharing

--
Ali Afshar | www.googplus.org/ali | Google Developer Relations

iPepito

unread,
Jan 7, 2012, 7:00:17 AM1/7/12
to Google Documents List API
Sometimes the edit link retrieved by the API is incorrect!
I'm retrieving the entire feed of document with the expandACL
attribute, every acl entry has an edit link with the following
format:
https://docs.google.com/feeds/default/private/expandAcl/user%3A<acl scope
value>

Maybe the Api does not handle correctly acl entries while using the
request: GET https://docs.google.com/feeds/default/private/expandAcl?showfolders=true.

This is the response of an entry fetched with the previous request,
I'm just showing the part relative to an acl feed of an entry.

[...]
<gd:feedLink rel="http://schemas.google.com/acl/
2007#accessControlList" href="https://docs.google.com/feeds/default/
private/expandAcl/folder
%3A0BwWfffIbdSCUYTBkNmJmOTYtYWEzYS00YjcyLTg4YzItZWExYjM0ZmFkNDc2/acl">
<feed gd:etag="W/&quot;AkIBQ3Y7fSt7ImA9WhRWGEg.&quot;">
[...]
<link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Amymail
%40gmail.com"/>
<link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Amymail
%40gmail.com"/>
<gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="owner"/>
<gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="mym...@gmail.com"/>
</entry>
</feed>
</gd:feedLink>
[...]

As you all can see, the edit link is not correct.

Ali Afshar

unread,
Jan 7, 2012, 8:48:33 AM1/7/12
to google-docum...@googlegroups.com
Hi iPepito,

Thanks for raising this, it certainly looks like a bug, I will
investigate and get back to you. Could you paste your complete
response XML please, without [...]? Thanks.

Regards

--

iPepito

unread,
Jan 7, 2012, 1:41:26 PM1/7/12
to Google Documents List API
_defaultCallbackForFeed:finishedWithFeed:error:




2012-01-07 18:34:25 +0000
Request: GET https://docs.google.com/feeds/default/private/expandAcl?showfolders=true
Request headers:
  Accept: application/atom+xml, text/xml
  Authorization: Bearer _snip_
  Cache-Control: no-cache
  Content-Type: application/atom+xml; charset=utf-8
  GData-Version: 3.0
  User-Agent: net.myProject-1.0 GData-ObjectiveC/1.12 MacOSX/10.7.2
(gzip)



I created a test account. This is a complete log.

Response: status 200
Response headers:
  Cache-Control: private, max-age=0, must-revalidate, no-transform
  Content-Encoding: gzip
  Content-Type: application/atom+xml; charset=UTF-8; type=feed
  Date: Sat, 07 Jan 2012 18:34:24 GMT
  Etag: W/"C0UCQng5eSt7ImA9WhRWGUs."
  Expires: Sat, 07 Jan 2012 18:34:24 GMT
  GData-Version: 3.0
  Last-Modified: Sat, 07 Jan 2012 18:34:23 GMT
  Server: GSE
  Transfer-Encoding: Identity
  Vary: Accept, X-GData-Authorization, GData-Version
  X-Content-Type-Options: nosniff
  X-Frame-Options: SAMEORIGIN
  X-XSS-Protection: 1; mode=block




Response body: (16979 bytes)
<?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:docs="http://schemas.google.com/
docs/2007" xmlns:batch="http://schemas.google.com/gdata/batch"
xmlns:gd="http://schemas.google.com/g/2005" gd:etag="W/
&quot;C0UCQng5eSt7ImA9WhRWGUs.&quot;">
  <id>https://docs.google.com/feeds/default/private/expandAcl</id>
  <updated>2012-01-07T18:34:23.621Z</updated>
  <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/docs/2007#item" label="item"/>
  <title>Available Documents - nonnapa...@gmail.com</title>
  <link rel="alternate" type="text/html" href="https://
docs.google.com"/>
  <link rel="http://schemas.google.com/g/2005#resumable-create-media"
type="application/atom+xml" href="https://docs.google.com/feeds/upload/
create-session/default/private/expandAcl"/>
  <link rel="http://schemas.google.com/g/2005#feed" type="application/
atom+xml" href="https://docs.google.com/feeds/default/private/
expandAcl"/>
  <link rel="http://schemas.google.com/g/2005#post" type="application/
atom+xml" href="https://docs.google.com/feeds/default/private/
expandAcl"/>
  <link rel="http://schemas.google.com/g/2005#batch" type="application/
atom+xml" href="https://docs.google.com/feeds/default/private/
expandAcl/batch"/>
  <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl?showfolders=true"/>
  <author>
    <name>nonnapapera888</name>
    <email>nonnapa...@gmail.com</email>
  </author>
  <openSearch:startIndex>1</openSearch:startIndex>
  <entry gd:etag="&quot;ERIZEA5IBit7ImBr&quot;">
    <id>https://docs.google.com/feeds/id/presentation
%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI</id>
    <published>2012-01-07T18:11:59.283Z</published>
    <updated>2012-01-07T18:32:11.172Z</updated>
    <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:32:11.174Z</app:edited>
    <category scheme="http://schemas.google.com/g/2005/labels"
term="http://schemas.google.com/g/2005/labels#viewed" label="viewed"/>
    <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/docs/2007#presentation"
label="presentation"/>
    <title>Test Presentation</title>
    <content type="text/html" src="https://docs.google.com/feeds/
download/presentations/Export?
docId=0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
    <link rel="alternate" type="text/html" href="https://
docs.google.com/present/edit?
id=0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI&amp;hl=en_US"/>
    <link rel="http://schemas.google.com/docs/2007#embed" type="text/
html" href="https://docs.google.com/present/embed?
id=0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI&amp;size=m&amp;hl=en_US"/>
    <link rel="http://schemas.google.com/docs/2007#icon" type="image/
png" href="https://docs.google.com/images/doclist/
icon_9_presentation_list.png"/>
    <link rel="http://schemas.google.com/g/2005#resumable-edit-media"
type="application/atom+xml" href="https://docs.google.com/feeds/upload/
create-session/default/private/expandAcl/presentation
%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
    <link rel="http://schemas.google.com/docs/2007/thumbnail"
type="image/jpeg" href="https://docs.google.com/feeds/vt?
authuser=0&amp;gd=true&amp;id=0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI&amp;v=1&amp;s=AMedNnoAAAAATwisUPydSLgaDJlRffzgx9RRxB9m8GLi&amp;sz=s220"/
>
    <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/presentation
%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
    <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/presentation
%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
    <link rel="edit-media" type="text/html" href="https://
docs.google.com/feeds/default/media/presentation
%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
    <author>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </author>
    <gd:resourceId>presentation:0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI</
gd:resourceId>
    <gd:lastModifiedBy>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </gd:lastModifiedBy>
    <gd:lastViewed>2012-01-07T18:11:59.902Z</gd:lastViewed>
    <gd:quotaBytesUsed>0</gd:quotaBytesUsed>
    <docs:writersCanInvite value="true"/>
    <gd:feedLink rel="http://schemas.google.com/acl/
2007#accessControlList" href="https://docs.google.com/feeds/default/
private/expandAcl/presentation%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI/
acl">
      <feed gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
        <id>https://docs.google.com/feeds/default/private/expandAcl</
id>
        <updated>2012-01-07T18:34:24.898Z</updated>
        <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
        <title>Document Permissions</title>
        <link rel="http://schemas.google.com/g/2005#feed"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#post"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#batch"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl/batch"/>
        <openSearch:totalResults>2</openSearch:totalResults>
        <entry gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
          <id>https://docs.google.com/feeds/id/user
%3Anonnapapera888%40gmail.com</id>
          <updated>2012-01-07T18:34:24.898Z</updated>
          <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:34:24.898Z</app:edited>
          <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
          <title>Document Permission - nonnapa...@gmail.com</
title>
          <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="owner"/>
          <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="nonnapa...@gmail.com"/>
        </entry>
        <entry gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
          <id>https://docs.google.com/feeds/id/user%3Arosanero
%40gmail.com</id>
          <updated>2012-01-07T18:34:24.898Z</updated>
          <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:34:24.898Z</app:edited>
          <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
          <title>Document Permission - rosa...@gmail.com</title>
          <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
%40gmail.com"/>
          <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
%40gmail.com"/>
          <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="writer"/>
          <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="rosa...@gmail.com" name="Giuseppe Basile"/>
        </entry>
      </feed>
    </gd:feedLink>
    <gd:feedLink rel="http://schemas.google.com/docs/2007/revisions"
href="https://docs.google.com/feeds/default/private/expandAcl/
presentation%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI/revisions"/>
  </entry>
  <entry gd:etag="&quot;ERIZEU9DTit7ImBr&quot;">
    <id>https://docs.google.com/feeds/id/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM</id>
    <published>2012-01-07T18:10:11.389Z</published>
    <updated>2012-01-07T18:32:24.367Z</updated>
    <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:32:24.369Z</app:edited>
    <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/docs/2007#document" label="document"/>
    <category scheme="http://schemas.google.com/g/2005/labels"
term="http://schemas.google.com/g/2005/labels#viewed" label="viewed"/>
    <title>Test File</title>
    <content type="text/html" src="https://docs.google.com/feeds/
download/documents/export/Export?
id=1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM"/>
    <link rel="alternate" type="text/html" href="https://
docs.google.com/document/d/
1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM/edit?hl=en_US"/>
    <link rel="http://schemas.google.com/docs/2007#embed" type="text/
html" href="https://docs.google.com/document/d/
1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM/preview?hl=en_US"/>
    <link rel="http://schemas.google.com/docs/2007#icon" type="image/
png" href="https://docs.google.com/images/doclist/
icon_9_document_list.png"/>
    <link rel="http://schemas.google.com/g/2005#resumable-edit-media"
type="application/atom+xml" href="https://docs.google.com/feeds/upload/
create-session/default/private/expandAcl/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM"/>
    <link rel="http://schemas.google.com/docs/2007/thumbnail"
type="image/jpeg" href="https://docs.google.com/feeds/vt?
authuser=0&amp;gd=true&amp;id=1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM&amp;v=3&amp;s=AMedNnoAAAAATwisUBjwGWMCi85pqpmF-
HM_CJ9y40ZB&amp;sz=s220"/>
    <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM"/>
    <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM"/>
    <link rel="edit-media" type="text/html" href="https://
docs.google.com/feeds/default/media/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM"/>
    <author>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </author>
    <gd:resourceId>document:
1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM</gd:resourceId>
    <docs:modifiedByMeDate>2012-01-07T18:10:15.711Z</
docs:modifiedByMeDate>
    <gd:lastModifiedBy>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </gd:lastModifiedBy>
    <gd:lastViewed>2012-01-07T18:10:15.711Z</gd:lastViewed>
    <gd:quotaBytesUsed>0</gd:quotaBytesUsed>
    <docs:writersCanInvite value="true"/>
    <gd:feedLink rel="http://schemas.google.com/acl/
2007#accessControlList" href="https://docs.google.com/feeds/default/
private/expandAcl/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM/acl">
      <feed gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
        <id>https://docs.google.com/feeds/default/private/expandAcl</
id>
        <updated>2012-01-07T18:34:24.898Z</updated>
        <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
        <title>Document Permissions</title>
        <link rel="http://schemas.google.com/g/2005#feed"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#post"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#batch"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl/batch"/>
        <openSearch:totalResults>2</openSearch:totalResults>
        <entry gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
          <id>https://docs.google.com/feeds/id/user
%3Anonnapapera888%40gmail.com</id>
          <updated>2012-01-07T18:34:24.898Z</updated>
          <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:34:24.898Z</app:edited>
          <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
          <title>Document Permission - nonnapa...@gmail.com</
title>
          <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="owner"/>
          <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="nonnapa...@gmail.com"/>
        </entry>
        <entry gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
          <id>https://docs.google.com/feeds/id/user%3Arosanero
%40gmail.com</id>
          <updated>2012-01-07T18:34:24.898Z</updated>
          <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:34:24.898Z</app:edited>
          <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
          <title>Document Permission - rosa...@gmail.com</title>
          <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
%40gmail.com"/>
          <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
%40gmail.com"/>
          <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="writer"/>
          <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="rosa...@gmail.com" name="Giuseppe Basile"/>
        </entry>
      </feed>
    </gd:feedLink>
    <gd:feedLink rel="http://schemas.google.com/docs/2007/revisions"
href="https://docs.google.com/feeds/default/private/expandAcl/document
%3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM/revisions"/>
  </entry>
  <entry gd:etag="&quot;ERIaVEtcQSt7ImBr&quot;">
    <id>https://docs.google.com/feeds/id/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2</id>
    <published>2012-01-07T18:26:05.641Z</published>
    <updated>2012-01-07T18:26:10.911Z</updated>
    <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:26:15.618Z</app:edited>
    <category scheme="http://schemas.google.com/g/2005/labels"
term="http://schemas.google.com/g/2005/labels#viewed" label="viewed"/>
    <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/docs/2007#folder" label="folder"/>
    <title>testCollection</title>
    <content type="application/atom+xml;type=feed" src="https://
docs.google.com/feeds/default/private/expandAcl/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2/
contents"/>
    <link rel="alternate" type="text/html" href="https://
docs.google.com/#folders/folder.
0.0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2"/>
    <link rel="http://schemas.google.com/docs/2007#icon" type="image/
png" href="https://docs.google.com/images/doclist/
icon_8_collection_list.png"/>
    <link rel="http://schemas.google.com/g/2005#resumable-create-
media" type="application/atom+xml" href="https://docs.google.com/feeds/
upload/create-session/default/private/expandAcl/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2/
contents"/>
    <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2"/>
    <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2"/>
    <author>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </author>
    <gd:resourceId>folder:
0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2</
gd:resourceId>
    <docs:modifiedByMeDate>2012-01-07T18:26:10.911Z</
docs:modifiedByMeDate>
    <gd:lastModifiedBy>
      <name>nonnapapera888</name>
      <email>nonnapa...@gmail.com</email>
    </gd:lastModifiedBy>
    <gd:lastViewed>2012-01-07T18:26:06.419Z</gd:lastViewed>
    <gd:quotaBytesUsed>0</gd:quotaBytesUsed>
    <docs:writersCanInvite value="true"/>
    <gd:feedLink rel="http://schemas.google.com/acl/
2007#accessControlList" href="https://docs.google.com/feeds/default/
private/expandAcl/folder
%3A0BybeP7lYbPxkZGU5NTNmZGUtNmJlMC00OTY0LTlmMzYtMzk3NDQwZjEyY2I2/acl">
      <feed gd:etag="W/&quot;C0UCRXYycSt7ImA9WhRWGUs.&quot;">
        <id>https://docs.google.com/feeds/default/private/expandAcl</
id>
        <updated>2012-01-07T18:34:24.899Z</updated>
        <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
        <title>Document Permissions</title>
        <link rel="http://schemas.google.com/g/2005#feed"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#post"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl"/>
        <link rel="http://schemas.google.com/g/2005#batch"
type="application/atom+xml" href="https://docs.google.com/feeds/
default/private/expandAcl/batch"/>
        <openSearch:totalResults>1</openSearch:totalResults>
        <entry gd:etag="W/&quot;C0UCRXYycSt7ImA9WhRWGUs.&quot;">
          <id>https://docs.google.com/feeds/id/user
%3Anonnapapera888%40gmail.com</id>
          <updated>2012-01-07T18:34:24.899Z</updated>
          <app:edited xmlns:app="http://www.w3.org/2007/
app">2012-01-07T18:34:24.899Z</app:edited>
          <category scheme="http://schemas.google.com/g/2005#kind"
term="http://schemas.google.com/acl/2007#accessRule"/>
          <title>Document Permission - nonnapa...@gmail.com</
title>
          <link rel="self" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <link rel="edit" type="application/atom+xml" href="https://
docs.google.com/feeds/default/private/expandAcl/user
%3Anonnapapera888%40gmail.com"/>
          <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
value="owner"/>
          <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
type="user" value="nonnapa...@gmail.com"/>
        </entry>
      </feed>
    </gd:feedLink>
  </entry>
</feed>




-----------------------------------------------------------

On Jan 7, 2:48 pm, Ali Afshar <afs...@google.com> wrote:
> Hi iPepito,
>
> Thanks for raising this, it certainly looks like a bug, I will
> investigate and get back to you. Could you paste your complete
> response XML please, without [...]? Thanks.
>
> Regards
>
>
>
>
>
>
>
>
>
> On Sat, Jan 7, 2012 at 12:00 PM, iPepito <rosan...@gmail.com> wrote:
> > Sometimes the edit link retrieved by the API is incorrect!
> > I'm retrieving the entire feed of document with the expandACL
> > attribute, every acl entry has an edit link with the following
> > format:
> >https://docs.google.com/feeds/default/private/expandAcl/user%3A<acl scope
> > value>
>
> > Maybe the Api does not handle correctly acl entries while using the
> > request: GEThttps://docs.google.com/feeds/default/private/expandAcl?showfolders=true.

iPepito

unread,
Jan 9, 2012, 4:41:49 AM1/9/12
to Google Documents List API
Can you please give me some feedback about this problem?

On Jan 7, 7:41 pm, iPepito <rosan...@gmail.com> wrote:
> _defaultCallbackForFeed:finishedWithFeed:error:
>
> 2012-01-07 18:34:25 +0000
> Request: GEThttps://docs.google.com/feeds/default/private/expandAcl?showfolders=true
>   <title>Available Documents - nonnapapera...@gmail.com</title>
>   <link rel="alternate" type="text/html" href="https://
> docs.google.com"/>
>   <link rel="http://schemas.google.com/g/2005#resumable-create-media"
> type="application/atom+xml" href="https://docs.google.com/feeds/upload/
> create-session/default/private/expandAcl"/>
>   <link rel="http://schemas.google.com/g/2005#feed" type="application/
> atom+xml" href="https://docs.google.com/feeds/default/private/
> expandAcl"/>
>   <link rel="http://schemas.google.com/g/2005#post" type="application/
> atom+xml" href="https://docs.google.com/feeds/default/private/
> expandAcl"/>
>   <link rel="http://schemas.google.com/g/2005#batch" type="application/
> atom+xml" href="https://docs.google.com/feeds/default/private/
> expandAcl/batch"/>
>   <link rel="self" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl?showfolders=true"/>
>   <author>
>     <name>nonnapapera888</name>
>     <email>nonnapapera...@gmail.com</email>
> authuser=0&amp;gd=true&amp;id=0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI&amp;v=1& amp;s=AMedNnoAAAAATwisUPydSLgaDJlRffzgx9RRxB9m8GLi&amp;sz=s220"/
>
>     <link rel="self" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/presentation
> %3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
>     <link rel="edit" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/presentation
> %3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
>     <link rel="edit-media" type="text/html" href="https://
> docs.google.com/feeds/default/media/presentation
> %3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI"/>
>     <author>
>       <name>nonnapapera888</name>
>       <email>nonnapapera...@gmail.com</email>
>     </author>
>     <gd:resourceId>presentation:0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI</
> gd:resourceId>
>     <gd:lastModifiedBy>
>       <name>nonnapapera888</name>
>       <email>nonnapapera...@gmail.com</email>
>           <title>Document Permission - nonnapapera...@gmail.com</
> title>
>           <link rel="self" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/user
> %3Anonnapapera888%40gmail.com"/>
>           <link rel="edit" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/user
> %3Anonnapapera888%40gmail.com"/>
>           <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
> value="owner"/>
>           <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
> type="user" value="nonnapapera...@gmail.com"/>
>         </entry>
>         <entry gd:etag="W/&quot;C0UCRXYycCt7ImA9WhRWGUs.&quot;">
>           <id>https://docs.google.com/feeds/id/user%3Arosanero
> %40gmail.com</id>
>           <updated>2012-01-07T18:34:24.898Z</updated>
>           <app:edited xmlns:app="http://www.w3.org/2007/
> app">2012-01-07T18:34:24.898Z</app:edited>
>           <category scheme="http://schemas.google.com/g/2005#kind"
> term="http://schemas.google.com/acl/2007#accessRule"/>
>           <title>Document Permission - rosan...@gmail.com</title>
>           <link rel="self" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
> %40gmail.com"/>
>           <link rel="edit" type="application/atom+xml" href="https://
> docs.google.com/feeds/default/private/expandAcl/user%3Arosanero
> %40gmail.com"/>
>           <gAcl:role xmlns:gAcl="http://schemas.google.com/acl/2007"
> value="writer"/>
>           <gAcl:scope xmlns:gAcl="http://schemas.google.com/acl/2007"
> type="user" value="rosan...@gmail.com" name="Giuseppe Basile"/>
>         </entry>
>       </feed>
>     </gd:feedLink>
>     <gd:feedLink rel="http://schemas.google.com/docs/2007/revisions"
> href="https://docs.google.com/feeds/default/private/expandAcl/
> presentation%3A0ASbeP7lYbPxkZHpydGNqd18wZG02c2poZmI/revisions"/>
>   </entry>
>   <entry gd:etag="&quot;ERIZEU9DTit7ImBr&quot;">
>     <id>https://docs.google.com/feeds/id/document
> %3A1-796cSbH0zYn5vavFNhWO2d_SCxdCewk8vchZayqgAM</id>
>     <published>2012-01-07T18:10:11.389Z</published>
>     <updated>2012-01-07T18:32:24.367Z</updated>
>     <app:edited xmlns:app="http://www.w3.org/2007/
> app">2012-01-07T18:32:24.369Z</app:edited>
>     <category scheme="http://schemas.google.com/g/2005#kind"
> term="http://schemas.google.com/docs/2007#document" label="document"/>
>     <category scheme="http://schemas.google.com/g/2005/labels"
> term="http://schemas.google.com/g/2005/labels#viewed" label="viewed"/>
>     <title>Test File</title>
>     <content type="text/html" ...
>
> read more »

Ali Afshar

unread,
Jan 9, 2012, 9:46:34 AM1/9/12
to google-docum...@googlegroups.com
Hi,

If you want to remove an ACL, you should manually create the uri[1]
and send the DELETE request. We are investigating the incorrect link
for expand-acl, and I will update this thread with any news.

Regards

[1] http://code.google.com/apis/documents/docs/3.0/developers_guide_protocol.html#ACLRemoveSharing

--

iPepito

unread,
Jan 11, 2012, 9:24:23 AM1/11/12
to Google Documents List API
Perfect! I will wait for updates!
Thanks

On Jan 9, 3:46 pm, Ali Afshar <afs...@google.com> wrote:
> Hi,
>
> If you want to remove an ACL, you should manually create the uri[1]
> and send the DELETE request. We are investigating the incorrect link
> for expand-acl, and I will update this thread with any news.
>
> Regards
>
> [1]http://code.google.com/apis/documents/docs/3.0/developers_guide_proto...
> ...
>
> read more »

iPepito

unread,
Jan 30, 2012, 7:19:15 AM1/30/12
to Google Documents List API
The workaround works fine while I remove a single entry.
Anyway, I can not batch ACLs cause of this problem, I always had an
"<batch:status code="400" reason="Invalid entry Id/Uri"/>"

Are there some news about this issue?
Regards

Ali Afshar

unread,
Feb 1, 2012, 11:22:38 AM2/1/12
to google-docum...@googlegroups.com
This should now be fixed in the API to return correct URIs when using
the expandAcl.

--

iPepito

unread,
Feb 7, 2012, 12:24:10 PM2/7/12
to Google Documents List API
I have tested these changes removing ACL for document with scope
default and domain and it works!
I will test tomorrow all the scopes, but I think the problem was
resolved!
Thanks

Ali Afshar

unread,
Feb 7, 2012, 1:10:33 PM2/7/12
to google-docum...@googlegroups.com
Excellent, please let us know if you have further issues.

Regards
Reply all
Reply to author
Forward
0 new messages