Skip to main content

 Services

Web services from /about to /webhooks

find comments

/members/{member}/comments/find [GET]

Description

Load a list of comments using filter parameters. The most recent comments are returned first.

This service performs the same as Service: /comments/find [GET] but returns any comments that {member} has access to.

Parameters

NameDescriptionRequiredTypeDefault value
groupsA comma-separated list of group names the comments must belong toyesstrings
archivedIf true, include archived commentsnobooleanfalse
attachmentsThe attachments to include
(can be none, context or all)
noenumall
authorThe ID of the comments authornolong
contentsThe contents to include
(can be none or all)
noenumall
contextOnly return comments in this context (can be group, uri, all)noenumall
createdafterThe date time after which the comments were created e.g. 2010-10-25T12:26:00+10:00nodatetime
createdbeforeThe date time before which the comments were created e.g. 2011-08-25T10:20:00-04:00nodatetime
emailsThe emails to include 
(can be none or all). Administrator use ONLY
noenumnone
labelsA comma-separated list of label values – comment MUST have all (not recommended for filtering large data sets)nostring
moderatedIf true, include moderated (not accepted) commentsnobooleanfalse
pageThe page to loadnolong1
pagesizeThe number of results per pageno long1000
pathsThe context URI paths for the comments – MUST be URL encoded (comma-separated list with optional * suffix)nopaths
positionIf first, only the first (root) comment in a discussion is returned (might be faster when using paths)nostringany
returngroupsThe groups to return in the output (can be none or specified)noenum"none" or if multiple groups "specified"
statusesComma-separated list of statusesnostring
titleThe title the comments MUST have (optional wildcard * suffix, use ** to escape)nostring
typeThe type the comments MUST have (optional wildcard * suffix, use ** to escape)nostring
typesComma-separated list of types the comment can have (empty string means no type)nostrings

Permission

The member in the request must have access to all the groups in the groups parameter. If the emails parameter is set to all, then the service is restricted to administrator only.

Response

The output has the following format:

<comments>
  <comment id="234"
           contentrole="File Attachment"
           created="2012-03-08T12:34:00+10:00">
    <title>My thread</title>
    <content type="text/plain">Some text</content>
    <attachment>
      <uri id="189"> ... </uri>
    </attachment>
    <attachment fragment="5">
      <uri id="289"> ... </uri>
    </attachment>
    <context>
      <group  id="3" name="acme-test" />
    </context>
  </comment>
  <comment id="567">
    ...
    <context fragment="2">
      <uri id="789"> ... </uri>
    </context>
  </comment>
</<comments>

Error Handling

CodeCause / Description
0x1306The Group is invalid or not accessible
0x1312The createdafter or createdbefore date is invalid
0x1313The author is invalid

 

Created on , last edited on