Gigya Job Openings

comments.getModerators REST

Skip to end of metadata
Go to start of metadata

 

Description

This API retrieves the moderators of a site and the categories they are moderating.

You can retrieve all current moderators for a site, or specify individual moderators using the optional usernames parameter.

Unable to render {include} The included page could not be found.

Parameters

RequiredNameTypeDescription

usernamesstringA comma separated list or JSON array of moderator usernames you want to retrieve, default is to return all moderators.

Sample Requests

 

Response Data

FieldTypeDescription
moderatorsarrayIncludes all the following for each moderator (some fields may be empty):
usernamestringThe username of the moderator.
nicknamestringThe nickname of the moderator.
photoUrlstringThe url to the moderators photo.
categoriesarray

Contains all the categories for which the moderator has privileges.

  • If the moderator has privileges for all categories, this will return as "*".
  • If the moderator has no privileges for any category, this will return empty, e.g., "categories": [ ].
 
errorCode integer The result code of the operation. Code '0' indicates success, any other number indicates failure. For a complete list of error codes, see the Error Codes table.
errorMessage string A short textual description of an error, associated with the errorCode, for logging purposes. This field will appear in the response only in case of an error.
errorDetails string This field will appear in the response only in case of an error and will contain the exception info, if available.
fullEventName string The full name of the event that triggered the response. This is an internally used parameter that is not always returned and should not be relied upon by your implementation.
callId string Unique identifier of the transaction, for debugging purposes.
time string The time of the response represented in ISO 8601 format, i.e., yyyy-mm-dd-Thh:MM:ss.SSSZ or
statusCode integer The HTTP response code of the operation. Code '200' indicates success.
This property is deprecated and only returned for backward compatibility.
statusReason string A brief explanation of the status code.
This property is deprecated and only returned for backward compatibility.

 

A field that does not contain data will not appear in the response.

Response Example

{
  "moderators": [
    {
      "username": "Levi",
      "nickname": "Levi",
      "photoUrl": "",
      "categories": [
        "*"
      ]
    },
	{
      "username": "leroyjenkins@xxxxxxxxxxx.com",
      "categories": []
    },
    {
      "username": "john@xxxxxxxxx.com",
      "nickname": "John S",
      "photoUrl": "",
      "categories": [
        "Awesome Stuff"
      ]
    }
  ],
  "statusCode": 200,
  "errorCode": 0,
  "statusReason": "OK",
  "callId": "388816461341486a86a796ab2170f085",
  "time": "2015-07-05T15:04:36.430Z"
}

More Information

For additional information on modifying moderators see the following:

 

 

 

 

 

 

 

 

  • No labels