Group: ipernity API development


Document permissions


Nick Lawes
17 Jun 2013 - 1 comment - 711 visits- Permalink   |   Translate title into English

Having recently started using the API from PHP, I am finding that the documented API does not match the actual API… For example, getting permissions of a document (doc.getPerms) is supposed to return ispublic, isfriend and isfamily where each field is set to 0 or 1. However, only the ispublic is returned…

Likewise when listing documents (doc.getList) the share parameter is totally ignored. It wouldn't be so bad if one or the other were broken, but as it's both, filtering is not possible…

Or am I missing something?
Comments
 Nick Lawes
Nick Lawes
Hmm, not quite true… If you are authenticated, doc.getList returns all of the documents you are entitled to see. This includes non-public (i.e. friends/family/friends&family) for each user that you list. This means that you can have to do a doc.getPerms call for each document to determine if it is public or not, then decide what to do with it. If the share filter worked that perm call per document could be eliminated. Or if the perm information was returned in doc.getList...
10 years ago.

You must be a member of this group to reply to this topic. (Join?)