Class WebhookMicrosoftTeamsFunctions
java.lang.Object
flexagon.fd.services.groovy.functions.BaseFunctions
flexagon.fd.services.groovy.functions.MicrosoftTeamsFunctions
flexagon.fd.services.groovy.functions.WebhookMicrosoftTeamsFunctions
-
Field Summary
Fields inherited from class flexagon.fd.services.groovy.functions.MicrosoftTeamsFunctions
APPROVE_STRING, FLEXDEPLOY_LOGO, REJECT_STRINGFields inherited from class flexagon.fd.services.groovy.functions.BaseFunctions
mFLOG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionmakePipelineStageCompletedMessage(Object pPayload) Generates a formatted message for the Pipeline Stage Complete Event for Teams messaging.Generates a formatted message for the Pipeline Stage Complete Event for Teams messaging.makeSnapshotCompleteMessage(Object pPayload) Generates a formatted message for the Snapshot Complete Event for Teams messaging.makeTaskCompletedMessage(Object pPayload, boolean approved) makeTaskCreatedMessage(Object pPayload) Generates a formatted message for the Task Created Event for Teams messaging.makeTaskCreatedMessageForWebhook(Object pPayload, String pFullUpdateTaskIncomingWebhookUrl) Generates a formatted message for the Task Created Event for Teams messaging.makeWorkflowCompletedMessage(Object pPayload) Generates a formatted message for the Workflow Completed Event for Teams messaging.makeWorkflowCompletedMessageForWebhook(Object pPayload) Generates a formatted message for the Workflow Completed Event for Teams messaging.voidApproves or rejects a task from an incoming Slack webhook payload.Methods inherited from class flexagon.fd.services.groovy.functions.MicrosoftTeamsFunctions
cleanup, createCalendarEvent, getGroovyKey, sendTeamsWebhookMessage, sendTeamsWebhookMessageMethods inherited from class flexagon.fd.services.groovy.functions.BaseFunctions
captureSecureValues, captureSecureValuesForLogFunction, decryptIntegrationInstance, doSimpleGet, findIntegrationInstanceByCode, getBinding, getLogFunctions, getServerBaseUrl, setBinding
-
Constructor Details
-
WebhookMicrosoftTeamsFunctions
-
-
Method Details
-
makePipelineStageCompletedMessage
public MicrosoftTeamsMessageCard makePipelineStageCompletedMessage(Object pPayload) throws FlexCheckedException Generates a formatted message for the Pipeline Stage Complete Event for Teams messaging.- Parameters:
pPayload- Event payload for the Snapshot Complete Event. Typically (EVENT.payload).- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error
-
makeTaskCreatedMessage
public MicrosoftTeamsMessageCard makeTaskCreatedMessage(Object pPayload) throws FlexCheckedException Generates a formatted message for the Task Created Event for Teams messaging.- Parameters:
pPayload- The task created payload.- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error
-
makeWorkflowCompletedMessage
public MicrosoftTeamsMessageCard makeWorkflowCompletedMessage(Object pPayload) throws FlexCheckedException Generates a formatted message for the Workflow Completed Event for Teams messaging.- Parameters:
pPayload- The workflow completed payload.- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error
-
makeSnapshotCompleteMessage
public MicrosoftTeamsMessageCard makeSnapshotCompleteMessage(Object pPayload) throws FlexCheckedException Generates a formatted message for the Snapshot Complete Event for Teams messaging.- Parameters:
pPayload- Event payload for the Snapshot Complete Event. Typically (EVENT.payload).- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error- Since:
- 5.5.0.2
-
makePipelineStageCompletedMessageForWebhook
public String makePipelineStageCompletedMessageForWebhook(Object pPayload) throws FlexCheckedException Generates a formatted message for the Pipeline Stage Complete Event for Teams messaging.- Parameters:
pPayload- Event payload for the Snapshot Complete Event. Typically (EVENT.payload).- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error- Since:
- 5.5.0.2
-
makeTaskCreatedMessageForWebhook
public String makeTaskCreatedMessageForWebhook(Object pPayload, String pFullUpdateTaskIncomingWebhookUrl) throws FlexCheckedException Generates a formatted message for the Task Created Event for Teams messaging.- Parameters:
pPayload- The task created payload.- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error- Since:
- 5.5.0.2
-
makeTaskCompletedMessage
public MicrosoftTeamsMessageCard makeTaskCompletedMessage(Object pPayload, boolean approved) throws FlexCheckedException - Throws:
FlexCheckedException
-
makeWorkflowCompletedMessageForWebhook
Generates a formatted message for the Workflow Completed Event for Teams messaging.- Parameters:
pPayload- The workflow completed payload.- Returns:
- Formatted message to be used with 'Send' methods.
- Throws:
FlexCheckedException- - Any execution error- Since:
- 5.5.0.2
-
updateTask
public void updateTask(Object pQueryParameters, Map<String, Object> pHeaders, String pTeamsMessagingAccountCode) throws FlexCheckedExceptionApproves or rejects a task from an incoming Slack webhook payload. This method expects the inbound webhook payload resulting from the makeTaskCreatedMessage formatted message. Works with Approval tasks only.- Parameters:
pQueryParameters- - The Query Parameters that came in to the Webhook - QUERY_PARAMSpHeaders- - The request headers that came into the webhookpTeamsMessagingAccountCode- - The messaging account code for the Teams account.- Throws:
FlexCheckedException- - Any execution error- Since:
- 5.5.0.2
-