SEDNA Workflow API API

The Workflow API API from SEDNA — 2 operation(s) for workflow api.

OpenAPI Specification

sedna-workflow-api-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  contact:
    name: Support
    url: https://support.sedna.com
  termsOfService: https://www.sedna.com/terms-of-service
  title: Sedna Authentication Workflow API API
  version: '2019-01-01'
servers:
- description: Platform endpoint
  url: https://{tenant}.sednanetwork.com/platform
  variables:
    tenant:
      default: example
      description: Your tenant's unique identifier
security:
- Basic: []
- OAuth: []
tags:
- name: Workflow API
paths:
  /2019-01-01/workflow:
    post:
      description: 'Create a workflow


        Required API Permissions: WORKFLOW_WRITE'
      operationId: createWorkflow
      parameters:
      - in: query
        name: include
        schema:
          type: string
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/WorkflowCreate'
      responses:
        default:
          content:
            application/json: {}
            application/vnd.api+json: {}
          description: default response
      tags:
      - Workflow API
    get:
      description: 'Fetch all WorkFlows belonging to a tenant


        Required API Permissions: WORKFLOW_READ'
      operationId: getWorkflows
      parameters:
      - in: query
        name: include
        schema:
          type: string
      responses:
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowCollection'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/WorkflowCollection'
          description: default response
      tags:
      - Workflow API
  /2019-01-01/workflow/{id}:
    delete:
      description: 'Delete a Workflow


        Required API Permissions: WORKFLOW_DELETE'
      operationId: deleteWorkflow
      parameters:
      - in: path
        name: id
        required: true
        schema:
          type: integer
          format: int64
      responses:
        default:
          content:
            application/json: {}
            application/vnd.api+json: {}
          description: default response
      tags:
      - Workflow API
    get:
      description: 'Fetch a single Workflow from its id


        Required API Permissions: WORKFLOW_READ'
      operationId: getWorkflow
      parameters:
      - in: path
        name: id
        required: true
        schema:
          type: integer
          format: int64
      - in: query
        name: include
        schema:
          type: string
      responses:
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowSingle'
            application/vnd.api+json:
              schema:
                $ref: '#/components/schemas/WorkflowSingle'
          description: default response
      tags:
      - Workflow API
    put:
      description: 'Update a Workflow


        Required API Permissions: WORKFLOW_WRITE'
      operationId: updateWorkflow
      parameters:
      - in: path
        name: id
        required: true
        schema:
          type: integer
          format: int64
      requestBody:
        content:
          '*/*':
            schema:
              $ref: '#/components/schemas/WorkflowUpdate'
      responses:
        default:
          content:
            application/json: {}
            application/vnd.api+json: {}
          description: default response
      tags:
      - Workflow API
