Cross-Provider Workflow

Vantage Cost Anomaly to SendGrid Alert

Version 1.0.0

Read a Vantage cost anomaly alert and email finance via SendGrid.

1 workflow 2 source APIs 2 providers
View Spec View on GitHub ArazzoWorkflowsCross-Provider

Providers Orchestrated

vantage sendgrid

Workflows

anomaly-to-email
Fetch a Vantage anomaly alert, then email finance via SendGrid.
Reads a single Vantage anomaly alert and, when present, emails the finance team a spend-spike notification through SendGrid.
2 steps inputs: anomalyAlertToken, financeEmail, fromEmail outputs: anomalyAmount, emailStatus
1
get-anomaly
$sourceDescriptions.vantageCostApi.getAnomalyAlert
Retrieve the Vantage cost anomaly alert.
2
email-finance
$sourceDescriptions.sendgridApi.SendMail
Email the finance team about the anomaly via SendGrid.

Source API Descriptions

Arazzo Workflow Specification

fin-vantage-anomaly-to-sendgrid-alert.yml Raw ↑
arazzo: 1.0.1
info:
  title: Vantage Cost Anomaly to SendGrid Alert
  summary: Read a Vantage cost anomaly alert and email finance via SendGrid.
  description: >-
    A spend-anomaly notification workflow that reads a Vantage anomaly alert and
    sends an email to the finance team through SendGrid when an unexpected cloud
    cost spike is detected. Demonstrates routing a FinOps anomaly signal into an
    email communications provider for human follow-up.
  version: 1.0.0
sourceDescriptions:
  - name: vantageCostApi
    url: https://raw.githubusercontent.com/api-evangelist/vantage/refs/heads/main/openapi/vantage-cost-management-api-openapi.yml
    type: openapi
  - name: sendgridApi
    url: https://raw.githubusercontent.com/api-evangelist/sendgrid/refs/heads/main/openapi/tsg_mail_v3.yaml
    type: openapi
workflows:
  - workflowId: anomaly-to-email
    summary: Fetch a Vantage anomaly alert, then email finance via SendGrid.
    description: >-
      Reads a single Vantage anomaly alert and, when present, emails the finance
      team a spend-spike notification through SendGrid.
    inputs:
      type: object
      properties:
        anomalyAlertToken:
          type: string
        financeEmail:
          type: string
        fromEmail:
          type: string
    steps:
      - stepId: get-anomaly
        description: Retrieve the Vantage cost anomaly alert.
        operationId: $sourceDescriptions.vantageCostApi.getAnomalyAlert
        parameters:
          - name: anomaly_alert_token
            in: path
            value: $inputs.anomalyAlertToken
        successCriteria:
          - condition: $statusCode == 200
        outputs:
          anomalyAmount: $response.body#/amount
          anomalyToken: $response.body#/token
      - stepId: email-finance
        description: Email the finance team about the anomaly via SendGrid.
        operationId: $sourceDescriptions.sendgridApi.SendMail
        requestBody:
          contentType: application/json
          payload:
            personalizations:
              - to:
                  - email: $inputs.financeEmail
                subject: Cloud cost anomaly detected
            from:
              email: $inputs.fromEmail
            content:
              - type: text/plain
                value: A cost anomaly was detected in Vantage. Please review.
        successCriteria:
          - condition: $statusCode == 202
        outputs:
          emailStatus: $statusCode
    outputs:
      anomalyAmount: $steps.get-anomaly.outputs.anomalyAmount
      emailStatus: $steps.email-finance.outputs.emailStatus