Mode Groups API
The Groups API from Mode — 4 operation(s) for groups.
The Groups API from Mode — 4 operation(s) for groups.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/mode-groups-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
version: 0.0.1
title: Mode Account Groups API
description: 'Mode provides a REST API for many common operations, such as:
* Listing spaces and reports
* Running reports
* Downloading query results
## Authentication
For most Mode API calls, the client must supply an API token and secret for
HTTP basic authentication.
If authentication is required for a given resource, unauthenticated requests
will result in a `401 Unauthorized` response.
[Create and Manage API Tokens](https://modeanalytics.com/settings/access_tokens)
'
termsOfService: https://mode.com/tos/
contact:
name: Mode API Team
email: support@modeanalytics.com
license:
name: MIT
servers:
- url: https://modeanalytics.com/api
security:
- accessTokenAuth: []
tags:
- name: Groups
paths:
/{workspace}/groups/{group_token}/memberships:
x-summary: Group Memberships
get:
operationId: listGroupMemberships
summary: List group memberships
description: Get all `Memberships` of a `Group`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroupMembership` collection response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroupMemberships'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
tags:
- Groups
post:
operationId: createGroupMembership
summary: Create a group membership
description: Create a `Group` `Membership` for a given `User`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroupMembership` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroupMembership'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
'400':
description: Bad request
content:
application/hal+json:
schema:
$ref: '#/components/schemas/BadRequest'
tags:
- Groups
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateUserGroupMembershipRequestBody'
/{workspace}/groups/{group_token}/memberships/{membership_token}:
x-summary: Group Membership
get:
operationId: getGroupMembership
summary: Get a group membership
description: Get the `Group` `Membership` of a `User`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
- name: membership_token
in: path
description: '`UserGroupMembership token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroupMembership` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroupMembership'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
tags:
- Groups
delete:
operationId: deleteGroupMembership
summary: Delete a group membership
description: Remove a `User` from a `Group` by deleting the `Membership`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
- name: membership_token
in: path
description: '`UserGroupMembership token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroupMembership` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroupMembership'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
'400':
description: Bad request
content:
application/hal+json:
schema:
$ref: '#/components/schemas/BadRequest'
tags:
- Groups
/{workspace}/groups:
x-summary: Groups
get:
operationId: listGroups
summary: List groups
description: Get all `Group`s for a `Workspace`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroup` collection response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroups'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
tags:
- Groups
post:
operationId: createGroup
summary: Create a group
description: Create a user `Group` with the provided attributes
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroup` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroup'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
'400':
description: Bad request
content:
application/hal+json:
schema:
$ref: '#/components/schemas/BadRequest'
tags:
- Groups
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateUserGroupRequestBody'
/{workspace}/groups/{group_token}:
x-summary: Group
get:
operationId: getGroup
summary: Get a group
description: Gets a user `Group`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroup` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroup'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
tags:
- Groups
delete:
operationId: deleteGroup
summary: Delete a group
description: Deletes a user `Group`
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroup` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroup'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
tags:
- Groups
patch:
operationId: updateGroup
summary: Update a group
description: Update a user `Group` with the provided attributes
parameters:
- name: workspace
in: path
description: '`Workspace` username'
required: true
schema:
type: string
- name: group_token
in: path
description: '`UserGroup` token'
required: true
schema:
type: string
responses:
'404':
description: '`Membership` not found for `Workspace`'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/NotFound'
'200':
description: '`UserGroup` response'
content:
application/hal+json:
schema:
$ref: '#/components/schemas/UserGroup'
'401':
description: Unauthorized
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Unauthorized'
'403':
description: Forbidden
content:
application/hal+json:
schema:
$ref: '#/components/schemas/Forbidden'
'400':
description: Bad request
content:
application/hal+json:
schema:
$ref: '#/components/schemas/BadRequest'
tags:
- Groups
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateUserGroupRequestBody'
components:
schemas:
BadRequest:
required:
- id
- message
properties:
id:
type: string
enum:
- bad_request
message:
type: string
UserGroups:
properties:
pagination:
$ref: '#/components/schemas/Pagination'
_links:
$ref: '#/components/schemas/UserGroupsLinks'
_embedded:
$ref: '#/components/schemas/UserGroupsEmbeds'
required:
- _links
UserGroupMembershipsEmbeds: {}
CreateUserGroupRequestBody:
required:
- user_group
type: object
properties:
user_group:
description: The parameters for the created user group
type: object
properties:
name:
description: The name for the new user group
type: string
Unauthorized:
required:
- id
- message
properties:
id:
type: string
enum:
- unauthorized
message:
type: string
UserGroupMemberships:
properties:
pagination:
$ref: '#/components/schemas/Pagination'
_links:
$ref: '#/components/schemas/UserGroupMembershipsLinks'
_embedded:
$ref: '#/components/schemas/UserGroupMembershipsEmbeds'
required:
- _links
UserGroupsEmbeds: {}
UserGroupMembership:
properties:
token:
type: string
member_token:
type: string
_links:
$ref: '#/components/schemas/UserGroupMembershipLinks'
_embedded:
$ref: '#/components/schemas/UserGroupMembershipEmbeds'
required:
- _links
- token
- member_token
UserGroupsLinks:
properties:
next_page:
$ref: '#/components/schemas/Link'
prev_page:
$ref: '#/components/schemas/Link'
self:
$ref: '#/components/schemas/Link'
required:
- self
UserGroupLinks:
properties:
self:
$ref: '#/components/schemas/Link'
web:
$ref: '#/components/schemas/Link'
creator:
$ref: '#/components/schemas/Link'
group_memberships:
$ref: '#/components/schemas/Link'
membership_by_id:
$ref: '#/components/schemas/Link'
memberships_preview:
$ref: '#/components/schemas/Link'
required:
- self
- web
- group_memberships
- membership_by_id
- memberships_preview
UserGroupEmbeds: {}
CreateUserGroupMembershipRequestBody:
required:
- membership
type: object
properties:
membership:
description: The parameters for the new membership
type: object
required:
- member_token
properties:
member_token:
description: The token of the user to become a member
type: string
NotFound:
required:
- id
- message
properties:
id:
type: string
enum:
- not_found
message:
type: string
Link:
required:
- href
properties:
href:
type: string
templated:
type: boolean
default: false
Pagination:
required:
- first_page
- last_page
- total_pages
- total_count
properties:
first_page:
type: string
last_page:
type: string
total_pages:
type: integer
total_count:
type: integer
Forbidden:
required:
- id
- message
properties:
id:
type: string
enum:
- forbidden
message:
type: string
UserGroupMembershipsLinks:
properties:
next_page:
$ref: '#/components/schemas/Link'
prev_page:
$ref: '#/components/schemas/Link'
self:
$ref: '#/components/schemas/Link'
required:
- self
UserGroupMembershipEmbeds: {}
UserGroupMembershipLinks:
properties:
self:
$ref: '#/components/schemas/Link'
creator:
$ref: '#/components/schemas/Link'
member:
$ref: '#/components/schemas/Link'
user_group:
$ref: '#/components/schemas/Link'
required:
- self
- member
- user_group
UserGroup:
properties:
token:
type: string
group_type:
type: string
name:
type: string
description:
type: string
state:
type: string
member_count:
type: string
spaces_count:
type: string
data_sources_count:
type: string
managed:
type: string
_links:
$ref: '#/components/schemas/UserGroupLinks'
_embedded:
$ref: '#/components/schemas/UserGroupEmbeds'
required:
- _links
- token
- group_type
- name
- description
- state
- member_count
- spaces_count
- data_sources_count
- managed
UpdateUserGroupRequestBody:
required:
- user_group
type: object
properties:
user_group:
description: The parameters for the updated user group
type: object
properties:
name:
description: The new name for the user group
type: string
securitySchemes:
accessTokenAuth:
type: http
scheme: basic