components:
  schemas:
    WorkflowDefinition:
      type: object
      properties:
        rule:
          $ref: '#/components/schemas/RuleNode'
        triggerActions:
          type: array
          items:
            $ref: '#/components/schemas/TriggerAction'
    WorkflowSingleLinks:
      type: object
      properties:
        self:
          type: string
    WorkflowUpsertAttributes:
      type: object
      properties:
        definition:
          $ref: '#/components/schemas/WorkflowDefinition'
        description:
          type: string
        hideFromUi:
          type: boolean
        messageEventTriggerTypes:
          type: array
          items:
            type: string
            enum:
            - RECEIVED
            - SENT
          uniqueItems: true
        name:
          type: string
        teamInfo:
          $ref: '#/components/schemas/TeamInfo'
      required:
      - name
    ResourceObjectResponse:
      type: object
      properties:
        id:
          type: string
        type:
          type: string
    WorkflowResource:
      type: object
      properties:
        attributes:
          $ref: '#/components/schemas/WorkflowResourceAttributes'
        id:
          type: string
        links:
          $ref: '#/components/schemas/WorkflowResourceLinks'
        relationships:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/RelationshipObject'
        type:
          type: string
    WorkflowUpdateResource:
      type: object
      properties:
        attributes:
          $ref: '#/components/schemas/WorkflowUpsertAttributes'
        id:
          type: string
        type:
          type: string
      required:
      - id
    RelationshipObject:
      type: object
    WorkflowCollectionLinks:
      type: object
      properties:
        self:
          type: string
    DataSourceResultContext:
      type: object
      allOf:
      - $ref: '#/components/schemas/Context'
      - type: object
        properties:
          attributes:
            type: object
            additionalProperties:
              type: string
          id:
            type: string
    WorkflowCollection:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/WorkflowResource'
        included:
          type: array
          items:
            $ref: '#/components/schemas/ResourceObjectResponse'
        links:
          $ref: '#/components/schemas/WorkflowCollectionLinks'
    TriggerAction:
      type: object
      properties:
        action:
          $ref: '#/components/schemas/Action'
        triggers:
          type: array
          items:
            $ref: '#/components/schemas/Trigger'
    Context:
      type: object
      discriminator:
        propertyName: type
      properties:
        description:
          type: string
        triggers:
          type: array
          items:
            $ref: '#/components/schemas/Trigger'
        type:
          type: string
      required:
      - type
    WorkflowCreate:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/WorkflowCreateResource'
    DataSource:
      type: object
      properties:
        adapter:
          $ref: '#/components/schemas/DataSourceAdapter'
        all:
          type: array
          items:
            $ref: '#/components/schemas/DataSourceResultContext'
        basePath:
          type: string
        baseUri:
          type: string
        fields:
          type: object
          additionalProperties:
            type: string
        id:
          type: string
        name:
          type: string
        password:
          type: string
        triggers:
          type: array
          items:
            $ref: '#/components/schemas/Trigger'
        username:
          type: string
    WorkflowUpdate:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/WorkflowUpdateResource'
    Action:
      type: object
      discriminator:
        propertyName: type
      properties:
        type:
          type: string
      required:
      - type
    WorkflowMessage:
      type: object
      properties:
        attachmentNames:
          type: array
          items:
            type: string
        ccEmails:
          type: array
          items:
            type: string
        fromEmail:
          type: string
        htmlBody:
          type: string
        id:
          type: string
        subject:
          type: string
        textBody:
          type: string
        toEmails:
          type: array
          items:
            type: string
    DataSourceAdapter:
      type: object
    WorkflowSingle:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/WorkflowResource'
        included:
          type: array
          items:
            $ref: '#/components/schemas/ResourceObjectResponse'
        links:
          $ref: '#/components/schemas/WorkflowSingleLinks'
    TeamInfo:
      type: object
      discriminator:
        propertyName: type
      properties:
        type:
          type: string
      required:
      - type
    WorkflowCreateResource:
      type: object
      properties:
        attributes:
          $ref: '#/components/schemas/WorkflowUpsertAttributes'
        type:
          type: string
    RuleNode:
      type: object
      discriminator:
        propertyName: op
      properties:
        dataSources:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/DataSource'
          writeOnly: true
        messageNodes:
          $ref: '#/components/schemas/WorkflowMessage'
        op:
          type: string
      required:
      - op
    WorkflowResourceAttributes:
      type: object
      properties:
        createdAt:
          type: string
          format: date-time
        createdBy:
          type: string
        definition:
          $ref: '#/components/schemas/WorkflowDefinition'
        description:
          type: string
        hideFromUi:
          type: boolean
        messageEventTriggerTypes:
          type: array
          items:
            type: string
            enum:
            - RECEIVED
            - SENT
          uniqueItems: true
        name:
          type: string
        teamInfo:
          $ref: '#/components/schemas/TeamInfo'
    Trigger:
      type: object
      discriminator:
        propertyName: type
      properties:
        type:
          type: string
      required:
      - type
    WorkflowResourceLinks:
      type: object
      properties:
        self:
          type: string
  securitySchemes:
    Basic:
      description: The basic auth scheme only requires the API-Specific username/password to be set.
      scheme: basic
      type: http
    OAuth:
      description: This API prefers OAuth 2 with client credentials flow. You can create your credentials in the <a href='https://{tenant}.sednanetwork.com/platform/settings/api-credential-management'>Api Credential Management page</a>.
      flows:
        clientCredentials:
          scopes:
            CATEGORYTAG_DELETE: Delete category tags
            CATEGORYTAG_READ: Read category tags
            CATEGORYTAG_WRITE: Create and update category tags
            CHARTERING_DELETE: Delete chartering (Pulse) information
            CHARTERING_READ: Read chartering (Pulse) information
            CHARTERING_WRITE: Create chartering (Pulse) information
            COMMENT_READ: Read message comments
            COMPANY_READ: Read company info
            COMPANY_WRITE: Update company info (eg. signature)
            CONTACTGROUP_DELETE: Delete contact groups
            CONTACTGROUP_READ: Read contact groups
            CONTACTGROUP_WRITE: Create and update contact groups
            CONTACT_DELETE: Delete contacts
            CONTACT_READ: Read contacts
            CONTACT_WRITE: Create and update contacts
            CRMENTITY_DELETE: Delete CRM contacts
            CRMENTITY_READ: Read CRM contacts
            CRMENTITY_WRITE: Create and update CRM Contacts
            DOCUMENT_READ: Read and download attachments
            EVENT_READ: Read events from the events endpoint
            JOBREFERENCE_DELETE: Delete job references
            JOBREFERENCE_READ: Read job references
            JOBREFERENCE_WRITE: Create and update job references
            KEYWORD_DELETE: Delete custom keywords
            KEYWORD_READ: Read custom keywords
            KEYWORD_WRITE: Create and update custom keywords
            LEGAL_HOLD_DELETE: Delete legal holds
            LEGAL_HOLD_READ: Read legal holds
            LEGAL_HOLD_WRITE: Create and update legal holds
            MESSAGE_DELETE: Archive email messages
            MESSAGE_READ: Read (draft) email messages
            MESSAGE_RETENTION_SETTINGS_READ: Read message retention settings
            MESSAGE_RETENTION_SETTINGS_WRITE: Update message retention settings
            MESSAGE_WRITE: Create and send (draft) email messages
            PERSONAL_DATA_UNREDACTED_READ: Read unredacted emails with personal data
            QUARANTINED_MESSAGE_READ: Read quarantined email messages
            QUARANTINED_MESSAGE_WRITE: Release quarantined email messages
            RETENTION_POLICY_DELETE: Delete retention policies
            RETENTION_POLICY_READ: Read retention policies
            RETENTION_POLICY_WRITE: Create and update retention policies
            SAVEDSEARCH_DELETE: Remove saved searches
            SAVEDSEARCH_READ: Read saved search details
            SAVEDSEARCH_WRITE: Create and update saved searches
            TEAM_DELETE: Delete teams
            TEAM_READ: Read team details
            TEAM_WRITE: Create and update teams
            TEMPLATE_READ: Read templates
            USER_DELETE: Archive users
            USER_READ: Read user details
            USER_WRITE: Create and update users
            WORKFLOW_DELETE: Delete workflows
            WORKFLOW_READ: Read workflow details
            WORKFLOW_WRITE: Create and update workflows
          tokenUrl: https://{tenant}.sednanetwork.com/platform/oauth/token
      type: oauth2