Skip to content
This repository has been archived by the owner on Feb 5, 2020. It is now read-only.

Latest commit

 

History

History
79 lines (62 loc) · 1.38 KB

03.Groups-resource.md

File metadata and controls

79 lines (62 loc) · 1.38 KB

Groups

Group schema

  • id: Group ID.
  • name: Group name.
  • uri: Group URI on Gitter.
  • backedBy: Security descriptor. Describes the backing object we get permissions from.
    • type: [null|'ONE_TO_ONE'|'GH_REPO'|'GH_ORG'|'GH_USER']
    • linkPath: Represents how we find the backing object given the type
  • avatarUrl: Base avatar URL (add s parameter to size)

List Groups

List groups the current user is in.

Parameters

  • none
GET /v1/groups

Try it from the CLI:

'demo api-access';
{
  "verb": "get",
  "resource": "{{api_url}}/v1/groups"
}
[
  {
    "id": "57542c12c43b8c601976fa66",
    "name": "gitterHQ",
    "uri": "gitterHQ",
    "backedBy": {
        "type": "GH_ORG",
        "linkPath": "gitterHQ"
    },
    "avatarUrl": "http://gitter.im/api/private/avatars/group/i/577ef7e4e897e2a459b1b881"
  },
  {
    "id": "577faf61a7d5727908337209",
    "name": "i-love-cats",
    "uri": "i-love-cats",
    "backedBy": {
        "type": null
    },
    "avatarUrl": "http://gitter.im/api/private/avatars/group/i/577faf61a7d5727908337209"
  }
]

Group sub-resources

Rooms

List rooms under group

List of rooms nested under the specified group.

GET /v1/groups/:groupId/rooms

Try it from the CLI:

'demo api-access';
{
  "verb": "get",
  "resource": "{{api_url}}/v1/groups/57542c12c43b8c601976fa66/groups"
}