Groupilot Docs
Referencja API

Communities

GET
/communities

Communities created by Groupilot plus the external ones the number administers. The list is the set of valid broadcast targets. The external part is cached for 5 minutes.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An API key created in Settings > Integrations (gp_live_…), or an OAuth access token.

Response Body

Communities, most recent live first.

application/json
  1. response
items*array<>
external_unreachable*boolean

True when the connected number could not be queried: only communities known to Groupilot are listed.

curl -X GET 'https://app.groupilot.com/api/v1/communities'
{  "items": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "whatsapp_id": "string",      "name": "string",      "member_count": 0,      "source": "groupilot",      "occurrence_id": "8508ee33-23a1-4a06-ae02-1eb167405e7b",      "scheduled_at": "2019-08-24T14:15:22Z",      "number": 0    }  ],  "external_unreachable": true}

Read a community

GET
/communities/{id}

Authorization

bearerAuth
headerAuthorizationBearer <token>

An API key created in Settings > Integrations (gp_live_…), or an OAuth access token.

Path Parameters

id*string
Formatuuid

Response Body

The community.

application/json
  1. response
id*string
Formatuuid
whatsapp_id*string|null
name*string|null
status*string
source*CommunitySource

groupilot: created by Groupilot for an occurrence. external: a community of the connected number that Groupilot did not create (older events, manual groups).

Value in"groupilot""external"
member_count*integer
is_full*boolean
invite_link*string|null
number*integer
occurrence_id*|
Formatuuid
event_id*|
Formatuuid
options*
event_defaults*|null
curl -X GET 'https://app.groupilot.com/api/v1/communities/497f6eca-6276-4993-bfeb-53cbbbba6f08'
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "whatsapp_id": "string",  "name": "string",  "status": "string",  "source": "groupilot",  "member_count": 0,  "is_full": true,  "invite_link": "string",  "number": 0,  "occurrence_id": "8508ee33-23a1-4a06-ae02-1eb167405e7b",  "event_id": "a7a26ff2-e851-45b6-9634-d595f45458b7",  "options": {    "status": "string",    "applied_at": "2019-08-24T14:15:22Z",    "last_error": "string"  },  "event_defaults": {    "description": "string",    "modify_groups_policy": "anyone",    "member_add_mode": "anyone"  }}
PATCH
/communities/{id}

Applied on WhatsApp right away; the response reports each field.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An API key created in Settings > Integrations (gp_live_…), or an OAuth access token.

Path Parameters

id*string
Formatuuid

Request Body

application/json
  1. body
name?string
Length1 <= length <= 100
description?|
Lengthlength <= 2000
modify_groups_policy?CommunityPolicy
Value in"anyone""admins"
member_add_mode?CommunityPolicy
Value in"anyone""admins"

Response Body

Applied (possibly partially).

application/json
  1. response
community*
applied*
errors*
curl -X PATCH 'https://app.groupilot.com/api/v1/communities/497f6eca-6276-4993-bfeb-53cbbbba6f08' \  -H 'Content-Type: application/json' \  -d '{}'
{  "community": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "whatsapp_id": "string",    "name": "string",    "status": "string",    "source": "groupilot",    "member_count": 0,    "is_full": true,    "invite_link": "string",    "number": 0,    "occurrence_id": "8508ee33-23a1-4a06-ae02-1eb167405e7b",    "event_id": "a7a26ff2-e851-45b6-9634-d595f45458b7",    "options": {      "status": "string",      "applied_at": "2019-08-24T14:15:22Z",      "last_error": "string"    },    "event_defaults": {      "description": "string",      "modify_groups_policy": "anyone",      "member_add_mode": "anyone"    }  },  "applied": {    "property1": true,    "property2": true  },  "errors": {    "property1": "string",    "property2": "string"  }}