openapi: 3.0.3
info:
title: Gencove Back array invitation API
version: v2
contact:
email: support@gencove.com
license:
name: Proprietary
description: API for Gencove REST service. Visit enterprise.gencove.com and docs.gencove.com for more information.
To work with Insomnia, you can generate a Gencove API key by clicking here. Once you have the API key and have imported the project in Insomnia as a Request Collection, enter the key in Insomnia under Manage Environment.
Run in Insomnia
servers:
- url: https://api.gencove.com
tags:
- name: invitation
paths:
/api/v2/invitations/:
get:
operationId: invitations_list
description: List invites for an organization.
parameters:
- name: limit
required: false
in: query
description: Number of results to return per page.
schema:
type: integer
- name: offset
required: false
in: query
description: The initial index from which to return the results.
schema:
type: integer
- in: query
name: status
schema:
type: string
enum:
- accepted
- all
- expired
- pending
- revoked
description: Filter invites by their status
tags:
- invitation
security:
- JWT: []
- API key: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/PaginatedInvitationList'
description: ''
post:
operationId: invitations_create
description: Invite Gencove user to actors's organization.
tags:
- invitation
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/CreateInvite'
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/CreateInvite'
multipart/form-data:
schema:
$ref: '#/components/schemas/CreateInvite'
required: true
security:
- JWT: []
- API key: []
responses:
'201':
content:
application/json:
schema:
$ref: '#/components/schemas/Invitation'
description: ''
/api/v2/invitations-token/{token}:
get:
operationId: invitations_token_retrieve
description: Get invitation details by token.
parameters:
- in: path
name: token
schema:
type: string
required: true
tags:
- invitation
security:
- JWT: []
- API key: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/InvitationDetails'
description: ''
patch:
operationId: invitations_token_partial_update
description: Handle invitation acceptance.
parameters:
- in: path
name: token
schema:
type: string
required: true
tags:
- invitation
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/PatchedInvitationDetails'
application/x-www-form-urlencoded:
schema:
$ref: '#/components/schemas/PatchedInvitationDetails'
multipart/form-data:
schema:
$ref: '#/components/schemas/PatchedInvitationDetails'
security:
- JWT: []
- API key: []
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/InvitationDetails'
description: ''
/api/v2/invitations/{invitation_id}:
delete:
operationId: invitations_destroy
description: 'Invitation details and management.
Retrieving is enabled for all users, even unauthorized ones.
Update and delete are enabled for logged-in users and only if they have
the appropriate relation to the invite.'
parameters:
- in: path
name: invitation_id
schema:
type: string
format: uuid
required: true
tags:
- invitation
security:
- JWT: []
- API key: []
responses:
'204':
description: No response body
components:
schemas:
InvitationDetails:
type: object
description: Represent invitation for invitee.
properties:
token:
type: string
readOnly: true
last_status:
allOf:
- $ref: '#/components/schemas/InvitationStatus'
readOnly: true
expires:
type: string
format: date-time
readOnly: true
organization:
$ref: '#/components/schemas/InviteOrganization'
role:
type: string
maxLength: 255
required:
- expires
- last_status
- organization
- role
- token
CreateInvite:
type: object
properties:
email:
type: string
format: email
role:
type: string
default: ''
required:
- email
InvitationActor:
type: object
properties:
id:
type: string
format: uuid
readOnly: true
name:
type: string
maxLength: 254
required:
- id
InvitationStatus:
type: object
properties:
id:
type: string
format: uuid
readOnly: true
status:
type: string
created:
type: string
format: date-time
actor:
allOf:
- $ref: '#/components/schemas/InvitationActor'
readOnly: true
required:
- actor
- id
- status
InviteOrganization:
type: object
properties:
id:
type: string
format: uuid
readOnly: true
name:
type: string
maxLength: 254
required:
- id
- name
PaginatedInvitationList:
type: object
required:
- results
properties:
meta:
type: object
properties:
count:
type: integer
next:
type: string
format: uri
nullable: true
previous:
type: string
format: uri
nullable: true
required:
- count
results:
type: array
items:
$ref: '#/components/schemas/Invitation'
PatchedInvitationDetails:
type: object
description: Represent invitation for invitee.
properties:
token:
type: string
readOnly: true
last_status:
allOf:
- $ref: '#/components/schemas/InvitationStatus'
readOnly: true
expires:
type: string
format: date-time
readOnly: true
organization:
$ref: '#/components/schemas/InviteOrganization'
role:
type: string
maxLength: 255
Invitation:
type: object
properties:
id:
type: string
format: uuid
readOnly: true
email:
type: string
format: email
nullable: true
maxLength: 254
last_status:
allOf:
- $ref: '#/components/schemas/InvitationStatus'
readOnly: true
expires:
type: string
format: date-time
readOnly: true
role:
type: string
maxLength: 255
required:
- expires
- id
- last_status
- role
securitySchemes:
API key:
type: apiKey
description: 'Authorization header content formated as: `Api-Key `
You can obtain new API key through Gencove''s web UI or `user-api-key` endpoint'
in: header
name: Authorization
JWT:
type: apiKey
description: 'Authorization header content formated as: `Bearer `
You can obtain access token using `jwt-create` endpoint.'
in: header
name: Authorization