Module: team

Copyright 2020 Parsable, Inc
API address: /api/teams
Functionality for Team-level configuration.

ModuleServicesData typesConstants
teamTeamService
Region
Team
TeamConfig
TeamModular
TeamStatusOptions

Data structures

Struct: TeamConfig

KeyFieldTypeDescriptionRequirednessDefault value
1requireReviewFlowboolif true, require use of the review flow rather than explicit publish() call for templates defaultfalse
2showStepHierarchyPosbooloptional
3defaultLocalestringoptional
4requireTemplateSetReviewFlowboolif true, require use of the review flow rather than explicit publish() call for template sets defaultfalse
5backendPdfGenbooldefaulttrue
6useWebSocketbooldefaulttrue
7emailSenderOverridestringoptional
8enableObserverRoleboolDeprecated defaultfalse
9enableTemplateDiffsbooloptional
10enableTemplateViewsbooloptional
11proxyRegionstringoptional
12useParsableCamerabooloptional
13previewPdfUrlstringoptional

Configuration parameters for a team

Struct: Team

KeyFieldTypeDescriptionRequirednessDefault value
1idstringdefault
2namestringdefault
3subdomainstringdefault
4owneruser.Userdefault
5configTeamConfigdefault
6createdAti64default
7updatedAti64default
8regionIdstringdefault
9isTrialbooldefault
10isDisabledbooldefault
11expireAti64default

Information about a team

Struct: TeamModular

KeyFieldTypeDescriptionRequirednessDefault value
1idstringdefault
2namestringdefault
3subdomainstringdefault
4createdAti64default
5updatedAti64default
6regionIdstringdefault
101owneruser.Useroptional
102configTeamConfigoptional

Information about a team, modular

Struct: Region

KeyFieldTypeDescriptionRequirednessDefault value
1idstringA region code, such as "us-west-2" or "eu-west-1" default
2apiHoststringThe hostname part of the REST API. The API itself is located at https://<apiHost>/api/ default
3sigHoststringAccess to real-time updates are via this host, and the websocket protocol. default
4staticHoststringdefault

Structure used to indicate the correct hostnames to contact, for customers with non-US deployments.

Struct: TeamStatusOptions

KeyFieldTypeDescriptionRequirednessDefault value
1isTrialbooloptional
2isTestbooloptional
3isDisabledbooloptional


Services

Service: TeamService

Function: TeamService.listAllRegions

list<string> listAllRegions()
    throws common.SystemException
Unauthenticated endpoint returning the list of available region ids

Function: TeamService.get

Team get(string teamId)
    throws common.SystemException
Get information about a team by ID; user must belong to the team

Function: TeamService.index

list<Team> index()
    throws common.SystemException
Returns the list of teams the current user belongs to

Function: TeamService.setTemplateApprovalWebhook

void setTemplateApprovalWebhook(string teamId,
                                string webhookUrl)
    throws common.SystemException
Sets the webhook to be used for template approval flow.

This webhook is invoked when a job template has been set to "Ready for approval" status. The webhookURL is called using POST, with JSON content like:
{
    "templateId": "TEMPLATE_GUID",
    "publicVersion": 3,
    "submitterId": "USER_GUID"
}


Call with an empty string to clear any previously configured webhook.

Function: TeamService.setTemplateSetApprovalWebhook

void setTemplateSetApprovalWebhook(string teamId,
                                   string webhookUrl)
    throws common.SystemException
Sets the webhook to be used for the template set approval flow.

This webhook is invoked when a template set has been set to "Ready for approval" status. The webhookURL is called using POST, with JSON content like:
{
    "templateSetId": "TEMPLATE_GUID",
    "publicVersion": 3,
    "submitterId": "USER_GUID"
}


Call with an empty string to clear any previously configured webhook.