Create Policy Template

createPolicyTemplate(
    companyId: ID, externalCompanyId: ID, name: String!, pdfFile: String!, category: PolicyCategory, tile: String,
		locales: [LanguageCode!],
		# This policy template will be shared with the owner's client if global is true
		global: Boolean,
		# You can use this option to restrict your template to a group of companies
		# These ids must be usecure company IDs and not those from your system
		companies: [ID!]
    action: PolicyCreateAction!
): PolicyTemplate!

enum PolicyCreateAction {
    saveDraft # Save the policy template to draft
    publish # Publish the policy template to live making it available for selection
}

Update Policy Template

updatePolicyTemplate(
    companyId: ID, externalCompanyId: ID, id: ID!, name: String, pdfFile: String, category: PolicyCategory, tile: String,
		locales: [LanguageCode!],
		global: Boolean, companies: [ID!]
    action: PolicyUpdateAction!
): Policy!

enum PolicyUpdateAction {
    # Saves your changes to new or existing draft version of this policy template
		saveDraft
		# Updates the existing draft copy of this policy template.
    # The mutation will fail if no draft copy exists
    updateDraft
		# Update the live policy template without publishing a new version.
		# The mutation will fail if the policy template is unpublished
    update
		# Same as update for policy templates as they do not have a version history
		# The mutation will fail if the policy template is unpublished
    publish
		# Publishes the existing draft copy of this policy template as a new version
    # The mutation will fail if no draft copy exists
    publishDraft
}

Publish Draft Policy Template

publishDraftPolicyTemplate(companyId: ID, externalCompanyId: ID, id: ID!): PolicyTemplate!

Discard Draft Policy Template

discardDraftPolicyTemplate(companyId: ID, externalCompanyId: ID, id: ID!): PolicyTemplate!

Delete Policy Templates

This mutation will only delete policy templates belonging to the target company specified by either companyId or externalCompanyId. Your account will be the target company if neither variable is supplied.

deletePolicyTemplates(companyId: ID, externalCompanyId: ID, policyTemplateIds: [ID!]!): Boolean!