CVS Health Capabilities

Naftiko 0.5 capability definitions for CVS Health - 100 capabilities showing integration workflows and service orchestrations.

Sort
Expand

Checks the status of a medical service prior authorization request in the Aetna utilization management system.

naftiko: "0.5"
info:
  title: Aetna Authorization Status
  version: "1.0"
  description: Checks the status of a medical service prior authorization request in the Aetna utilization management system.
  tags: [clinical, utilization-management, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_aetna_auth
        description: Returns authorization determination status, approved units, and expiration date.
        inputParameters:
          - name: auth_number
            in: query
            required: true
            type: string
        call:
          operationId: getAuthStatus
          input:
            authNumber: "{{auth_number}}"
        outputParameters:
          - name: status
            type: string
          - name: approved_units
            type: integer
          - name: expiration_date
            type: string
  consumes:
    - type: http
      baseUri: https://api.aetna.com/utilization-mgmt/v1
      authentication:
        type: bearer
        token: $secrets.aetna_um_token
      resources:
        - path: /authorizations/{authNumber}
          operations:
            - id: getAuthStatus
              method: GET

Retrieves open preventive care gaps for an Aetna member from the population health platform.

naftiko: "0.5"
info:
  title: Aetna Care Gap Status
  version: "1.0"
  description: Retrieves open preventive care gaps for an Aetna member from the population health platform.
  tags: [population-health, clinical, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_aetna_care_gaps
        description: Returns open care gaps with measure names and compliance deadlines.
        inputParameters:
          - name: member_id
            in: query
            required: true
            type: string
        call:
          operationId: getCareGaps
          input:
            memberId: "{{member_id}}"
        outputParameters:
          - name: care_gaps
            type: array
          - name: total_open
            type: integer
  consumes:
    - type: http
      baseUri: https://api.aetna.com/population-health/v1
      authentication:
        type: bearer
        token: $secrets.aetna_ph_token
      resources:
        - path: /members/{memberId}/care-gaps
          operations:
            - id: getCareGaps
              method: GET

Creates care management cases for high-risk Aetna members and assigns care managers.

naftiko: "0.5"
info:
  title: Aetna Care Management Case Creation
  version: "1.0"
  description: Creates care management cases for high-risk Aetna members and assigns care managers.
  tags: [clinical, population-health, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: create_aetna_care_case
        description: Gets risk profile, creates case, and notifies care manager.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: risk_category
            in: body
            required: true
            type: string
        steps:
          - name: get-risk
            call:
              operationId: getRiskProfile
              input:
                memberId: "{{member_id}}"
          - name: create-case
            call:
              operationId: createCareCase
              input:
                memberId: "{{member_id}}"
                riskCategory: "{{risk_category}}"
                score: "{{get-risk.risk_score}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "care-management"
                message: "Care case {{create-case.case_id}} for member {{member_id}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/population-health/v1
      authentication:
        type: bearer
        token: $secrets.aetna_ph_token
      resources:
        - path: /members/{memberId}/risk-profile
          operations:
            - id: getRiskProfile
              method: GET
    - type: http
      baseUri: https://api.aetna.com/care-management/v1
      authentication:
        type: bearer
        token: $secrets.aetna_cm_token
      resources:
        - path: /cases
          operations:
            - id: createCareCase
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Identifies members with unmanaged chronic conditions and creates outreach cases in Salesforce.

naftiko: "0.5"
info:
  title: Aetna Chronic Condition Outreach
  version: "1.0"
  description: Identifies members with unmanaged chronic conditions and creates outreach cases in Salesforce.
  tags: [population-health, clinical, healthcare, salesforce]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: trigger_aetna_chronic_outreach
        description: Queries high-risk members and creates care management outreach tasks.
        inputParameters:
          - name: condition
            in: body
            required: true
            type: string
          - name: risk_threshold
            in: body
            required: true
            type: number
        steps:
          - name: identify
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, risk_score FROM chronic_conditions WHERE condition='{{condition}}' AND risk_score > {{risk_threshold}}"
          - name: create-cases
            call:
              operationId: createCases
              input:
                members: "{{identify.results}}"
                caseType: "chronic_outreach"
                condition: "{{condition}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "care-management"
                message: "Chronic outreach for {{condition}} initiated."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Case
          operations:
            - id: createCases
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Retrieves the current processing status and adjudication details for an Aetna health insurance claim.

naftiko: "0.5"
info:
  title: Aetna Claim Status Lookup
  version: "1.0"
  description: Retrieves the current processing status and adjudication details for an Aetna health insurance claim.
  tags: [claims, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_aetna_claim_status
        description: Returns claim status, adjudication date, allowed amount, and patient responsibility.
        inputParameters:
          - name: claim_id
            in: query
            required: true
            type: string
          - name: member_id
            in: query
            required: true
            type: string
        call:
          operationId: getClaimStatus
          input:
            claimId: "{{claim_id}}"
            memberId: "{{member_id}}"
        outputParameters:
          - name: status
            type: string
          - name: adjudication_date
            type: string
          - name: allowed_amount
            type: number
  consumes:
    - type: http
      baseUri: https://api.aetna.com/claims/v2
      authentication:
        type: bearer
        token: $secrets.aetna_claims_token
      resources:
        - path: /claims/{claimId}
          operations:
            - id: getClaimStatus
              method: GET

Monitors nightly claims batch processing and creates incidents for failures.

naftiko: "0.5"
info:
  title: Aetna Claims Batch Monitor
  version: "1.0"
  description: Monitors nightly claims batch processing and creates incidents for failures.
  tags: [claims, itsm, healthcare, observability]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: monitor_aetna_batch
        description: Checks batch status, creates incidents, and alerts operations.
        inputParameters:
          - name: batch_name
            in: body
            required: true
            type: string
          - name: expected_time
            in: body
            required: true
            type: string
        steps:
          - name: check
            call:
              operationId: queryMetric
              input:
                query: "avg:batch.status{job:{{batch_name}}}"
                from: "{{expected_time}}"
          - name: incident
            call:
              operationId: createIncident
              input:
                short_description: "Batch {{batch_name}} failure"
                urgency: "1"
                category: "batch_processing"
          - name: alert
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "claims-ops"
                message: "Batch {{batch_name}} failed. Incident: {{incident.number}}."
  consumes:
    - type: http
      baseUri: https://api.datadoghq.com/api/v1
      authentication:
        type: apikey
        name: DD-API-KEY
        in: header
        key: $secrets.datadog_api_key
      resources:
        - path: /metrics/query
          operations:
            - id: queryMetric
              method: GET
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Retrieves denied claim details, submits an appeal to the Aetna appeals system, and notifies the member via Teams.

naftiko: "0.5"
info:
  title: Aetna Claims Denial Appeal Orchestrator
  version: "1.0"
  description: Retrieves denied claim details, submits an appeal to the Aetna appeals system, and notifies the member via Teams.
  tags: [claims, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_aetna_appeal
        description: Retrieves denial info, creates appeal, and sends member notification.
        inputParameters:
          - name: claim_id
            in: body
            required: true
            type: string
          - name: member_id
            in: body
            required: true
            type: string
          - name: appeal_reason
            in: body
            required: true
            type: string
        steps:
          - name: get-denial
            call:
              operationId: getClaimDenial
              input:
                claimId: "{{claim_id}}"
                memberId: "{{member_id}}"
          - name: submit-appeal
            call:
              operationId: createAppeal
              input:
                claimId: "{{claim_id}}"
                reason: "{{appeal_reason}}"
                denialCode: "{{get-denial.denial_code}}"
          - name: notify-member
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "aetna-member-alerts"
                message: "Appeal {{submit-appeal.appeal_id}} submitted for claim {{claim_id}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/claims/v2
      authentication:
        type: bearer
        token: $secrets.aetna_claims_token
      resources:
        - path: /claims/{claimId}/denial
          operations:
            - id: getClaimDenial
              method: GET
    - type: http
      baseUri: https://api.aetna.com/appeals/v1
      authentication:
        type: bearer
        token: $secrets.aetna_appeals_token
      resources:
        - path: /appeals
          operations:
            - id: createAppeal
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Looks up the current processing status of a health insurance claim in Aetna's claims management system and returns the adjudication status, denial reason if applicable, and payment details.

naftiko: "0.5"
info:
  label: "Aetna Claims Processing Status Lookup"
  description: "Looks up the current processing status of a health insurance claim in Aetna's claims management system and returns the adjudication status, denial reason if applicable, and payment details."
  tags:
    - healthcare
    - insurance
    - claims
    - aetna
    - lookup
capability:
  exposes:
    - type: mcp
      namespace: claims-management
      port: 8080
      tools:
        - name: get-claim-status
          description: "Given an Aetna claim ID, retrieve the adjudication status, payment amount, EOB date, and denial reason if the claim was denied. Use for member services inquiries and provider billing dispute resolution."
          inputParameters:
            - name: claim_id
              in: body
              type: string
              description: "Aetna claim ID in the format CLM-XXXXXXXXX."
            - name: member_id
              in: body
              type: string
              description: "Aetna member ID for authorization validation."
          call: aetna.get-claim
          with:
            claim_id: "{{claim_id}}"
            member_id: "{{member_id}}"
          outputParameters:
            - name: status
              type: string
              mapping: "$.claim.adjudicationStatus"
            - name: payment_amount
              type: string
              mapping: "$.claim.paymentAmount"
            - name: eob_date
              type: string
              mapping: "$.claim.explanationOfBenefitsDate"
            - name: denial_reason
              type: string
              mapping: "$.claim.denialReason"
  consumes:
    - type: http
      namespace: aetna
      baseUri: "https://api.aetna.com/health/v1"
      authentication:
        type: bearer
        token: "$secrets.aetna_api_token"
      resources:
        - name: claims
          path: "/claims/{{claim_id}}"
          inputParameters:
            - name: claim_id
              in: path
            - name: member_id
              in: query
          operations:
            - name: get-claim
              method: GET

Retrieves deductible and out-of-pocket accumulator balances for an Aetna member.

naftiko: "0.5"
info:
  title: Aetna Deductible Accumulator Lookup
  version: "1.0"
  description: Retrieves deductible and out-of-pocket accumulator balances for an Aetna member.
  tags: [claims, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_aetna_accumulators
        description: Returns current deductible met, remaining, and OOP max balances.
        inputParameters:
          - name: member_id
            in: query
            required: true
            type: string
          - name: plan_year
            in: query
            required: true
            type: string
        call:
          operationId: getAccumulators
          input:
            memberId: "{{member_id}}"
            planYear: "{{plan_year}}"
        outputParameters:
          - name: deductible_met
            type: number
          - name: deductible_max
            type: number
          - name: oop_met
            type: number
  consumes:
    - type: http
      baseUri: https://api.aetna.com/accumulators/v1
      authentication:
        type: bearer
        token: $secrets.aetna_claims_token
      resources:
        - path: /members/{memberId}/accumulators
          operations:
            - id: getAccumulators
              method: GET

Processes Aetna dental claims by verifying eligibility, adjudicating, and sending EOB notification.

naftiko: "0.5"
info:
  title: Aetna Dental Claim Processor
  version: "1.0"
  description: Processes Aetna dental claims by verifying eligibility, adjudicating, and sending EOB notification.
  tags: [claims, enrollment, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_aetna_dental_claim
        description: Verifies dental eligibility, adjudicates claim, and sends EOB.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: claim_id
            in: body
            required: true
            type: string
          - name: procedure_code
            in: body
            required: true
            type: string
        steps:
          - name: verify
            call:
              operationId: verifyDentalEligibility
              input:
                memberId: "{{member_id}}"
                procedureCode: "{{procedure_code}}"
          - name: adjudicate
            call:
              operationId: adjudicateClaim
              input:
                claimId: "{{claim_id}}"
                memberId: "{{member_id}}"
                eligible: "{{verify.eligible}}"
          - name: send-eob
            call:
              operationId: sendEmail
              input:
                to: "{{member_id}}@aetna-portal.com"
                subject: "Dental EOB — {{claim_id}}"
                body: "Claim processed. Allowed: ${{adjudicate.allowed_amount}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/dental/v1
      authentication:
        type: bearer
        token: $secrets.aetna_dental_token
      resources:
        - path: /eligibility
          operations:
            - id: verifyDentalEligibility
              method: GET
    - type: http
      baseUri: https://api.aetna.com/dental/v1
      authentication:
        type: bearer
        token: $secrets.aetna_dental_token
      resources:
        - path: /claims/{claimId}/adjudicate
          operations:
            - id: adjudicateClaim
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /me/sendMail
          operations:
            - id: sendEmail
              method: POST

Prepares employer group renewal by pulling utilization data and creating Salesforce opportunity.

naftiko: "0.5"
info:
  title: Aetna Employer Group Renewal
  version: "1.0"
  description: Prepares employer group renewal by pulling utilization data and creating Salesforce opportunity.
  tags: [enrollment, employer-group, healthcare, salesforce]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_aetna_renewal
        description: Queries utilization, calculates renewal, and creates opportunity.
        inputParameters:
          - name: group_id
            in: body
            required: true
            type: string
          - name: renewal_date
            in: body
            required: true
            type: string
        steps:
          - name: query-utilization
            call:
              operationId: executeQuery
              input:
                statement: "SELECT total_claims, loss_ratio FROM group_utilization WHERE group_id='{{group_id}}'"
          - name: calculate-renewal
            call:
              operationId: calculateRenewal
              input:
                groupId: "{{group_id}}"
                renewalDate: "{{renewal_date}}"
          - name: create-opportunity
            call:
              operationId: createOpportunity
              input:
                groupId: "{{group_id}}"
                rate: "{{calculate-renewal.proposed_rate}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.aetna.com/underwriting/v1
      authentication:
        type: bearer
        token: $secrets.aetna_underwriting_token
      resources:
        - path: /renewals
          operations:
            - id: calculateRenewal
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Opportunity
          operations:
            - id: createOpportunity
              method: POST

Triggers post-discharge follow-up for Aetna members including appointment scheduling and medication reconciliation.

naftiko: "0.5"
info:
  title: Aetna Member Discharge Follow-Up
  version: "1.0"
  description: Triggers post-discharge follow-up for Aetna members including appointment scheduling and medication reconciliation.
  tags: [clinical, population-health, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_aetna_discharge
        description: Gets discharge info, schedules follow-up, and triggers med recon.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: discharge_id
            in: body
            required: true
            type: string
        steps:
          - name: get-discharge
            call:
              operationId: getDischargeInfo
              input:
                dischargeId: "{{discharge_id}}"
          - name: schedule
            call:
              operationId: scheduleAppointment
              input:
                memberId: "{{member_id}}"
                type: "post_discharge"
                diagnosis: "{{get-discharge.diagnosis}}"
          - name: med-recon
            call:
              operationId: createMedReconciliation
              input:
                memberId: "{{member_id}}"
                meds: "{{get-discharge.medications}}"
  consumes:
    - type: http
      baseUri: https://api.aetna.com/clinical/v1
      authentication:
        type: bearer
        token: $secrets.aetna_clinical_token
      resources:
        - path: /discharges/{dischargeId}
          operations:
            - id: getDischargeInfo
              method: GET
    - type: http
      baseUri: https://api.aetna.com/scheduling/v1
      authentication:
        type: bearer
        token: $secrets.aetna_scheduling_token
      resources:
        - path: /appointments
          operations:
            - id: scheduleAppointment
              method: POST
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /medication-reconciliation
          operations:
            - id: createMedReconciliation
              method: POST

Verifies an Aetna member's eligibility and benefit coverage for a given date of service.

naftiko: "0.5"
info:
  title: Aetna Member Eligibility Check
  version: "1.0"
  description: Verifies an Aetna member's eligibility and benefit coverage for a given date of service.
  tags: [claims, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_aetna_eligibility
        description: Returns eligibility status and plan benefit summary.
        inputParameters:
          - name: member_id
            in: query
            required: true
            type: string
          - name: service_date
            in: query
            required: true
            type: string
        call:
          operationId: verifyEligibility
          input:
            memberId: "{{member_id}}"
            serviceDate: "{{service_date}}"
        outputParameters:
          - name: eligible
            type: boolean
          - name: plan_name
            type: string
          - name: copay
            type: number
  consumes:
    - type: http
      baseUri: https://api.aetna.com/eligibility/v2
      authentication:
        type: bearer
        token: $secrets.aetna_eligibility_token
      resources:
        - path: /members/{memberId}/eligibility
          operations:
            - id: verifyEligibility
              method: GET

Processes an Aetna member plan change by validating eligibility, updating enrollment, and syncing pharmacy benefits.

naftiko: "0.5"
info:
  title: Aetna Member Enrollment Change Workflow
  version: "1.0"
  description: Processes an Aetna member plan change by validating eligibility, updating enrollment, and syncing pharmacy benefits.
  tags: [enrollment, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_aetna_enrollment_change
        description: Validates eligibility, submits plan change, and synchronizes with Caremark.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: new_plan_id
            in: body
            required: true
            type: string
          - name: effective_date
            in: body
            required: true
            type: string
        steps:
          - name: validate
            call:
              operationId: verifyEligibility
              input:
                memberId: "{{member_id}}"
                serviceDate: "{{effective_date}}"
          - name: change-plan
            call:
              operationId: changePlan
              input:
                memberId: "{{member_id}}"
                newPlanId: "{{new_plan_id}}"
                effectiveDate: "{{effective_date}}"
          - name: sync-pharmacy
            call:
              operationId: updatePharmacyBenefit
              input:
                memberId: "{{member_id}}"
                planId: "{{new_plan_id}}"
  consumes:
    - type: http
      baseUri: https://api.aetna.com/eligibility/v2
      authentication:
        type: bearer
        token: $secrets.aetna_eligibility_token
      resources:
        - path: /members/{memberId}/eligibility
          operations:
            - id: verifyEligibility
              method: GET
    - type: http
      baseUri: https://api.aetna.com/enrollment/v1
      authentication:
        type: bearer
        token: $secrets.aetna_enrollment_token
      resources:
        - path: /members/{memberId}/plan-change
          operations:
            - id: changePlan
              method: POST
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /members/{memberId}/pharmacy-benefit
          operations:
            - id: updatePharmacyBenefit
              method: PUT

Logs an Aetna member grievance, assigns to resolution team, and tracks SLA in ServiceNow.

naftiko: "0.5"
info:
  title: Aetna Member Grievance Workflow
  version: "1.0"
  description: Logs an Aetna member grievance, assigns to resolution team, and tracks SLA in ServiceNow.
  tags: [member-services, itsm, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: log_aetna_grievance
        description: Creates grievance case, assigns specialist, and sends team notification.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: grievance_type
            in: body
            required: true
            type: string
          - name: description
            in: body
            required: true
            type: string
        steps:
          - name: create-case
            call:
              operationId: createIncident
              input:
                short_description: "Aetna grievance — {{grievance_type}}"
                description: "Member {{member_id}}: {{description}}"
                category: "grievance"
                urgency: "2"
          - name: assign-team
            call:
              operationId: updateIncident
              input:
                sys_id: "{{create-case.sys_id}}"
                assigned_to: "grievance-resolution-team"
          - name: notify-team
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "aetna-grievances"
                message: "New grievance {{create-case.number}} for member {{member_id}}."
  consumes:
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident/{sys_id}
          operations:
            - id: updateIncident
              method: PATCH
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Processes an Aetna member ID card reissue by validating enrollment and sending confirmation.

naftiko: "0.5"
info:
  title: Aetna Member ID Card Reissue
  version: "1.0"
  description: Processes an Aetna member ID card reissue by validating enrollment and sending confirmation.
  tags: [enrollment, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: reissue_aetna_id_card
        description: Validates enrollment, requests card, and sends confirmation email.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: reason
            in: body
            required: true
            type: string
        steps:
          - name: validate
            call:
              operationId: verifyEligibility
              input:
                memberId: "{{member_id}}"
                serviceDate: "2026-03-27"
          - name: request-card
            call:
              operationId: requestIdCard
              input:
                memberId: "{{member_id}}"
                reason: "{{reason}}"
          - name: confirm
            call:
              operationId: sendEmail
              input:
                to: "{{member_id}}@aetna-portal.com"
                subject: "ID Card Reissue"
                body: "Your new Aetna ID card has been requested."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/eligibility/v2
      authentication:
        type: bearer
        token: $secrets.aetna_eligibility_token
      resources:
        - path: /members/{memberId}/eligibility
          operations:
            - id: verifyEligibility
              method: GET
    - type: http
      baseUri: https://api.aetna.com/member-services/v1
      authentication:
        type: bearer
        token: $secrets.aetna_member_token
      resources:
        - path: /id-cards
          operations:
            - id: requestIdCard
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /me/sendMail
          operations:
            - id: sendEmail
              method: POST

Assigns or changes an Aetna member's primary care physician and updates enrollment records.

naftiko: "0.5"
info:
  title: Aetna Member PCP Assignment
  version: "1.0"
  description: Assigns or changes an Aetna member's primary care physician and updates enrollment records.
  tags: [enrollment, provider-network, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: assign_aetna_pcp
        description: Validates provider, updates assignment, and notifies care team.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: provider_npi
            in: body
            required: true
            type: string
        steps:
          - name: validate
            call:
              operationId: getProviderDetails
              input:
                providerNpi: "{{provider_npi}}"
          - name: assign
            call:
              operationId: assignPCP
              input:
                memberId: "{{member_id}}"
                providerNpi: "{{provider_npi}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "care-coordination"
                message: "PCP updated for member {{member_id}} to {{validate.name}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/provider-directory/v2
      authentication:
        type: bearer
        token: $secrets.aetna_provider_token
      resources:
        - path: /providers/{providerNpi}
          operations:
            - id: getProviderDetails
              method: GET
    - type: http
      baseUri: https://api.aetna.com/enrollment/v1
      authentication:
        type: bearer
        token: $secrets.aetna_enrollment_token
      resources:
        - path: /members/{memberId}/pcp
          operations:
            - id: assignPCP
              method: PUT
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Submits a prior authorization request to Aetna's utilization management system, creates a ServiceNow case to track the PA review, and notifies the requesting provider via email.

naftiko: "0.5"
info:
  label: "Aetna Member Prior Authorization Request"
  description: "Submits a prior authorization request to Aetna's utilization management system, creates a ServiceNow case to track the PA review, and notifies the requesting provider via email."
  tags:
    - healthcare
    - insurance
    - aetna
    - prior-authorization
    - servicenow
capability:
  exposes:
    - type: mcp
      namespace: utilization-management
      port: 8080
      tools:
        - name: submit-prior-authorization
          description: "Given a member ID, provider NPI, requested procedure/drug code, and clinical justification, submit a prior authorization request to Aetna and create a tracking case in ServiceNow. Use for provider portal PA submissions and care management workflows."
          inputParameters:
            - name: member_id
              in: body
              type: string
              description: "Aetna member ID."
            - name: provider_npi
              in: body
              type: string
              description: "National Provider Identifier of the requesting provider."
            - name: procedure_code
              in: body
              type: string
              description: "CPT or HCPCS procedure code requiring authorization."
            - name: diagnosis_code
              in: body
              type: string
              description: "ICD-10 diagnosis code supporting the request."
            - name: clinical_notes
              in: body
              type: string
              description: "Clinical justification summary for the authorization request."
          steps:
            - name: submit-pa-request
              type: call
              call: aetna-pa.create-authorization
              with:
                member_id: "{{member_id}}"
                provider_npi: "{{provider_npi}}"
                procedure_code: "{{procedure_code}}"
                diagnosis_code: "{{diagnosis_code}}"
                clinical_notes: "{{clinical_notes}}"
            - name: create-tracking-case
              type: call
              call: servicenow-pa.create-incident
              with:
                short_description: "Prior Authorization: {{procedure_code}} for member {{member_id}}"
                category: "Utilization Management"
                description: "PA Request ID: {{submit-pa-request.pa_request_id}}\nMember: {{member_id}}\nProvider NPI: {{provider_npi}}\nProcedure: {{procedure_code}}\nDiagnosis: {{diagnosis_code}}\nStatus: {{submit-pa-request.status}}"
  consumes:
    - type: http
      namespace: aetna-pa
      baseUri: "https://api.aetna.com/health/v1"
      authentication:
        type: bearer
        token: "$secrets.aetna_api_token"
      resources:
        - name: authorizations
          path: "/authorizations"
          operations:
            - name: create-authorization
              method: POST
    - type: http
      namespace: servicenow-pa
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST

Retrieves updated provider network roster data from Aetna and loads it into Snowflake for analytics and member-facing provider directory applications.

naftiko: "0.5"
info:
  label: "Aetna Network Provider Roster Sync"
  description: "Retrieves updated provider network roster data from Aetna and loads it into Snowflake for analytics and member-facing provider directory applications."
  tags:
    - healthcare
    - aetna
    - snowflake
    - data
    - provider-network
capability:
  exposes:
    - type: mcp
      namespace: provider-network
      port: 8080
      tools:
        - name: sync-provider-roster
          description: "Retrieve the latest provider network roster delta from Aetna's provider management API and load changed records into the Snowflake provider directory table. Use for nightly provider network synchronization to keep member-facing directories current."
          inputParameters:
            - name: network_id
              in: body
              type: string
              description: "Aetna network plan ID to sync (e.g., 'OPEN_CHOICE', 'HMO_PLUS')."
            - name: since_date
              in: body
              type: string
              description: "Sync delta since this date in YYYY-MM-DD format."
          steps:
            - name: get-roster-delta
              type: call
              call: aetna-providers.get-provider-roster
              with:
                network_id: "{{network_id}}"
                modified_since: "{{since_date}}"
            - name: load-to-snowflake
              type: call
              call: snowflake-providers.run-query
              with:
                statement: "MERGE INTO provider_directory.providers USING (SELECT * FROM TABLE(PARSE_JSON('{{get-roster-delta.providers}}'))) AS src ON providers.npi = src.npi WHEN MATCHED THEN UPDATE SET network_status=src.network_status, last_updated=CURRENT_TIMESTAMP() WHEN NOT MATCHED THEN INSERT (npi, name, specialty, network_id, network_status) VALUES (src.npi, src.name, src.specialty, '{{network_id}}', src.network_status)"
  consumes:
    - type: http
      namespace: aetna-providers
      baseUri: "https://api.aetna.com/health/v1"
      authentication:
        type: bearer
        token: "$secrets.aetna_api_token"
      resources:
        - name: provider-roster
          path: "/networks/{{network_id}}/providers"
          inputParameters:
            - name: network_id
              in: path
            - name: modified_since
              in: query
          operations:
            - name: get-provider-roster
              method: GET
    - type: http
      namespace: snowflake-providers
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST

Determines the network participation tier for a provider under an Aetna member's benefit plan.

naftiko: "0.5"
info:
  title: Aetna Network Tier Check
  version: "1.0"
  description: Determines the network participation tier for a provider under an Aetna member's benefit plan.
  tags: [provider-network, claims, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_aetna_network_tier
        description: Returns provider network tier, in-network status, and cost-sharing level.
        inputParameters:
          - name: provider_npi
            in: query
            required: true
            type: string
          - name: plan_id
            in: query
            required: true
            type: string
        call:
          operationId: getNetworkTier
          input:
            providerNpi: "{{provider_npi}}"
            planId: "{{plan_id}}"
        outputParameters:
          - name: tier
            type: string
          - name: in_network
            type: boolean
          - name: effective_date
            type: string
  consumes:
    - type: http
      baseUri: https://api.aetna.com/provider-directory/v2
      authentication:
        type: bearer
        token: $secrets.aetna_provider_token
      resources:
        - path: /providers/{providerNpi}/tier
          operations:
            - id: getNetworkTier
              method: GET

Retrieves a comprehensive benefit summary for an Aetna health plan including copays, deductibles, and coverage limits.

naftiko: "0.5"
info:
  title: Aetna Plan Benefit Summary
  version: "1.0"
  description: Retrieves a comprehensive benefit summary for an Aetna health plan including copays, deductibles, and coverage limits.
  tags: [enrollment, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_benefit_summary
        description: Returns plan benefit details including in-network and out-of-network cost-sharing.
        inputParameters:
          - name: plan_id
            in: query
            required: true
            type: string
          - name: coverage_type
            in: query
            required: true
            type: string
        call:
          operationId: getBenefitSummary
          input:
            planId: "{{plan_id}}"
            coverageType: "{{coverage_type}}"
        outputParameters:
          - name: benefits
            type: object
          - name: effective_date
            type: string
  consumes:
    - type: http
      baseUri: https://api.aetna.com/plans/v1
      authentication:
        type: bearer
        token: $secrets.aetna_plans_token
      resources:
        - path: /plans/{planId}/benefits
          operations:
            - id: getBenefitSummary
              method: GET

Submits a prior authorization request for a medical service, receives determination, and notifies the provider.

naftiko: "0.5"
info:
  title: Aetna Prior Authorization Workflow
  version: "1.0"
  description: Submits a prior authorization request for a medical service, receives determination, and notifies the provider.
  tags: [clinical, utilization-management, healthcare, communication]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: submit_aetna_prior_auth
        description: Submits prior auth, gets determination, and sends provider notification.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: service_code
            in: body
            required: true
            type: string
          - name: provider_npi
            in: body
            required: true
            type: string
        steps:
          - name: submit-auth
            call:
              operationId: createAuth
              input:
                memberId: "{{member_id}}"
                serviceCode: "{{service_code}}"
                providerNpi: "{{provider_npi}}"
          - name: notify-provider
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "provider-notifications"
                message: "Prior auth {{submit-auth.auth_number}} for member {{member_id}} — status: {{submit-auth.status}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/utilization-mgmt/v1
      authentication:
        type: bearer
        token: $secrets.aetna_um_token
      resources:
        - path: /authorizations
          operations:
            - id: createAuth
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Syncs provider credentialing status and alerts on upcoming expirations for the Aetna network.

naftiko: "0.5"
info:
  title: Aetna Provider Credentialing Sync
  version: "1.0"
  description: Syncs provider credentialing status and alerts on upcoming expirations for the Aetna network.
  tags: [provider-network, compliance, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: sync_aetna_credentialing
        description: Checks credentials, updates directory, and creates expiration alerts.
        inputParameters:
          - name: provider_npi
            in: body
            required: true
            type: string
        steps:
          - name: get-status
            call:
              operationId: getCredentialingStatus
              input:
                providerNpi: "{{provider_npi}}"
          - name: update-directory
            call:
              operationId: updateProvider
              input:
                providerNpi: "{{provider_npi}}"
                status: "{{get-status.status}}"
          - name: alert-expiring
            call:
              operationId: createIncident
              input:
                short_description: "Provider {{provider_npi}} credential expiring {{get-status.expiration_date}}"
                urgency: "3"
                category: "credentialing"
  consumes:
    - type: http
      baseUri: https://api.aetna.com/credentialing/v1
      authentication:
        type: bearer
        token: $secrets.aetna_cred_token
      resources:
        - path: /providers/{providerNpi}/status
          operations:
            - id: getCredentialingStatus
              method: GET
    - type: http
      baseUri: https://api.aetna.com/provider-directory/v2
      authentication:
        type: bearer
        token: $secrets.aetna_provider_token
      resources:
        - path: /providers/{providerNpi}
          operations:
            - id: updateProvider
              method: PUT
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

Searches the Aetna provider network directory by specialty and geographic location.

naftiko: "0.5"
info:
  title: Aetna Provider Directory Search
  version: "1.0"
  description: Searches the Aetna provider network directory by specialty and geographic location.
  tags: [provider-network, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: search_aetna_providers
        description: Returns matching in-network providers with addresses and accepting-new-patients status.
        inputParameters:
          - name: specialty
            in: query
            required: true
            type: string
          - name: zip_code
            in: query
            required: true
            type: string
          - name: radius
            in: query
            required: true
            type: integer
        call:
          operationId: searchProviders
          input:
            specialty: "{{specialty}}"
            zipCode: "{{zip_code}}"
            radius: "{{radius}}"
        outputParameters:
          - name: providers
            type: array
          - name: total_count
            type: integer
  consumes:
    - type: http
      baseUri: https://api.aetna.com/provider-directory/v2
      authentication:
        type: bearer
        token: $secrets.aetna_provider_token
      resources:
        - path: /providers/search
          operations:
            - id: searchProviders
              method: GET

Reconciles Aetna provider payments against contracted rates and flags discrepancies.

naftiko: "0.5"
info:
  title: Aetna Provider Payment Reconciliation
  version: "1.0"
  description: Reconciles Aetna provider payments against contracted rates and flags discrepancies.
  tags: [claims, provider-network, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: reconcile_aetna_payments
        description: Queries payments, compares rates, and creates discrepancy tickets.
        inputParameters:
          - name: provider_npi
            in: body
            required: true
            type: string
          - name: period
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT claim_id, paid, contracted FROM provider_payments WHERE npi='{{provider_npi}}' AND period='{{period}}'"
          - name: flag
            call:
              operationId: createIncident
              input:
                short_description: "Payment discrepancy for provider {{provider_npi}}"
                category: "payment_reconciliation"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

Tracks Medicare Advantage star rating metrics and creates improvement stories in Jira.

naftiko: "0.5"
info:
  title: Aetna Star Rating Tracker
  version: "1.0"
  description: Tracks Medicare Advantage star rating metrics and creates improvement stories in Jira.
  tags: [population-health, medicare, healthcare, jira]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: track_aetna_stars
        description: Queries star data and creates Jira stories for improvement.
        inputParameters:
          - name: contract_id
            in: body
            required: true
            type: string
          - name: target
            in: body
            required: true
            type: number
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT measure_id, score FROM star_ratings WHERE contract='{{contract_id}}' AND score < {{target}}"
          - name: create-story
            call:
              operationId: createIssue
              input:
                project: "STARS"
                issuetype: "Story"
                summary: "Improve star measure for contract {{contract_id}}"
                priority: "High"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.atlassian.net/rest/api/3
      authentication:
        type: basic
        username: $secrets.jira_user
        password: $secrets.jira_api_token
      resources:
        - path: /issue
          operations:
            - id: createIssue
              method: POST

Checks telehealth visit availability for Aetna members, books appointments, and sends confirmation.

naftiko: "0.5"
info:
  title: Aetna Telehealth Visit Coordinator
  version: "1.0"
  description: Checks telehealth visit availability for Aetna members, books appointments, and sends confirmation.
  tags: [clinical, telehealth, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: coordinate_telehealth
        description: Checks availability, books visit, and confirms with member.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: specialty
            in: body
            required: true
            type: string
          - name: preferred_date
            in: body
            required: true
            type: string
        steps:
          - name: check-availability
            call:
              operationId: getAvailability
              input:
                memberId: "{{member_id}}"
                specialty: "{{specialty}}"
                date: "{{preferred_date}}"
          - name: book-visit
            call:
              operationId: bookVisit
              input:
                memberId: "{{member_id}}"
                slotId: "{{check-availability.best_slot_id}}"
          - name: confirm
            call:
              operationId: sendEmail
              input:
                to: "{{member_id}}@aetna-portal.com"
                subject: "Telehealth Appointment Confirmed"
                body: "Your telehealth visit is scheduled for {{book-visit.appointment_time}}."
  consumes:
    - type: http
      baseUri: https://api.aetna.com/telehealth/v1
      authentication:
        type: bearer
        token: $secrets.aetna_telehealth_token
      resources:
        - path: /availability
          operations:
            - id: getAvailability
              method: GET
    - type: http
      baseUri: https://api.aetna.com/telehealth/v1
      authentication:
        type: bearer
        token: $secrets.aetna_telehealth_token
      resources:
        - path: /appointments
          operations:
            - id: bookVisit
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /me/sendMail
          operations:
            - id: sendEmail
              method: POST

Retrieves value-based care contract metrics and updates Salesforce account records with performance data.

naftiko: "0.5"
info:
  title: Aetna VBC Contract Performance Sync
  version: "1.0"
  description: Retrieves value-based care contract metrics and updates Salesforce account records with performance data.
  tags: [population-health, analytics, healthcare, salesforce]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: sync_vbc_performance
        description: Queries performance data and updates Salesforce.
        inputParameters:
          - name: contract_id
            in: body
            required: true
            type: string
          - name: period
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT quality_score, cost_savings FROM vbc_contracts WHERE contract_id='{{contract_id}}' AND period='{{period}}'"
          - name: update
            call:
              operationId: updateAccount
              input:
                contractId: "{{contract_id}}"
                data: "{{query.results}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Account
          operations:
            - id: updateAccount
              method: PATCH

Retrieves eligible employees from Workday for the open enrollment period and sends personalized Microsoft 365 email communications with benefits selection deadlines and enrollment links.

naftiko: "0.5"
info:
  label: "Annual Open Enrollment Benefits Communication"
  description: "Retrieves eligible employees from Workday for the open enrollment period and sends personalized Microsoft 365 email communications with benefits selection deadlines and enrollment links."
  tags:
    - hr
    - benefits
    - workday
    - open-enrollment
    - microsoft-365
capability:
  exposes:
    - type: mcp
      namespace: benefits-ops
      port: 8080
      tools:
        - name: send-open-enrollment-notifications
          description: "Given an open enrollment period ID and deadline date, retrieve all eligible employees from Workday and send personalized open enrollment email notifications via Microsoft 365. Use at the start of annual benefits enrollment to ensure all eligible employees receive enrollment instructions."
          inputParameters:
            - name: enrollment_period_id
              in: body
              type: string
              description: "Workday open enrollment period ID."
            - name: enrollment_deadline
              in: body
              type: string
              description: "Benefits enrollment deadline date in YYYY-MM-DD format."
            - name: enrollment_portal_url
              in: body
              type: string
              description: "URL to the benefits enrollment portal for employees."
          steps:
            - name: get-eligible-employees
              type: call
              call: workday-benefits.get-eligible-employees
              with:
                enrollment_period_id: "{{enrollment_period_id}}"
            - name: send-enrollment-notification
              type: call
              call: msgraph-benefits.send-email
              with:
                to: "all-employees@cvshealth.com"
                subject: "Action Required: Open Enrollment Closes {{enrollment_deadline}}"
                body: "CVS Health Open Enrollment is now open. Eligible employees ({{get-eligible-employees.count}} total): Please select your benefits by {{enrollment_deadline}} at {{enrollment_portal_url}}. No action means you keep your current elections."
  consumes:
    - type: http
      namespace: workday-benefits
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: eligible-employees
          path: "/cvs-health/openEnrollment/{{enrollment_period_id}}/eligibleEmployees"
          inputParameters:
            - name: enrollment_period_id
              in: path
          operations:
            - name: get-eligible-employees
              method: GET
    - type: http
      namespace: msgraph-benefits
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: send-mail
          path: "/users/hr@cvshealth.com/sendMail"
          operations:
            - name: send-email
              method: POST

When AWS Cost Anomaly Detection identifies an unexpected spend spike, creates a ServiceNow incident and notifies the cloud FinOps team in Microsoft Teams with cost breakdown details.

naftiko: "0.5"
info:
  label: "AWS Cost Anomaly Alert and Ticket"
  description: "When AWS Cost Anomaly Detection identifies an unexpected spend spike, creates a ServiceNow incident and notifies the cloud FinOps team in Microsoft Teams with cost breakdown details."
  tags:
    - cloud
    - finops
    - aws
    - servicenow
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: finops-ops
      port: 8080
      tools:
        - name: handle-aws-cost-anomaly
          description: "Given an AWS cost anomaly alert with account ID, service, and excess spend amount, create a ServiceNow incident for the FinOps team and notify the cloud operations Microsoft Teams channel. Use when AWS anomaly detection fires on unexpected spending."
          inputParameters:
            - name: aws_account_id
              in: body
              type: string
              description: "AWS account ID where the cost anomaly was detected."
            - name: service_name
              in: body
              type: string
              description: "AWS service with the cost anomaly (e.g., 'Amazon EC2', 'Amazon S3')."
            - name: excess_spend
              in: body
              type: string
              description: "Estimated excess spend amount in USD."
            - name: anomaly_id
              in: body
              type: string
              description: "AWS Cost Anomaly ID."
          steps:
            - name: create-finops-ticket
              type: call
              call: servicenow-finops.create-incident
              with:
                short_description: "AWS Cost Anomaly: {{service_name}} in {{aws_account_id}} — ${{excess_spend}} overage"
                category: "Cloud FinOps"
                urgency: "2"
                description: "Anomaly ID: {{anomaly_id}}\nAccount: {{aws_account_id}}\nService: {{service_name}}\nExcess Spend: ${{excess_spend}}"
            - name: notify-finops-team
              type: call
              call: msteams-finops.send-message
              with:
                channel_id: "cloud-finops-alerts"
                message: "AWS COST ANOMALY: {{service_name}} in account {{aws_account_id}} — ${{excess_spend}} above expected. SNOW: {{create-finops-ticket.number}} | Anomaly: {{anomaly_id}}"
  consumes:
    - type: http
      namespace: servicenow-finops
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msteams-finops
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Monitors application load and auto-scales AKS clusters for CVS digital platforms.

naftiko: "0.5"
info:
  title: Azure CVS Infrastructure Scaler
  version: "1.0"
  description: Monitors application load and auto-scales AKS clusters for CVS digital platforms.
  tags: [infrastructure, observability, healthcare, azure]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: scale_cvs_infra
        description: Checks load, scales cluster, and alerts team.
        inputParameters:
          - name: cluster
            in: body
            required: true
            type: string
          - name: cpu_threshold
            in: body
            required: true
            type: number
        steps:
          - name: check
            call:
              operationId: queryMetric
              input:
                query: "avg:kubernetes.cpu.usage{cluster:{{cluster}}}"
          - name: scale
            call:
              operationId: scaleNodePool
              input:
                cluster: "{{cluster}}"
                nodes: "{{check.recommended_nodes}}"
          - name: alert
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "platform-eng"
                message: "Cluster {{cluster}} scaled. CPU: {{check.value}}%."
  consumes:
    - type: http
      baseUri: https://api.datadoghq.com/api/v1
      authentication:
        type: apikey
        name: DD-API-KEY
        in: header
        key: $secrets.datadog_api_key
      resources:
        - path: /metrics/query
          operations:
            - id: queryMetric
              method: GET
    - type: http
      baseUri: https://management.azure.com/subscriptions/cvs-sub
      authentication:
        type: bearer
        token: $secrets.azure_mgmt_token
      resources:
        - path: /resourceGroups/digital/providers/Microsoft.ContainerService/managedClusters/{cluster}
          operations:
            - id: scaleNodePool
              method: PATCH
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Monitors 340B drug pricing program compliance by validating claims against eligible entities and flagging discrepancies.

naftiko: "0.5"
info:
  title: Caremark 340B Program Compliance
  version: "1.0"
  description: Monitors 340B drug pricing program compliance by validating claims against eligible entities and flagging discrepancies.
  tags: [pharmacy, compliance, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: audit_340b_compliance
        description: Queries 340B claims, validates against eligible entities, and creates audit reports.
        inputParameters:
          - name: covered_entity_id
            in: body
            required: true
            type: string
          - name: audit_period
            in: body
            required: true
            type: string
        steps:
          - name: query-claims
            call:
              operationId: executeQuery
              input:
                statement: "SELECT claim_id, ndc, price FROM claims_340b WHERE entity='{{covered_entity_id}}' AND period='{{audit_period}}'"
          - name: validate
            call:
              operationId: validate340BEligibility
              input:
                entityId: "{{covered_entity_id}}"
                claims: "{{query-claims.results}}"
          - name: create-report
            call:
              operationId: createContent
              input:
                type: "page"
                title: "340B Audit — {{covered_entity_id}} — {{audit_period}}"
                space: "COMPLIANCE"
                body: "{{validate.results}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.caremark.com/compliance/v1
      authentication:
        type: bearer
        token: $secrets.caremark_compliance_token
      resources:
        - path: /340b/validate
          operations:
            - id: validate340BEligibility
              method: POST
    - type: http
      baseUri: https://cvshealth.atlassian.net/wiki/rest/api
      authentication:
        type: basic
        username: $secrets.confluence_user
        password: $secrets.confluence_api_token
      resources:
        - path: /content
          operations:
            - id: createContent
              method: POST

Monitors medication adherence rates for chronic condition patients and triggers pharmacist outreach for non-adherent members.

naftiko: "0.5"
info:
  title: Caremark Adherence Monitoring
  version: "1.0"
  description: Monitors medication adherence rates for chronic condition patients and triggers pharmacist outreach for non-adherent members.
  tags: [pharmacy, population-health, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: monitor_adherence
        description: Queries adherence data, identifies gaps, and creates outreach tasks.
        inputParameters:
          - name: condition
            in: body
            required: true
            type: string
          - name: adherence_threshold
            in: body
            required: true
            type: number
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, pdc_rate, last_fill FROM adherence_metrics WHERE condition='{{condition}}' AND pdc_rate < {{adherence_threshold}}"
          - name: create-outreach
            call:
              operationId: createTasks
              input:
                members: "{{query.results}}"
                taskType: "adherence_outreach"
                condition: "{{condition}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-clinical"
                message: "Adherence outreach for {{condition}} initiated."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.caremark.com/clinical/v1
      authentication:
        type: bearer
        token: $secrets.caremark_clinical_token
      resources:
        - path: /outreach/tasks
          operations:
            - id: createTasks
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Monitors controlled substance dispensing patterns and flags potential abuse for review.

naftiko: "0.5"
info:
  title: Caremark Controlled Substance Monitoring
  version: "1.0"
  description: Monitors controlled substance dispensing patterns and flags potential abuse for review.
  tags: [pharmacy, compliance, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: monitor_controlled_substances
        description: Queries dispensing patterns, flags anomalies, and creates investigation cases.
        inputParameters:
          - name: drug_schedule
            in: body
            required: true
            type: string
          - name: lookback_days
            in: body
            required: true
            type: integer
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, ndc, fill_count, prescriber_count FROM controlled_rx WHERE schedule='{{drug_schedule}}' AND lookback={{lookback_days}} AND anomaly=true"
          - name: flag
            call:
              operationId: createIncident
              input:
                short_description: "Controlled substance monitoring alert — Schedule {{drug_schedule}}"
                urgency: "2"
                category: "controlled_substance"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-compliance"
                message: "Controlled substance alert flagged. Incident: {{flag.number}}."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Estimates the out-of-pocket cost for a prescription drug under a member's Caremark pharmacy benefit plan.

naftiko: "0.5"
info:
  title: Caremark Drug Cost Estimator
  version: "1.0"
  description: Estimates the out-of-pocket cost for a prescription drug under a member's Caremark pharmacy benefit plan.
  tags: [pharmacy, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: estimate_drug_cost
        description: Returns estimated copay, coinsurance, and deductible impact for a given drug and plan.
        inputParameters:
          - name: ndc_code
            in: query
            required: true
            type: string
          - name: member_id
            in: query
            required: true
            type: string
        call:
          operationId: estimateCost
          input:
            ndcCode: "{{ndc_code}}"
            memberId: "{{member_id}}"
        outputParameters:
          - name: copay
            type: number
          - name: coinsurance_pct
            type: number
          - name: deductible_applies
            type: boolean
  consumes:
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /drugs/{ndcCode}/cost-estimate
          operations:
            - id: estimateCost
              method: GET

Checks a new prescription against the member's medication history for interactions and creates a pharmacist alert.

naftiko: "0.5"
info:
  title: Caremark Drug Interaction Alert
  version: "1.0"
  description: Checks a new prescription against the member's medication history for interactions and creates a pharmacist alert.
  tags: [pharmacy, clinical, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_caremark_interactions
        description: Retrieves medication history, checks interactions, and creates alert if risks found.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: new_drug_ndc
            in: body
            required: true
            type: string
        steps:
          - name: get-history
            call:
              operationId: getMedicationHistory
              input:
                memberId: "{{member_id}}"
                monthsBack: "12"
          - name: check-interactions
            call:
              operationId: checkInteractions
              input:
                currentMeds: "{{get-history.medications}}"
                newDrug: "{{new_drug_ndc}}"
          - name: create-alert
            call:
              operationId: createIncident
              input:
                short_description: "Drug interaction alert for member {{member_id}} — drug {{new_drug_ndc}}"
                urgency: "2"
                category: "pharmacy"
  consumes:
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /members/{memberId}/medication-history
          operations:
            - id: getMedicationHistory
              method: GET
    - type: http
      baseUri: https://api.caremark.com/clinical-decision/v1
      authentication:
        type: bearer
        token: $secrets.caremark_clinical_token
      resources:
        - path: /drug-interactions
          operations:
            - id: checkInteractions
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

Searches the Caremark formulary for drug tier classification and coverage restrictions.

naftiko: "0.5"
info:
  title: Caremark Formulary Tier Lookup
  version: "1.0"
  description: Searches the Caremark formulary for drug tier classification and coverage restrictions.
  tags: [pharmacy, formulary, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: lookup_caremark_formulary
        description: Returns tier level, prior auth requirement, and quantity limits.
        inputParameters:
          - name: ndc_code
            in: query
            required: true
            type: string
          - name: formulary_id
            in: query
            required: true
            type: string
        call:
          operationId: getFormularyTier
          input:
            ndcCode: "{{ndc_code}}"
            formularyId: "{{formulary_id}}"
        outputParameters:
          - name: tier
            type: string
          - name: prior_auth_required
            type: boolean
          - name: quantity_limit
            type: integer
  consumes:
    - type: http
      baseUri: https://api.caremark.com/formulary/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /formulary/{ndcCode}
          operations:
            - id: getFormularyTier
              method: GET

Retrieves the current status and tracking information for a Caremark mail-order prescription.

naftiko: "0.5"
info:
  title: Caremark Mail Order Status
  version: "1.0"
  description: Retrieves the current status and tracking information for a Caremark mail-order prescription.
  tags: [pharmacy, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_mail_order_status
        description: Returns order status, tracking number, and estimated delivery date.
        inputParameters:
          - name: order_id
            in: query
            required: true
            type: string
        call:
          operationId: getOrderStatus
          input:
            orderId: "{{order_id}}"
        outputParameters:
          - name: status
            type: string
          - name: tracking_number
            type: string
          - name: estimated_delivery
            type: string
  consumes:
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /orders/{orderId}
          operations:
            - id: getOrderStatus
              method: GET

Identifies members eligible for medication therapy management, creates care plans, and schedules pharmacist consultations.

naftiko: "0.5"
info:
  title: Caremark Medication Therapy Management
  version: "1.0"
  description: Identifies members eligible for medication therapy management, creates care plans, and schedules pharmacist consultations.
  tags: [pharmacy, clinical, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: trigger_mtm_program
        description: Identifies eligible members, creates care plans, and schedules consultations.
        inputParameters:
          - name: eligibility_criteria
            in: body
            required: true
            type: string
          - name: program_id
            in: body
            required: true
            type: string
        steps:
          - name: query-eligible
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, medication_count, chronic_conditions FROM mtm_eligible WHERE {{eligibility_criteria}}"
          - name: create-plans
            call:
              operationId: createCarePlans
              input:
                members: "{{query-eligible.results}}"
                programId: "{{program_id}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "mtm-pharmacy"
                message: "MTM program {{program_id}} initiated. {{query-eligible.results}} members identified."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.caremark.com/clinical/v1
      authentication:
        type: bearer
        token: $secrets.caremark_clinical_token
      resources:
        - path: /care-plans
          operations:
            - id: createCarePlans
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Looks up a drug's formulary tier, prior authorization requirements, and step therapy protocol in the CVS Caremark pharmacy benefit management system.

naftiko: "0.5"
info:
  label: "Caremark PBM Drug Formulary Lookup"
  description: "Looks up a drug's formulary tier, prior authorization requirements, and step therapy protocol in the CVS Caremark pharmacy benefit management system."
  tags:
    - pharmacy
    - pbm
    - caremark
    - formulary
    - lookup
capability:
  exposes:
    - type: mcp
      namespace: pbm-formulary
      port: 8080
      tools:
        - name: get-drug-formulary-status
          description: "Given a drug NDC code and a plan ID, retrieve the formulary tier, PA requirements, quantity limits, and step therapy requirements from CVS Caremark PBM. Use for pharmacist clinical decision support and member benefit inquiries."
          inputParameters:
            - name: ndc_code
              in: body
              type: string
              description: "National Drug Code (NDC) in 11-digit format."
            - name: plan_id
              in: body
              type: string
              description: "Caremark benefit plan ID."
          call: caremark.get-formulary-status
          with:
            ndc: "{{ndc_code}}"
            plan_id: "{{plan_id}}"
          outputParameters:
            - name: formulary_tier
              type: string
              mapping: "$.formulary.tier"
            - name: requires_pa
              type: string
              mapping: "$.formulary.priorAuthorizationRequired"
            - name: step_therapy_required
              type: string
              mapping: "$.formulary.stepTherapyRequired"
            - name: quantity_limit
              type: string
              mapping: "$.formulary.quantityLimit"
  consumes:
    - type: http
      namespace: caremark
      baseUri: "https://api.caremark.com/pbm/v2"
      authentication:
        type: bearer
        token: "$secrets.caremark_api_token"
      resources:
        - name: formulary
          path: "/formulary/drugs/{{ndc}}"
          inputParameters:
            - name: ndc
              in: path
            - name: plan_id
              in: query
          operations:
            - name: get-formulary-status
              method: GET

Reconciles pharmacy benefit manager rebates against manufacturer contracts and flags variances.

naftiko: "0.5"
info:
  title: Caremark PBM Rebate Reconciliation
  version: "1.0"
  description: Reconciles pharmacy benefit manager rebates against manufacturer contracts and flags variances.
  tags: [pharmacy, claims, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: reconcile_pbm_rebates
        description: Queries rebate data, validates against contracts, and flags discrepancies.
        inputParameters:
          - name: manufacturer_id
            in: body
            required: true
            type: string
          - name: quarter
            in: body
            required: true
            type: string
        steps:
          - name: query-rebates
            call:
              operationId: executeQuery
              input:
                statement: "SELECT drug_ndc, units, rebate_amount FROM pbm_rebates WHERE manufacturer='{{manufacturer_id}}' AND quarter='{{quarter}}'"
          - name: validate-contract
            call:
              operationId: validateRebateContract
              input:
                manufacturerId: "{{manufacturer_id}}"
                rebates: "{{query-rebates.results}}"
          - name: flag-variance
            call:
              operationId: createIncident
              input:
                short_description: "Rebate variance for manufacturer {{manufacturer_id}}"
                category: "rebate_reconciliation"
                urgency: "3"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.caremark.com/contracts/v1
      authentication:
        type: bearer
        token: $secrets.caremark_contracts_token
      resources:
        - path: /rebates/validate
          operations:
            - id: validateRebateContract
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

Checks the status of a prescription transfer request between pharmacies in the Caremark network.

naftiko: "0.5"
info:
  title: Caremark Prescription Transfer Status
  version: "1.0"
  description: Checks the status of a prescription transfer request between pharmacies in the Caremark network.
  tags: [pharmacy, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_transfer_status
        description: Returns transfer status, originating and receiving pharmacy details.
        inputParameters:
          - name: transfer_id
            in: query
            required: true
            type: string
        call:
          operationId: getTransferStatus
          input:
            transferId: "{{transfer_id}}"
        outputParameters:
          - name: status
            type: string
          - name: from_pharmacy
            type: string
          - name: to_pharmacy
            type: string
  consumes:
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /transfers/{transferId}
          operations:
            - id: getTransferStatus
              method: GET

Bridges approved pharmacy prior authorizations to the claims adjudication system for coverage validation.

naftiko: "0.5"
info:
  title: Caremark Prior Auth to Claims Bridge
  version: "1.0"
  description: Bridges approved pharmacy prior authorizations to the claims adjudication system for coverage validation.
  tags: [pharmacy, claims, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: bridge_caremark_pa
        description: Retrieves approved PA, pushes to claims, and confirms activation.
        inputParameters:
          - name: auth_id
            in: body
            required: true
            type: string
          - name: claim_id
            in: body
            required: true
            type: string
        steps:
          - name: get-auth
            call:
              operationId: getPriorAuth
              input:
                authId: "{{auth_id}}"
          - name: update-claims
            call:
              operationId: updateClaimAuth
              input:
                claimId: "{{claim_id}}"
                authId: "{{auth_id}}"
                drug: "{{get-auth.drug_code}}"
          - name: confirm
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-ops"
                message: "PA {{auth_id}} activated for claim {{claim_id}}."
  consumes:
    - type: http
      baseUri: https://api.caremark.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.caremark_token
      resources:
        - path: /prior-authorizations/{authId}
          operations:
            - id: getPriorAuth
              method: GET
    - type: http
      baseUri: https://api.aetna.com/claims/v2
      authentication:
        type: bearer
        token: $secrets.aetna_claims_token
      resources:
        - path: /claims/{claimId}/authorization
          operations:
            - id: updateClaimAuth
              method: PUT
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Retrieves the status of a specialty medication order from the Caremark Specialty Pharmacy.

naftiko: "0.5"
info:
  title: Caremark Specialty Drug Status
  version: "1.0"
  description: Retrieves the status of a specialty medication order from the Caremark Specialty Pharmacy.
  tags: [pharmacy, clinical, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_specialty_status
        description: Returns order status, clinical review outcome, and delivery schedule.
        inputParameters:
          - name: specialty_order_id
            in: query
            required: true
            type: string
        call:
          operationId: getSpecialtyOrder
          input:
            orderId: "{{specialty_order_id}}"
        outputParameters:
          - name: status
            type: string
          - name: clinical_review
            type: string
          - name: next_delivery
            type: string
  consumes:
    - type: http
      baseUri: https://api.caremark.com/specialty/v1
      authentication:
        type: bearer
        token: $secrets.caremark_specialty_token
      resources:
        - path: /orders/{orderId}
          operations:
            - id: getSpecialtyOrder
              method: GET

Onboards a new patient to Caremark Specialty Pharmacy by verifying benefits, completing clinical intake, and scheduling first delivery.

naftiko: "0.5"
info:
  title: Caremark Specialty Onboarding Workflow
  version: "1.0"
  description: Onboards a new patient to Caremark Specialty Pharmacy by verifying benefits, completing clinical intake, and scheduling first delivery.
  tags: [pharmacy, clinical, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: onboard_specialty_patient
        description: Verifies benefits, completes intake, and schedules delivery.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
          - name: drug_ndc
            in: body
            required: true
            type: string
          - name: prescriber_npi
            in: body
            required: true
            type: string
        steps:
          - name: verify-benefits
            call:
              operationId: verifySpecialtyBenefit
              input:
                memberId: "{{member_id}}"
                drugNdc: "{{drug_ndc}}"
          - name: clinical-intake
            call:
              operationId: completeClinicalIntake
              input:
                memberId: "{{member_id}}"
                drugNdc: "{{drug_ndc}}"
                prescriberNpi: "{{prescriber_npi}}"
          - name: schedule-delivery
            call:
              operationId: scheduleFirstDelivery
              input:
                memberId: "{{member_id}}"
                drugNdc: "{{drug_ndc}}"
                intakeComplete: "{{clinical-intake.complete}}"
  consumes:
    - type: http
      baseUri: https://api.caremark.com/specialty/v1
      authentication:
        type: bearer
        token: $secrets.caremark_specialty_token
      resources:
        - path: /benefits/{memberId}
          operations:
            - id: verifySpecialtyBenefit
              method: GET
    - type: http
      baseUri: https://api.caremark.com/specialty/v1
      authentication:
        type: bearer
        token: $secrets.caremark_specialty_token
      resources:
        - path: /intake
          operations:
            - id: completeClinicalIntake
              method: POST
    - type: http
      baseUri: https://api.caremark.com/specialty/v1
      authentication:
        type: bearer
        token: $secrets.caremark_specialty_token
      resources:
        - path: /deliveries
          operations:
            - id: scheduleFirstDelivery
              method: POST

Searches Confluence for pharmacy operations runbooks and standard operating procedures.

naftiko: "0.5"
info:
  title: Confluence Pharmacy Ops Runbook Search
  version: "1.0"
  description: Searches Confluence for pharmacy operations runbooks and standard operating procedures.
  tags: [knowledge-management, pharmacy, confluence]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: search_pharmacy_runbooks
        description: Returns matching runbook pages with titles and links.
        inputParameters:
          - name: query
            in: query
            required: true
            type: string
          - name: space_key
            in: query
            required: true
            type: string
        call:
          operationId: searchContent
          input:
            cql: "space={{space_key}} AND type=page AND text~'{{query}}'"
            limit: "20"
        outputParameters:
          - name: results
            type: array
          - name: total_size
            type: integer
  consumes:
    - type: http
      baseUri: https://cvshealth.atlassian.net/wiki/rest/api
      authentication:
        type: basic
        username: $secrets.confluence_user
        password: $secrets.confluence_api_token
      resources:
        - path: /content/search
          operations:
            - id: searchContent
              method: GET

Aggregates clinical quality measures and publishes a report to Confluence for regulatory review.

naftiko: "0.5"
info:
  title: CVS Clinical Quality Reporting
  version: "1.0"
  description: Aggregates clinical quality measures and publishes a report to Confluence for regulatory review.
  tags: [clinical, analytics, healthcare, confluence]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: generate_cvs_quality_report
        description: Queries metrics and publishes to Confluence.
        inputParameters:
          - name: period
            in: body
            required: true
            type: string
          - name: measure_set
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT measure_code, numerator, denominator, rate FROM quality_measures WHERE period='{{period}}' AND set='{{measure_set}}'"
          - name: publish
            call:
              operationId: createContent
              input:
                type: "page"
                title: "Quality Report — {{period}}"
                space: "REG"
                body: "{{query.results}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.atlassian.net/wiki/rest/api
      authentication:
        type: basic
        username: $secrets.confluence_user
        password: $secrets.confluence_api_token
      resources:
        - path: /content
          operations:
            - id: createContent
              method: POST

Monitors data ingestion pipelines into the CVS analytics data lake and creates remediation incidents.

naftiko: "0.5"
info:
  title: CVS Data Lake Ingestion Monitor
  version: "1.0"
  description: Monitors data ingestion pipelines into the CVS analytics data lake and creates remediation incidents.
  tags: [analytics, observability, healthcare, azure]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: monitor_cvs_ingestion
        description: Checks pipeline metrics, creates incidents, and notifies data engineering.
        inputParameters:
          - name: pipeline
            in: body
            required: true
            type: string
          - name: max_lag
            in: body
            required: true
            type: integer
        steps:
          - name: check-pipeline
            call:
              operationId: queryMetric
              input:
                query: "avg:data_lake.lag{pipeline:{{pipeline}}}"
          - name: create-incident
            call:
              operationId: createIncident
              input:
                short_description: "Data ingestion lag for {{pipeline}}"
                urgency: "2"
                category: "data_engineering"
          - name: notify-team
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "data-engineering"
                message: "Ingestion alert: {{pipeline}} lag detected. Incident: {{create-incident.number}}."
  consumes:
    - type: http
      baseUri: https://api.datadoghq.com/api/v1
      authentication:
        type: apikey
        name: DD-API-KEY
        in: header
        key: $secrets.datadog_api_key
      resources:
        - path: /metrics/query
          operations:
            - id: queryMetric
              method: GET
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Detects member portal outages via Datadog, creates P1 incidents, and notifies the on-call team.

naftiko: "0.5"
info:
  title: CVS Digital Member Portal Incident Response
  version: "1.0"
  description: Detects member portal outages via Datadog, creates P1 incidents, and notifies the on-call team.
  tags: [itsm, observability, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: respond_portal_incident
        description: Checks portal health, creates P1 incident, and pages on-call.
        inputParameters:
          - name: service
            in: body
            required: true
            type: string
          - name: threshold
            in: body
            required: true
            type: number
        steps:
          - name: check
            call:
              operationId: queryMetric
              input:
                query: "avg:http.error_rate{service:{{service}}}"
          - name: incident
            call:
              operationId: createIncident
              input:
                short_description: "Member portal {{service}} error rate exceeded"
                urgency: "1"
                category: "application"
          - name: page
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "digital-oncall"
                message: "P1: Member portal {{service}} degraded. Incident: {{incident.number}}."
  consumes:
    - type: http
      baseUri: https://api.datadoghq.com/api/v1
      authentication:
        type: apikey
        name: DD-API-KEY
        in: header
        key: $secrets.datadog_api_key
      resources:
        - path: /metrics/query
          operations:
            - id: queryMetric
              method: GET
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Aggregates member satisfaction data and publishes NPS analysis to Confluence.

naftiko: "0.5"
info:
  title: CVS Member Satisfaction Analysis
  version: "1.0"
  description: Aggregates member satisfaction data and publishes NPS analysis to Confluence.
  tags: [population-health, analytics, healthcare, confluence]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: analyze_cvs_satisfaction
        description: Queries surveys and publishes report.
        inputParameters:
          - name: period
            in: body
            required: true
            type: string
          - name: region
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT question_id, avg_score, nps FROM surveys WHERE period='{{period}}' AND region='{{region}}'"
          - name: publish
            call:
              operationId: createContent
              input:
                type: "page"
                title: "Satisfaction Report — {{period}} — {{region}}"
                space: "QUALITY"
                body: "{{query.results}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.atlassian.net/wiki/rest/api
      authentication:
        type: basic
        username: $secrets.confluence_user
        password: $secrets.confluence_api_token
      resources:
        - path: /content
          operations:
            - id: createContent
              method: POST

Analyzes Aetna provider network adequacy by geography and creates remediation tasks in Jira.

naftiko: "0.5"
info:
  title: CVS Network Adequacy Analysis
  version: "1.0"
  description: Analyzes Aetna provider network adequacy by geography and creates remediation tasks in Jira.
  tags: [provider-network, analytics, healthcare, jira]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: analyze_cvs_network
        description: Queries network data and creates Jira stories for gaps.
        inputParameters:
          - name: state
            in: body
            required: true
            type: string
          - name: specialty
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT county, provider_count, member_count FROM network_adequacy WHERE state='{{state}}' AND specialty='{{specialty}}'"
          - name: create-story
            call:
              operationId: createIssue
              input:
                project: "NETWORK"
                issuetype: "Story"
                summary: "Network gap: {{specialty}} in {{state}}"
                priority: "High"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.atlassian.net/rest/api/3
      authentication:
        type: basic
        username: $secrets.jira_user
        password: $secrets.jira_api_token
      resources:
        - path: /issue
          operations:
            - id: createIssue
              method: POST

Synchronizes member interaction data across CVS retail, MinuteClinic, and Aetna digital channels into Salesforce.

naftiko: "0.5"
info:
  title: CVS Omnichannel Member Experience Sync
  version: "1.0"
  description: Synchronizes member interaction data across CVS retail, MinuteClinic, and Aetna digital channels into Salesforce.
  tags: [member-services, salesforce, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: sync_member_experience
        description: Retrieves interactions from all channels and updates the Salesforce member profile.
        inputParameters:
          - name: member_id
            in: body
            required: true
            type: string
        steps:
          - name: get-retail
            call:
              operationId: getRetailInteractions
              input:
                memberId: "{{member_id}}"
          - name: get-clinic
            call:
              operationId: getClinicVisits
              input:
                memberId: "{{member_id}}"
          - name: update-salesforce
            call:
              operationId: updateMemberProfile
              input:
                memberId: "{{member_id}}"
                retailData: "{{get-retail.interactions}}"
                clinicData: "{{get-clinic.visits}}"
  consumes:
    - type: http
      baseUri: https://api.cvs.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.cvs_pharmacy_token
      resources:
        - path: /members/{memberId}/interactions
          operations:
            - id: getRetailInteractions
              method: GET
    - type: http
      baseUri: https://api.minuteclinic.com/v1
      authentication:
        type: bearer
        token: $secrets.minuteclinic_token
      resources:
        - path: /members/{memberId}/visits
          operations:
            - id: getClinicVisits
              method: GET
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Contact
          operations:
            - id: updateMemberProfile
              method: PATCH

Identifies members due for immunizations and creates outreach campaigns through retail pharmacy locations.

naftiko: "0.5"
info:
  title: CVS Pharmacy Immunization Campaign
  version: "1.0"
  description: Identifies members due for immunizations and creates outreach campaigns through retail pharmacy locations.
  tags: [pharmacy, population-health, healthcare, salesforce]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: launch_immunization_campaign
        description: Queries due immunizations, creates campaign, and assigns store outreach.
        inputParameters:
          - name: vaccine_type
            in: body
            required: true
            type: string
          - name: region
            in: body
            required: true
            type: string
        steps:
          - name: query-due
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, last_dose_date FROM immunization_tracking WHERE vaccine='{{vaccine_type}}' AND region='{{region}}' AND status='due'"
          - name: create-campaign
            call:
              operationId: createCampaign
              input:
                name: "{{vaccine_type}} Campaign — {{region}}"
                members: "{{query-due.results}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-immunizations"
                message: "Immunization campaign for {{vaccine_type}} in {{region}} launched."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Campaign
          operations:
            - id: createCampaign
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Monitors pharmacy inventory levels, identifies low-stock medications, and triggers automated replenishment orders.

naftiko: "0.5"
info:
  title: CVS Pharmacy Low Stock Replenishment
  version: "1.0"
  description: Monitors pharmacy inventory levels, identifies low-stock medications, and triggers automated replenishment orders.
  tags: [pharmacy, retail, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: trigger_replenishment
        description: Checks inventory, creates replenishment order, and notifies store manager.
        inputParameters:
          - name: store_id
            in: body
            required: true
            type: string
          - name: threshold
            in: body
            required: true
            type: integer
        steps:
          - name: check-inventory
            call:
              operationId: queryLowStock
              input:
                storeId: "{{store_id}}"
                threshold: "{{threshold}}"
          - name: create-order
            call:
              operationId: createReplenishmentOrder
              input:
                storeId: "{{store_id}}"
                items: "{{check-inventory.low_stock_items}}"
          - name: notify-manager
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-operations"
                message: "Replenishment order {{create-order.order_id}} created for store {{store_id}}."
  consumes:
    - type: http
      baseUri: https://api.cvs.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.cvs_pharmacy_token
      resources:
        - path: /stores/{storeId}/inventory/low-stock
          operations:
            - id: queryLowStock
              method: GET
    - type: http
      baseUri: https://api.cvs.com/supply-chain/v1
      authentication:
        type: bearer
        token: $secrets.cvs_supply_token
      resources:
        - path: /replenishment-orders
          operations:
            - id: createReplenishmentOrder
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Tracks regulatory filing deadlines, submits filings, and creates audit entries.

naftiko: "0.5"
info:
  title: CVS Regulatory Filing Tracker
  version: "1.0"
  description: Tracks regulatory filing deadlines, submits filings, and creates audit entries.
  tags: [compliance, healthcare, regulatory]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: submit_cvs_filing
        description: Gets requirements, submits filing, and logs for audit.
        inputParameters:
          - name: filing_type
            in: body
            required: true
            type: string
          - name: state
            in: body
            required: true
            type: string
          - name: period
            in: body
            required: true
            type: string
        steps:
          - name: get-req
            call:
              operationId: getFilingRequirements
              input:
                filingType: "{{filing_type}}"
                state: "{{state}}"
                period: "{{period}}"
          - name: submit
            call:
              operationId: submitFiling
              input:
                filingType: "{{filing_type}}"
                state: "{{state}}"
                data: "{{get-req.data_package}}"
          - name: log
            call:
              operationId: createIncident
              input:
                short_description: "Filing submitted: {{filing_type}} — {{state}}"
                category: "regulatory"
                urgency: "3"
  consumes:
    - type: http
      baseUri: https://api.aetna.com/regulatory/v1
      authentication:
        type: bearer
        token: $secrets.aetna_regulatory_token
      resources:
        - path: /filings/requirements
          operations:
            - id: getFilingRequirements
              method: GET
    - type: http
      baseUri: https://api.aetna.com/regulatory/v1
      authentication:
        type: bearer
        token: $secrets.aetna_regulatory_token
      resources:
        - path: /filings/submit
          operations:
            - id: submitFiling
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

Detects anomalous prescription fill patterns at retail locations and creates investigation cases.

naftiko: "0.5"
info:
  title: CVS Retail Claims Fraud Detection
  version: "1.0"
  description: Detects anomalous prescription fill patterns at retail locations and creates investigation cases.
  tags: [claims, compliance, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: detect_retail_fraud
        description: Queries anomalies, creates SIU case, and notifies compliance.
        inputParameters:
          - name: store_id
            in: body
            required: true
            type: string
          - name: anomaly_type
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: executeQuery
              input:
                statement: "SELECT rx_number, ndc, fill_date FROM prescription_fills WHERE store_id='{{store_id}}' AND anomaly='{{anomaly_type}}'"
          - name: create-case
            call:
              operationId: createIncident
              input:
                short_description: "Pharmacy fraud alert — {{anomaly_type}} at store {{store_id}}"
                urgency: "1"
                category: "fraud"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "siu-pharmacy"
                message: "Fraud alert at store {{store_id}}: {{anomaly_type}}. Case: {{create-case.number}}."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Checks real-time inventory levels for a medication at a specific CVS retail pharmacy location.

naftiko: "0.5"
info:
  title: CVS Retail Pharmacy Inventory Check
  version: "1.0"
  description: Checks real-time inventory levels for a medication at a specific CVS retail pharmacy location.
  tags: [pharmacy, retail, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_pharmacy_inventory
        description: Returns current stock level, reorder status, and estimated restock date.
        inputParameters:
          - name: store_id
            in: query
            required: true
            type: string
          - name: ndc_code
            in: query
            required: true
            type: string
        call:
          operationId: checkInventory
          input:
            storeId: "{{store_id}}"
            ndcCode: "{{ndc_code}}"
        outputParameters:
          - name: in_stock
            type: boolean
          - name: quantity_on_hand
            type: integer
          - name: restock_date
            type: string
  consumes:
    - type: http
      baseUri: https://api.cvs.com/pharmacy/v1
      authentication:
        type: bearer
        token: $secrets.cvs_pharmacy_token
      resources:
        - path: /stores/{storeId}/inventory/{ndcCode}
          operations:
            - id: checkInventory
              method: GET

Finds nearby CVS pharmacy and MinuteClinic locations with hours and services offered.

naftiko: "0.5"
info:
  title: CVS Store Locator
  version: "1.0"
  description: Finds nearby CVS pharmacy and MinuteClinic locations with hours and services offered.
  tags: [retail, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: find_cvs_stores
        description: Returns nearby store locations with address, hours, pharmacy status, and MinuteClinic availability.
        inputParameters:
          - name: zip_code
            in: query
            required: true
            type: string
          - name: radius_miles
            in: query
            required: true
            type: integer
        call:
          operationId: findStores
          input:
            zipCode: "{{zip_code}}"
            radiusMiles: "{{radius_miles}}"
        outputParameters:
          - name: stores
            type: array
          - name: total_count
            type: integer
  consumes:
    - type: http
      baseUri: https://api.cvs.com/locations/v1
      authentication:
        type: bearer
        token: $secrets.cvs_locations_token
      resources:
        - path: /stores/search
          operations:
            - id: findStores
              method: GET

Triggers a Databricks ML pipeline for pharmacy claims prediction and refreshes the analytics dashboard.

naftiko: "0.5"
info:
  title: Databricks CVS Claims ML Pipeline
  version: "1.0"
  description: Triggers a Databricks ML pipeline for pharmacy claims prediction and refreshes the analytics dashboard.
  tags: [analytics, pharmacy, healthcare, databricks]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: trigger_cvs_ml_pipeline
        description: Starts ML job, refreshes dashboard, and notifies data science team.
        inputParameters:
          - name: pipeline_id
            in: body
            required: true
            type: string
          - name: model_version
            in: body
            required: true
            type: string
        steps:
          - name: run
            call:
              operationId: triggerJob
              input:
                pipelineId: "{{pipeline_id}}"
                parameters: "model={{model_version}}"
          - name: refresh
            call:
              operationId: refreshDataset
              input:
                datasetId: "pharmacy-predictions"
                workspaceId: "analytics"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "data-science"
                message: "ML pipeline {{pipeline_id}} complete ({{model_version}}). Dashboard refreshed."
  consumes:
    - type: http
      baseUri: https://cvshealth-databricks.azuredatabricks.net/api/2.1
      authentication:
        type: bearer
        token: $secrets.databricks_token
      resources:
        - path: /jobs/run-now
          operations:
            - id: triggerJob
              method: POST
    - type: http
      baseUri: https://api.powerbi.com/v1.0/myorg
      authentication:
        type: bearer
        token: $secrets.powerbi_token
      resources:
        - path: /groups/analytics/datasets/pharmacy-predictions/refreshes
          operations:
            - id: refreshDataset
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Queries Datadog for application health metrics across CVS Health digital platform services.

naftiko: "0.5"
info:
  title: Datadog CVS Platform Health Query
  version: "1.0"
  description: Queries Datadog for application health metrics across CVS Health digital platform services.
  tags: [observability, datadog, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: query_platform_health
        description: Returns error rates, latency percentiles, and throughput for a specified service.
        inputParameters:
          - name: service_name
            in: query
            required: true
            type: string
          - name: time_range
            in: query
            required: true
            type: string
        call:
          operationId: queryMetric
          input:
            query: "avg:service.errors{service:{{service_name}}}"
            from: "{{time_range}}"
        outputParameters:
          - name: error_rate
            type: number
          - name: p99_latency
            type: number
          - name: requests_per_sec
            type: number
  consumes:
    - type: http
      baseUri: https://api.datadoghq.com/api/v1
      authentication:
        type: apikey
        name: DD-API-KEY
        in: header
        key: $secrets.datadog_api_key
      resources:
        - path: /metrics/query
          operations:
            - id: queryMetric
              method: GET

When a critical defect is filed in Jira for CVS Health digital platforms (app or website), automatically creates a ServiceNow P1 incident and alerts the digital engineering team in Microsoft Teams.

naftiko: "0.5"
info:
  label: "Digital Health App Defect Triage"
  description: "When a critical defect is filed in Jira for CVS Health digital platforms (app or website), automatically creates a ServiceNow P1 incident and alerts the digital engineering team in Microsoft Teams."
  tags:
    - devops
    - digital-health
    - jira
    - servicenow
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: digital-ops
      port: 8080
      tools:
        - name: triage-digital-defect
          description: "Given a Jira critical defect ID for the CVS digital platform, create a corresponding ServiceNow incident for operations tracking and notify the digital engineering on-call channel in Teams. Use when the CVS mobile app, website, or digital pharmacy portal has a critical production defect."
          inputParameters:
            - name: jira_issue_key
              in: body
              type: string
              description: "Jira issue key for the critical digital defect (e.g., 'DIGI-5432')."
            - name: platform
              in: body
              type: string
              description: "Affected digital platform: MOBILE_APP, WEBSITE, or PHARMACY_PORTAL."
          steps:
            - name: get-defect
              type: call
              call: jira-digital.get-issue
              with:
                issue_key: "{{jira_issue_key}}"
            - name: create-ops-incident
              type: call
              call: servicenow-digital.create-incident
              with:
                short_description: "Digital P1: {{get-defect.summary}} on {{platform}}"
                category: "Digital Platform"
                urgency: "1"
                description: "Jira: {{jira_issue_key}}\nPlatform: {{platform}}\nSummary: {{get-defect.summary}}\nReporter: {{get-defect.reporter}}\nAffected Users: {{get-defect.affected_users}}"
            - name: alert-digital-team
              type: call
              call: msteams-digital.send-message
              with:
                channel_id: "digital-oncall"
                message: "CRITICAL DIGITAL DEFECT: {{get-defect.summary}} | Platform: {{platform}} | Jira: {{jira_issue_key}} | SNOW: {{create-ops-incident.number}}"
  consumes:
    - type: http
      namespace: jira-digital
      baseUri: "https://cvshealth.atlassian.net/rest/api/3"
      authentication:
        type: basic
        username: "$secrets.jira_user"
        password: "$secrets.jira_api_token"
      resources:
        - name: issues
          path: "/issue/{{issue_key}}"
          inputParameters:
            - name: issue_key
              in: path
          operations:
            - name: get-issue
              method: GET
    - type: http
      namespace: servicenow-digital
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msteams-digital
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

When an employee is terminated in Workday, disables the Microsoft 365 account, revokes Salesforce license, and creates a ServiceNow offboarding checklist task.

naftiko: "0.5"
info:
  label: "Employee Offboarding Access Revocation"
  description: "When an employee is terminated in Workday, disables the Microsoft 365 account, revokes Salesforce license, and creates a ServiceNow offboarding checklist task."
  tags:
    - hr
    - offboarding
    - workday
    - salesforce
    - servicenow
capability:
  exposes:
    - type: mcp
      namespace: hr-offboarding
      port: 8080
      tools:
        - name: deprovision-terminated-employee
          description: "Given a Workday worker ID for a terminated employee, disable the Microsoft 365 account, remove Salesforce license assignment, and create a ServiceNow offboarding checklist. Use immediately upon confirmed termination to ensure access revocation."
          inputParameters:
            - name: worker_id
              in: body
              type: string
              description: "Workday worker ID of the terminated employee."
          steps:
            - name: get-worker
              type: call
              call: workday-offboard.get-worker
              with:
                worker_id: "{{worker_id}}"
            - name: disable-m365-account
              type: call
              call: msgraph-offboard.disable-user
              with:
                user_principal_name: "{{get-worker.work_email}}"
                account_enabled: "false"
            - name: create-offboarding-task
              type: call
              call: servicenow-offboard.create-incident
              with:
                short_description: "Employee Offboarding: {{get-worker.full_name}}"
                category: "HR"
                description: "Worker: {{worker_id}}\nEmployee: {{get-worker.full_name}}\nLast Day: {{get-worker.termination_date}}\nDepartment: {{get-worker.department}}\nM365 disabled: {{disable-m365-account.status}}"
  consumes:
    - type: http
      namespace: workday-offboard
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: workers
          path: "/cvs-health/workers/{{worker_id}}"
          inputParameters:
            - name: worker_id
              in: path
          operations:
            - name: get-worker
              method: GET
    - type: http
      namespace: msgraph-offboard
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: users
          path: "/users/{{user_principal_name}}"
          inputParameters:
            - name: user_principal_name
              in: path
          operations:
            - name: disable-user
              method: PATCH
    - type: http
      namespace: servicenow-offboard
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST

On a GitHub Actions pipeline failure on the main branch, creates a Jira bug, posts an alert to the engineering Microsoft Teams channel, and records the failure in Snowflake for trend analysis.

naftiko: "0.5"
info:
  label: "GitHub CI Pipeline Failure Alert"
  description: "On a GitHub Actions pipeline failure on the main branch, creates a Jira bug, posts an alert to the engineering Microsoft Teams channel, and records the failure in Snowflake for trend analysis."
  tags:
    - devops
    - cicd
    - github
    - jira
    - snowflake
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: devops-ops
      port: 8080
      tools:
        - name: handle-pipeline-failure
          description: "Given a GitHub Actions workflow failure on the main branch, create a Jira bug for the engineering team, post an alert to the Teams engineering channel, and log the failure event in Snowflake for pipeline reliability tracking. Use as part of the CI/CD failure notification pipeline."
          inputParameters:
            - name: repo_name
              in: body
              type: string
              description: "GitHub repository name where the pipeline failed."
            - name: workflow_name
              in: body
              type: string
              description: "GitHub Actions workflow name that failed."
            - name: run_id
              in: body
              type: string
              description: "GitHub Actions workflow run ID."
            - name: commit_sha
              in: body
              type: string
              description: "Commit SHA that triggered the failed run."
            - name: log_url
              in: body
              type: string
              description: "URL to the GitHub Actions run log."
          steps:
            - name: create-jira-bug
              type: call
              call: jira.create-issue
              with:
                project_key: "ENG"
                issuetype: "Bug"
                summary: "CI Failure: {{workflow_name}} on {{repo_name}}"
                description: "Repository: {{repo_name}}\nWorkflow: {{workflow_name}}\nRun ID: {{run_id}}\nCommit: {{commit_sha}}\nLog: {{log_url}}"
            - name: notify-engineering
              type: call
              call: msteams-eng.send-message
              with:
                channel_id: "engineering-alerts"
                message: "CI FAILURE: {{workflow_name}} on {{repo_name}} | Commit: {{commit_sha}} | Jira: {{create-jira-bug.key}} | Logs: {{log_url}}"
            - name: log-failure
              type: call
              call: snowflake-devops.run-query
              with:
                statement: "INSERT INTO devops.pipeline_failures (repo_name, workflow_name, run_id, commit_sha, failed_at, jira_key) VALUES ('{{repo_name}}', '{{workflow_name}}', '{{run_id}}', '{{commit_sha}}', CURRENT_TIMESTAMP(), '{{create-jira-bug.key}}')"
  consumes:
    - type: http
      namespace: jira
      baseUri: "https://cvshealth.atlassian.net/rest/api/3"
      authentication:
        type: basic
        username: "$secrets.jira_user"
        password: "$secrets.jira_api_token"
      resources:
        - name: issues
          path: "/issue"
          operations:
            - name: create-issue
              method: POST
    - type: http
      namespace: msteams-eng
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST
    - type: http
      namespace: snowflake-devops
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST

Orchestrates CVS digital application releases via GitHub Actions and ServiceNow change management.

naftiko: "0.5"
info:
  title: GitHub CVS App Release Workflow
  version: "1.0"
  description: Orchestrates CVS digital application releases via GitHub Actions and ServiceNow change management.
  tags: [devops, digital, healthcare, github]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: release_cvs_app
        description: Triggers build, creates change request, and notifies team.
        inputParameters:
          - name: repository
            in: body
            required: true
            type: string
          - name: release_tag
            in: body
            required: true
            type: string
        steps:
          - name: build
            call:
              operationId: triggerWorkflow
              input:
                repo: "{{repository}}"
                workflow: "release.yml"
                ref: "{{release_tag}}"
          - name: change
            call:
              operationId: createChangeRequest
              input:
                short_description: "Release {{release_tag}} for {{repository}}"
                category: "software"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "digital-releases"
                message: "Release {{release_tag}} initiated. Change: {{change.number}}."
  consumes:
    - type: http
      baseUri: https://api.github.com
      authentication:
        type: bearer
        token: $secrets.github_token
      resources:
        - path: /repos/cvshealth/{repo}/actions/workflows/{workflow}/dispatches
          operations:
            - id: triggerWorkflow
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/change_request
          operations:
            - id: createChangeRequest
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

When a HIPAA or CMS regulatory incident is identified, creates a high-priority ServiceNow compliance incident, notifies the Chief Compliance Officer via Microsoft Teams, and logs it in the Snowflake compliance audit trail.

naftiko: "0.5"
info:
  label: "Healthcare Regulatory Compliance Incident Report"
  description: "When a HIPAA or CMS regulatory incident is identified, creates a high-priority ServiceNow compliance incident, notifies the Chief Compliance Officer via Microsoft Teams, and logs it in the Snowflake compliance audit trail."
  tags:
    - compliance
    - healthcare
    - hipaa
    - servicenow
    - snowflake
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: compliance-ops
      port: 8080
      tools:
        - name: report-regulatory-incident
          description: "Given a regulatory incident description, affected data type, and incident category, create a ServiceNow compliance incident, notify the CCO via Teams, and insert an audit record into Snowflake. Use for HIPAA breaches, CMS violations, or state insurance regulatory events."
          inputParameters:
            - name: incident_description
              in: body
              type: string
              description: "Description of the regulatory incident, including what occurred and initial scope."
            - name: regulation_type
              in: body
              type: string
              description: "Regulation applicable to the incident: HIPAA, CMS, STATE, or ERISA."
            - name: affected_member_count
              in: body
              type: integer
              description: "Estimated number of members or records affected."
            - name: business_unit
              in: body
              type: string
              description: "CVS Health business unit where the incident originated (e.g., Aetna, Caremark, Pharmacy)."
          steps:
            - name: create-compliance-incident
              type: call
              call: servicenow-compliance.create-incident
              with:
                short_description: "Regulatory Incident: {{regulation_type}} — {{business_unit}}"
                category: "Regulatory Compliance"
                urgency: "1"
                description: "Regulation: {{regulation_type}}\nBusiness Unit: {{business_unit}}\nAffected Records: {{affected_member_count}}\nDescription: {{incident_description}}"
            - name: log-audit-record
              type: call
              call: snowflake-compliance.run-query
              with:
                statement: "INSERT INTO compliance.regulatory_incidents (incident_number, regulation_type, business_unit, affected_count, description, reported_at) VALUES ('{{create-compliance-incident.number}}', '{{regulation_type}}', '{{business_unit}}', {{affected_member_count}}, '{{incident_description}}', CURRENT_TIMESTAMP())"
            - name: notify-cco
              type: call
              call: msteams-compliance.send-message
              with:
                channel_id: "compliance-leadership"
                message: "REGULATORY INCIDENT FILED: {{regulation_type}} | Business Unit: {{business_unit}} | Members Affected: {{affected_member_count}} | SNOW: {{create-compliance-incident.number}}"
  consumes:
    - type: http
      namespace: servicenow-compliance
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: snowflake-compliance
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST
    - type: http
      namespace: msteams-compliance
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Identifies Aetna members with open HEDIS care gaps and creates outreach campaigns in Salesforce.

naftiko: "0.5"
info:
  title: HEDIS Care Gap Closure Outreach
  version: "1.0"
  description: Identifies Aetna members with open HEDIS care gaps and creates outreach campaigns in Salesforce.
  tags: [population-health, clinical, healthcare, salesforce]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: run_hedis_outreach
        description: Queries open gaps, creates campaign, and assigns outreach tasks.
        inputParameters:
          - name: measure_code
            in: body
            required: true
            type: string
          - name: region
            in: body
            required: true
            type: string
        steps:
          - name: query-gaps
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, gap_type FROM care_gaps WHERE measure='{{measure_code}}' AND region='{{region}}' AND status='open'"
          - name: create-campaign
            call:
              operationId: createCampaign
              input:
                name: "HEDIS {{measure_code}} Outreach — {{region}}"
                members: "{{query-gaps.results}}"
          - name: assign-tasks
            call:
              operationId: createTasks
              input:
                campaignId: "{{create-campaign.campaign_id}}"
                taskType: "outreach_call"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Campaign
          operations:
            - id: createCampaign
              method: POST
    - type: http
      baseUri: https://cvshealth.my.salesforce.com/services/data/v58.0
      authentication:
        type: bearer
        token: $secrets.salesforce_token
      resources:
        - path: /sobjects/Task
          operations:
            - id: createTasks
              method: POST

Audits PHI access logs across CVS Health systems, identifies anomalies, and creates compliance incidents.

naftiko: "0.5"
info:
  title: HIPAA PHI Access Audit CVS
  version: "1.0"
  description: Audits PHI access logs across CVS Health systems, identifies anomalies, and creates compliance incidents.
  tags: [compliance, hipaa, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: audit_cvs_phi_access
        description: Queries access logs, creates compliance incidents, and notifies privacy officer.
        inputParameters:
          - name: date_start
            in: body
            required: true
            type: string
          - name: date_end
            in: body
            required: true
            type: string
        steps:
          - name: query-logs
            call:
              operationId: executeQuery
              input:
                statement: "SELECT user_id, member_id, access_time FROM phi_access_log WHERE access_time BETWEEN '{{date_start}}' AND '{{date_end}}' AND anomaly=true"
          - name: create-incident
            call:
              operationId: createIncident
              input:
                short_description: "HIPAA PHI access anomaly detected"
                urgency: "1"
                category: "hipaa_compliance"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "privacy-compliance"
                message: "PHI access anomalies detected. Incident {{create-incident.number}} created."
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Queries open user stories in the CVS Health digital product Jira backlog by priority.

naftiko: "0.5"
info:
  title: Jira CVS Digital Backlog Query
  version: "1.0"
  description: Queries open user stories in the CVS Health digital product Jira backlog by priority.
  tags: [project-management, digital, jira]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: query_digital_backlog
        description: Returns backlog items filtered by project and priority level.
        inputParameters:
          - name: project_key
            in: query
            required: true
            type: string
          - name: priority
            in: query
            required: true
            type: string
        call:
          operationId: searchIssues
          input:
            jql: "project={{project_key}} AND priority={{priority}} AND status=Open"
            maxResults: "50"
        outputParameters:
          - name: issues
            type: array
          - name: total
            type: integer
  consumes:
    - type: http
      baseUri: https://cvshealth.atlassian.net/rest/api/3
      authentication:
        type: basic
        username: $secrets.jira_user
        password: $secrets.jira_api_token
      resources:
        - path: /search
          operations:
            - id: searchIssues
              method: GET

Retrieves all completed and incomplete Jira stories from the current sprint for a healthcare IT project and publishes a sprint review summary to the SharePoint project site.

naftiko: "0.5"
info:
  label: "Jira Healthcare IT Project Sprint Review"
  description: "Retrieves all completed and incomplete Jira stories from the current sprint for a healthcare IT project and publishes a sprint review summary to the SharePoint project site."
  tags:
    - devops
    - project-management
    - jira
    - sharepoint
    - reporting
capability:
  exposes:
    - type: mcp
      namespace: project-reporting
      port: 8080
      tools:
        - name: publish-sprint-review
          description: "Given a Jira project key and SharePoint site ID, retrieve all stories from the current active sprint, compute completion rate, and publish a sprint review page to SharePoint. Use at the end of each two-week sprint for stakeholder communication."
          inputParameters:
            - name: jira_project_key
              in: body
              type: string
              description: "Jira project key for the healthcare IT project (e.g., 'PHARM', 'AETNA', 'HIT')."
            - name: sharepoint_site_id
              in: body
              type: string
              description: "SharePoint Online site ID for the project site."
          steps:
            - name: get-sprint-stories
              type: call
              call: jira-sprint.search-issues
              with:
                jql: "project={{jira_project_key}} AND sprint in openSprints() ORDER BY status ASC"
            - name: publish-to-sharepoint
              type: call
              call: sharepoint.create-page
              with:
                site_id: "{{sharepoint_site_id}}"
                title: "Sprint Review — {{jira_project_key}}"
                content: "Total Stories: {{get-sprint-stories.total}} | Completed: {{get-sprint-stories.done_count}} | In Progress: {{get-sprint-stories.in_progress_count}} | Completion Rate: {{get-sprint-stories.completion_pct}}%"
  consumes:
    - type: http
      namespace: jira-sprint
      baseUri: "https://cvshealth.atlassian.net/rest/api/3"
      authentication:
        type: basic
        username: "$secrets.jira_user"
        password: "$secrets.jira_api_token"
      resources:
        - name: issues-search
          path: "/search"
          inputParameters:
            - name: jql
              in: query
          operations:
            - name: search-issues
              method: GET
    - type: http
      namespace: sharepoint
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: site-pages
          path: "/sites/{{site_id}}/pages"
          inputParameters:
            - name: site_id
              in: path
          operations:
            - name: create-page
              method: POST

Validates the completeness and accuracy of Medicare Star Ratings performance data in Snowflake against CMS submission deadlines and alerts the quality team if data gaps are found.

naftiko: "0.5"
info:
  label: "Medicare Star Ratings Data Quality Check"
  description: "Validates the completeness and accuracy of Medicare Star Ratings performance data in Snowflake against CMS submission deadlines and alerts the quality team if data gaps are found."
  tags:
    - healthcare
    - compliance
    - snowflake
    - cms
    - data-quality
capability:
  exposes:
    - type: mcp
      namespace: stars-quality
      port: 8080
      tools:
        - name: validate-star-ratings-data
          description: "Query Snowflake to validate completeness of Medicare Star Ratings measure data for the current performance year. Alert the quality analytics team if any required measures are missing or below completeness thresholds. Use ahead of CMS submission deadlines."
          inputParameters:
            - name: performance_year
              in: body
              type: integer
              description: "Medicare performance year to validate (e.g., 2025)."
            - name: alert_channel_id
              in: body
              type: string
              description: "Microsoft Teams channel ID to alert if data gaps are found."
          steps:
            - name: check-measure-completeness
              type: call
              call: snowflake-stars.run-query
              with:
                statement: "SELECT measure_id, measure_name, COUNT(*) as record_count, AVG(completeness_pct) as avg_completeness FROM cms_stars.measure_data WHERE performance_year={{performance_year}} GROUP BY 1,2 HAVING avg_completeness < 95 ORDER BY avg_completeness ASC"
            - name: alert-quality-team
              type: call
              call: msteams-quality.send-message
              with:
                channel_id: "{{alert_channel_id}}"
                message: "STAR RATINGS DATA ALERT ({{performance_year}}): {{check-measure-completeness.row_count}} measures below 95% completeness. Top gap: {{check-measure-completeness.measure_name}} at {{check-measure-completeness.avg_completeness}}%"
  consumes:
    - type: http
      namespace: snowflake-stars
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST
    - type: http
      namespace: msteams-quality
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Creates a MinuteClinic patient appointment in the scheduling system and sends a confirmation notification to the patient via email using Microsoft Graph.

naftiko: "0.5"
info:
  label: "MinuteClinic Appointment Scheduling"
  description: "Creates a MinuteClinic patient appointment in the scheduling system and sends a confirmation notification to the patient via email using Microsoft Graph."
  tags:
    - healthcare
    - minuteclinic
    - scheduling
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: clinic-scheduling
      port: 8080
      tools:
        - name: schedule-clinic-appointment
          description: "Given a patient ID, clinic location, appointment type, and requested date/time, create a MinuteClinic appointment and send a confirmation email to the patient. Use for online appointment booking and telehealth scheduling workflows."
          inputParameters:
            - name: patient_id
              in: body
              type: string
              description: "CVS Health patient ID."
            - name: clinic_location_id
              in: body
              type: string
              description: "MinuteClinic location ID."
            - name: appointment_type
              in: body
              type: string
              description: "Appointment type code (e.g., 'WELLNESS', 'ILLNESS', 'VACCINATION')."
            - name: requested_datetime
              in: body
              type: string
              description: "Requested appointment datetime in ISO 8601 format."
            - name: patient_email
              in: body
              type: string
              description: "Patient email address for confirmation."
          steps:
            - name: create-appointment
              type: call
              call: minuteclinic.create-appointment
              with:
                patient_id: "{{patient_id}}"
                location_id: "{{clinic_location_id}}"
                appointment_type: "{{appointment_type}}"
                scheduled_at: "{{requested_datetime}}"
            - name: send-confirmation
              type: call
              call: msgraph-clinic.send-email
              with:
                to: "{{patient_email}}"
                subject: "Your MinuteClinic Appointment Confirmation"
                body: "Appointment ID: {{create-appointment.appointment_id}}\nDate/Time: {{requested_datetime}}\nType: {{appointment_type}}\nLocation: {{clinic_location_id}}"
  consumes:
    - type: http
      namespace: minuteclinic
      baseUri: "https://api.cvshealth.com/minuteclinic/v1"
      authentication:
        type: bearer
        token: "$secrets.cvs_platform_token"
      resources:
        - name: appointments
          path: "/appointments"
          operations:
            - name: create-appointment
              method: POST
    - type: http
      namespace: msgraph-clinic
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: send-mail
          path: "/users/noreply@cvshealth.com/sendMail"
          operations:
            - name: send-email
              method: POST

Checks real-time provider availability at MinuteClinic locations by ZIP code and service type.

naftiko: "0.5"
info:
  title: MinuteClinic Provider Availability
  version: "1.0"
  description: Checks real-time provider availability at MinuteClinic locations by ZIP code and service type.
  tags: [clinical, member-services, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: check_clinic_availability
        description: Returns available appointment slots at nearby MinuteClinic locations.
        inputParameters:
          - name: zip_code
            in: query
            required: true
            type: string
          - name: service_type
            in: query
            required: true
            type: string
        call:
          operationId: getAvailability
          input:
            zipCode: "{{zip_code}}"
            serviceType: "{{service_type}}"
        outputParameters:
          - name: locations
            type: array
          - name: total_slots
            type: integer
  consumes:
    - type: http
      baseUri: https://api.minuteclinic.com/v1
      authentication:
        type: bearer
        token: $secrets.minuteclinic_token
      resources:
        - path: /locations/availability
          operations:
            - id: getAvailability
              method: GET

Retrieves a completed MinuteClinic visit summary and sends it to the patient's primary care physician via email.

naftiko: "0.5"
info:
  title: MinuteClinic Visit Summary to PCP
  version: "1.0"
  description: Retrieves a completed MinuteClinic visit summary and sends it to the patient's primary care physician via email.
  tags: [clinical, communication, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: distribute_clinic_summary
        description: Fetches visit notes, looks up PCP, and sends summary email.
        inputParameters:
          - name: visit_id
            in: body
            required: true
            type: string
          - name: member_id
            in: body
            required: true
            type: string
        steps:
          - name: get-summary
            call:
              operationId: getVisitSummary
              input:
                visitId: "{{visit_id}}"
          - name: get-pcp
            call:
              operationId: getMemberPCP
              input:
                memberId: "{{member_id}}"
          - name: send-email
            call:
              operationId: sendEmail
              input:
                to: "{{get-pcp.email}}"
                subject: "MinuteClinic Visit Summary — {{member_id}}"
                body: "Visit {{visit_id}}: {{get-summary.notes}}"
  consumes:
    - type: http
      baseUri: https://api.minuteclinic.com/v1
      authentication:
        type: bearer
        token: $secrets.minuteclinic_token
      resources:
        - path: /visits/{visitId}/summary
          operations:
            - id: getVisitSummary
              method: GET
    - type: http
      baseUri: https://api.aetna.com/enrollment/v1
      authentication:
        type: bearer
        token: $secrets.aetna_enrollment_token
      resources:
        - path: /members/{memberId}/pcp
          operations:
            - id: getMemberPCP
              method: GET
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /me/sendMail
          operations:
            - id: sendEmail
              method: POST

Provisions application access through Okta based on Workday role assignments.

naftiko: "0.5"
info:
  title: Okta CVS Access Provisioning
  version: "1.0"
  description: Provisions application access through Okta based on Workday role assignments.
  tags: [identity-management, okta, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: provision_cvs_access
        description: Gets role from Workday, provisions Okta app, and logs activity.
        inputParameters:
          - name: employee_id
            in: body
            required: true
            type: string
          - name: app_id
            in: body
            required: true
            type: string
        steps:
          - name: get-role
            call:
              operationId: getWorkerRole
              input:
                employeeId: "{{employee_id}}"
          - name: provision
            call:
              operationId: assignApplication
              input:
                userId: "{{employee_id}}"
                appId: "{{app_id}}"
                role: "{{get-role.role}}"
          - name: log
            call:
              operationId: createIncident
              input:
                short_description: "Access provisioned: {{employee_id}} -> {{app_id}}"
                category: "access_management"
                urgency: "4"
  consumes:
    - type: http
      baseUri: https://wd5-impl-services1.workday.com/ccx/api/v1/cvshealth
      authentication:
        type: bearer
        token: $secrets.workday_token
      resources:
        - path: /workers/{employeeId}
          operations:
            - id: getWorkerRole
              method: GET
    - type: http
      baseUri: https://cvshealth.okta.com/api/v1
      authentication:
        type: bearer
        token: $secrets.okta_token
      resources:
        - path: /apps/{appId}/users
          operations:
            - id: assignApplication
              method: PUT
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST

After a Caremark PBM prescription transaction is completed, triggers a member satisfaction survey via email and logs survey responses in Snowflake for NPS trend analysis.

naftiko: "0.5"
info:
  label: "Pharmacy Benefit Member Satisfaction Survey"
  description: "After a Caremark PBM prescription transaction is completed, triggers a member satisfaction survey via email and logs survey responses in Snowflake for NPS trend analysis."
  tags:
    - customer-experience
    - caremark
    - snowflake
    - pharmacy
    - nps
capability:
  exposes:
    - type: mcp
      namespace: member-experience
      port: 8080
      tools:
        - name: send-prescription-satisfaction-survey
          description: "Given a completed Caremark prescription transaction ID and member email, send a satisfaction survey email to the member and log the survey dispatch record in Snowflake for NPS tracking. Use 24 hours after prescription fill completion."
          inputParameters:
            - name: transaction_id
              in: body
              type: string
              description: "Caremark prescription transaction ID."
            - name: member_email
              in: body
              type: string
              description: "Member email address to send the survey to."
            - name: member_id
              in: body
              type: string
              description: "Caremark member ID."
          steps:
            - name: send-survey-email
              type: call
              call: msgraph-survey.send-email
              with:
                to: "{{member_email}}"
                subject: "How was your CVS Caremark experience?"
                body: "Thank you for using CVS Caremark! Please rate your prescription experience for transaction {{transaction_id}}. Your feedback helps us improve."
            - name: log-survey-dispatch
              type: call
              call: snowflake-nps.run-query
              with:
                statement: "INSERT INTO member_experience.survey_dispatches (transaction_id, member_id, member_email, dispatched_at) VALUES ('{{transaction_id}}', '{{member_id}}', '{{member_email}}', CURRENT_TIMESTAMP())"
  consumes:
    - type: http
      namespace: msgraph-survey
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: send-mail
          path: "/users/noreply@caremark.com/sendMail"
          operations:
            - name: send-email
              method: POST
    - type: http
      namespace: snowflake-nps
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST

Queries the pharmacy inventory management system for drugs below reorder threshold and creates a replenishment request in SAP, notifying the pharmacy operations team in Microsoft Teams.

naftiko: "0.5"
info:
  label: "Pharmacy Inventory Low Stock Alert"
  description: "Queries the pharmacy inventory management system for drugs below reorder threshold and creates a replenishment request in SAP, notifying the pharmacy operations team in Microsoft Teams."
  tags:
    - pharmacy
    - inventory
    - sap
    - microsoft-teams
    - operations
capability:
  exposes:
    - type: mcp
      namespace: pharmacy-inventory
      port: 8080
      tools:
        - name: trigger-inventory-replenishment
          description: "Given a store ID, query the pharmacy inventory system for drugs below the reorder point, create SAP purchase requisitions for each low-stock drug, and notify the pharmacy operations team in Teams. Use for automated daily inventory replenishment checks."
          inputParameters:
            - name: store_id
              in: body
              type: string
              description: "CVS pharmacy store ID to check inventory for."
            - name: reorder_threshold_days
              in: body
              type: integer
              description: "Days of supply threshold below which a reorder is triggered."
          steps:
            - name: get-low-stock-items
              type: call
              call: pharmacy-inv.get-low-stock
              with:
                store_id: "{{store_id}}"
                threshold_days: "{{reorder_threshold_days}}"
            - name: create-purchase-requisition
              type: call
              call: sap-inventory.create-requisition
              with:
                store_id: "{{store_id}}"
                item_count: "{{get-low-stock-items.count}}"
                items: "{{get-low-stock-items.drug_ids}}"
            - name: notify-pharmacy-ops
              type: call
              call: msteams-pharmacy.send-message
              with:
                channel_id: "pharmacy-operations"
                message: "Inventory Alert — Store {{store_id}}: {{get-low-stock-items.count}} drugs below {{reorder_threshold_days}}-day supply. SAP Purchase Requisition: {{create-purchase-requisition.requisition_number}}"
  consumes:
    - type: http
      namespace: pharmacy-inv
      baseUri: "https://api.cvshealth.com/pharmacy/v1"
      authentication:
        type: bearer
        token: "$secrets.cvs_platform_token"
      resources:
        - name: inventory
          path: "/stores/{{store_id}}/inventory/low-stock"
          inputParameters:
            - name: store_id
              in: path
            - name: threshold_days
              in: query
          operations:
            - name: get-low-stock
              method: GET
    - type: http
      namespace: sap-inventory
      baseUri: "https://cvs-s4.sap.com/sap/opu/odata/sap/MM_PUR_PR_MAINT_V2_SRV"
      authentication:
        type: basic
        username: "$secrets.sap_user"
        password: "$secrets.sap_password"
      resources:
        - name: requisitions
          path: "/A_PurchaseRequisitionHeader"
          operations:
            - name: create-requisition
              method: POST
    - type: http
      namespace: msteams-pharmacy
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Triggers a Snowflake query to compute same-day prescription fill rates across CVS pharmacy locations and refreshes the Tableau dashboard used by pharmacy operations leadership.

naftiko: "0.5"
info:
  label: "Pharmacy Prescription Fill Rate Dashboard Refresh"
  description: "Triggers a Snowflake query to compute same-day prescription fill rates across CVS pharmacy locations and refreshes the Tableau dashboard used by pharmacy operations leadership."
  tags:
    - pharmacy
    - data
    - snowflake
    - tableau
    - reporting
capability:
  exposes:
    - type: mcp
      namespace: pharmacy-reporting
      port: 8080
      tools:
        - name: refresh-fill-rate-dashboard
          description: "Execute a Snowflake query to aggregate daily prescription fill rates by store and region, then trigger a Tableau workbook refresh for the pharmacy operations leadership dashboard. Use for daily operational reviews."
          inputParameters:
            - name: report_date
              in: body
              type: string
              description: "Date for the fill rate report in YYYY-MM-DD format."
            - name: tableau_datasource_id
              in: body
              type: string
              description: "Tableau datasource LUID to refresh."
          steps:
            - name: compute-fill-rates
              type: call
              call: snowflake.run-query
              with:
                statement: "SELECT store_id, region, COUNT(*) as total_rx, SUM(CASE WHEN status='filled' THEN 1 ELSE 0 END) as filled_rx, ROUND(filled_rx/total_rx*100,2) as fill_rate FROM pharmacy.rx_transactions WHERE fill_date='{{report_date}}' GROUP BY 1,2"
            - name: refresh-tableau
              type: call
              call: tableau.refresh-datasource
              with:
                datasource_id: "{{tableau_datasource_id}}"
  consumes:
    - type: http
      namespace: snowflake
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST
    - type: http
      namespace: tableau
      baseUri: "https://tableau.cvshealth.com/api/2.8"
      authentication:
        type: apikey
        key: "X-Tableau-Auth"
        value: "$secrets.tableau_token"
        placement: header
      resources:
        - name: datasource-refreshes
          path: "/sites/{{site_id}}/datasources/{{datasource_id}}/refresh"
          inputParameters:
            - name: site_id
              in: path
            - name: datasource_id
              in: path
          operations:
            - name: refresh-datasource
              method: POST

Executes risk stratification for Aetna members by querying claims data, scoring, and updating care management.

naftiko: "0.5"
info:
  title: Population Health Risk Stratification
  version: "1.0"
  description: Executes risk stratification for Aetna members by querying claims data, scoring, and updating care management.
  tags: [population-health, analytics, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: run_aetna_risk_stratification
        description: Queries data, scores members, and updates care management cohorts.
        inputParameters:
          - name: segment
            in: body
            required: true
            type: string
          - name: model
            in: body
            required: true
            type: string
        steps:
          - name: query-data
            call:
              operationId: executeQuery
              input:
                statement: "SELECT member_id, total_cost, conditions FROM claims_summary WHERE segment='{{segment}}'"
          - name: score
            call:
              operationId: runRiskScore
              input:
                model: "{{model}}"
                data: "{{query-data.results}}"
          - name: update
            call:
              operationId: updateCohort
              input:
                segment: "{{segment}}"
                scores: "{{score.results}}"
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST
    - type: http
      baseUri: https://api.aetna.com/population-health/v1
      authentication:
        type: bearer
        token: $secrets.aetna_ph_token
      resources:
        - path: /risk-scoring
          operations:
            - id: runRiskScore
              method: POST
    - type: http
      baseUri: https://api.aetna.com/care-management/v1
      authentication:
        type: bearer
        token: $secrets.aetna_cm_token
      resources:
        - path: /cohorts
          operations:
            - id: updateCohort
              method: PUT

Triggers a Power BI dataset refresh for the enterprise finance dashboard and sends a Microsoft Teams notification to the CFO office when the refresh completes.

naftiko: "0.5"
info:
  label: "Power BI Finance Dashboard Refresh"
  description: "Triggers a Power BI dataset refresh for the enterprise finance dashboard and sends a Microsoft Teams notification to the CFO office when the refresh completes."
  tags:
    - finance
    - reporting
    - power-bi
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: finance-reporting
      port: 8080
      tools:
        - name: refresh-finance-dashboard
          description: "Trigger a Power BI dataset refresh for the enterprise finance dashboard and notify the finance leadership team in Microsoft Teams when complete. Use before monthly close reporting and board presentations."
          inputParameters:
            - name: dataset_id
              in: body
              type: string
              description: "Power BI dataset ID for the finance dashboard."
            - name: workspace_id
              in: body
              type: string
              description: "Power BI workspace ID containing the dataset."
          steps:
            - name: trigger-refresh
              type: call
              call: powerbi.trigger-refresh
              with:
                workspace_id: "{{workspace_id}}"
                dataset_id: "{{dataset_id}}"
            - name: notify-finance-team
              type: call
              call: msteams-finance.send-message
              with:
                channel_id: "finance-leadership"
                message: "Finance Dashboard refresh triggered for dataset {{dataset_id}}. Results will be available within 20 minutes."
  consumes:
    - type: http
      namespace: powerbi
      baseUri: "https://api.powerbi.com/v1.0/myorg"
      authentication:
        type: bearer
        token: "$secrets.powerbi_token"
      resources:
        - name: dataset-refreshes
          path: "/groups/{{workspace_id}}/datasets/{{dataset_id}}/refreshes"
          inputParameters:
            - name: workspace_id
              in: path
            - name: dataset_id
              in: path
          operations:
            - name: trigger-refresh
              method: POST
    - type: http
      namespace: msteams-finance
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Triggers a Power BI dataset refresh for pharmacy analytics dashboards and notifies the analytics team.

naftiko: "0.5"
info:
  title: Power BI Pharmacy Analytics Refresh
  version: "1.0"
  description: Triggers a Power BI dataset refresh for pharmacy analytics dashboards and notifies the analytics team.
  tags: [analytics, pharmacy, healthcare, power-bi]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: refresh_pharmacy_dashboard
        description: Triggers refresh and sends completion notification.
        inputParameters:
          - name: dataset_id
            in: body
            required: true
            type: string
          - name: workspace_id
            in: body
            required: true
            type: string
        steps:
          - name: refresh
            call:
              operationId: refreshDataset
              input:
                datasetId: "{{dataset_id}}"
                workspaceId: "{{workspace_id}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "pharmacy-analytics"
                message: "Pharmacy analytics dashboard refreshed. Dataset: {{dataset_id}}."
  consumes:
    - type: http
      baseUri: https://api.powerbi.com/v1.0/myorg
      authentication:
        type: bearer
        token: $secrets.powerbi_token
      resources:
        - path: /groups/{workspaceId}/datasets/{datasetId}/refreshes
          operations:
            - id: refreshDataset
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

When a Salesforce customer service case for a pharmacy issue is escalated to priority 1, creates a ServiceNow operational incident and notifies the pharmacy operations duty manager in Microsoft Teams.

naftiko: "0.5"
info:
  label: "Salesforce Case Escalation to Pharmacy Operations"
  description: "When a Salesforce customer service case for a pharmacy issue is escalated to priority 1, creates a ServiceNow operational incident and notifies the pharmacy operations duty manager in Microsoft Teams."
  tags:
    - customer-service
    - pharmacy
    - salesforce
    - servicenow
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: pharmacy-service
      port: 8080
      tools:
        - name: escalate-pharmacy-case
          description: "Given a Salesforce case ID escalated to P1, retrieve the case details, create a ServiceNow operational incident for pharmacy operations, and notify the duty manager in Microsoft Teams. Use when pharmacy dispensing errors or critical member complaints are escalated."
          inputParameters:
            - name: case_id
              in: body
              type: string
              description: "Salesforce case record ID."
          steps:
            - name: get-case
              type: call
              call: salesforce-case.get-case
              with:
                case_id: "{{case_id}}"
            - name: create-ops-incident
              type: call
              call: servicenow-pharmacy.create-incident
              with:
                short_description: "Pharmacy P1 Escalation: {{get-case.subject}}"
                category: "Pharmacy Operations"
                urgency: "1"
                description: "Salesforce Case: {{case_id}}\nSubject: {{get-case.subject}}\nMember ID: {{get-case.member_id}}\nStore: {{get-case.store_id}}\nDescription: {{get-case.description}}"
            - name: notify-duty-manager
              type: call
              call: msteams-ops.send-message
              with:
                channel_id: "pharmacy-ops-escalations"
                message: "P1 PHARMACY ESCALATION: {{get-case.subject}} | Case: {{case_id}} | Store: {{get-case.store_id}} | SNOW: {{create-ops-incident.number}}"
  consumes:
    - type: http
      namespace: salesforce-case
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: cases
          path: "/sobjects/Case/{{case_id}}"
          inputParameters:
            - name: case_id
              in: path
          operations:
            - name: get-case
              method: GET
    - type: http
      namespace: servicenow-pharmacy
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msteams-ops
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Retrieves a Salesforce health plan member account summary including open cases, recent interactions, and plan details for customer service representatives handling escalations.

naftiko: "0.5"
info:
  label: "Salesforce Customer Account Health Review"
  description: "Retrieves a Salesforce health plan member account summary including open cases, recent interactions, and plan details for customer service representatives handling escalations."
  tags:
    - crm
    - customer-service
    - salesforce
    - healthcare
    - lookup
capability:
  exposes:
    - type: mcp
      namespace: customer-service
      port: 8080
      tools:
        - name: get-member-account-summary
          description: "Given a Salesforce account ID for a health plan member, retrieve account details, open service cases, recent interaction history, and current plan enrollment. Use when customer service agents need a 360-degree member view before handling an escalation."
          inputParameters:
            - name: account_id
              in: body
              type: string
              description: "Salesforce account ID for the health plan member."
          steps:
            - name: get-account
              type: call
              call: salesforce.get-account
              with:
                account_id: "{{account_id}}"
            - name: get-open-cases
              type: call
              call: salesforce-cases.list-cases
              with:
                account_id: "{{account_id}}"
                status: "Open"
  consumes:
    - type: http
      namespace: salesforce
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: accounts
          path: "/sobjects/Account/{{account_id}}"
          inputParameters:
            - name: account_id
              in: path
          operations:
            - name: get-account
              method: GET
    - type: http
      namespace: salesforce-cases
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: cases
          path: "/sobjects/Case"
          inputParameters:
            - name: account_id
              in: query
            - name: status
              in: query
          operations:
            - name: list-cases
              method: GET

When a new prospective member lead is created in Salesforce, enriches the lead record with prescription benefit eligibility and plan tier data from the Caremark API.

naftiko: "0.5"
info:
  label: "Salesforce Healthcare Member Lead Enrichment"
  description: "When a new prospective member lead is created in Salesforce, enriches the lead record with prescription benefit eligibility and plan tier data from the Caremark API."
  tags:
    - crm
    - sales
    - salesforce
    - caremark
    - healthcare
capability:
  exposes:
    - type: mcp
      namespace: member-acquisition
      port: 8080
      tools:
        - name: enrich-member-lead
          description: "Given a Salesforce lead ID for a prospective health plan member, retrieve their current prescription benefit eligibility from Caremark and update the lead record with plan tier, benefit level, and estimated premium data. Use during member acquisition campaigns."
          inputParameters:
            - name: lead_id
              in: body
              type: string
              description: "Salesforce lead record ID."
            - name: member_dob
              in: body
              type: string
              description: "Prospective member date of birth in YYYY-MM-DD format for eligibility lookup."
            - name: zip_code
              in: body
              type: string
              description: "Prospective member ZIP code for plan availability lookup."
          steps:
            - name: get-lead
              type: call
              call: salesforce-lead.get-lead
              with:
                lead_id: "{{lead_id}}"
            - name: check-eligibility
              type: call
              call: caremark-eligibility.check-eligibility
              with:
                date_of_birth: "{{member_dob}}"
                zip_code: "{{zip_code}}"
            - name: update-lead
              type: call
              call: salesforce-lead-enrich.update-lead
              with:
                lead_id: "{{lead_id}}"
                benefit_level: "{{check-eligibility.benefit_level}}"
                plan_tier: "{{check-eligibility.plan_tier}}"
                estimated_premium: "{{check-eligibility.estimated_monthly_premium}}"
  consumes:
    - type: http
      namespace: salesforce-lead
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: leads
          path: "/sobjects/Lead/{{lead_id}}"
          inputParameters:
            - name: lead_id
              in: path
          operations:
            - name: get-lead
              method: GET
    - type: http
      namespace: caremark-eligibility
      baseUri: "https://api.caremark.com/pbm/v2"
      authentication:
        type: bearer
        token: "$secrets.caremark_api_token"
      resources:
        - name: eligibility
          path: "/eligibility/check"
          inputParameters:
            - name: date_of_birth
              in: query
            - name: zip_code
              in: query
          operations:
            - name: check-eligibility
              method: GET
    - type: http
      namespace: salesforce-lead-enrich
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: leads
          path: "/sobjects/Lead/{{lead_id}}"
          inputParameters:
            - name: lead_id
              in: path
          operations:
            - name: update-lead
              method: PATCH

When a Salesforce opportunity reaches Closed Won, retrieves the deal details and creates a corresponding contract record in SAP S/4HANA for revenue recognition and finance processing.

naftiko: "0.5"
info:
  label: "Salesforce Opportunity to SAP Contract Creation"
  description: "When a Salesforce opportunity reaches Closed Won, retrieves the deal details and creates a corresponding contract record in SAP S/4HANA for revenue recognition and finance processing."
  tags:
    - sales
    - finance
    - salesforce
    - sap
    - erp
capability:
  exposes:
    - type: mcp
      namespace: revenue-ops
      port: 8080
      tools:
        - name: create-sap-contract-from-opportunity
          description: "Given a Salesforce Closed Won opportunity ID, retrieve the opportunity and account details, then create a corresponding SAP customer contract for revenue recognition. Use in the quote-to-cash process when health plan or enterprise deals close."
          inputParameters:
            - name: opportunity_id
              in: body
              type: string
              description: "Salesforce opportunity ID for the Closed Won deal."
          steps:
            - name: get-opportunity
              type: call
              call: salesforce-opp.get-opportunity
              with:
                opportunity_id: "{{opportunity_id}}"
            - name: create-sap-contract
              type: call
              call: sap-contracts.create-contract
              with:
                customer_name: "{{get-opportunity.account_name}}"
                contract_value: "{{get-opportunity.amount}}"
                currency: "USD"
                start_date: "{{get-opportunity.close_date}}"
                description: "Salesforce Opportunity: {{opportunity_id}} — {{get-opportunity.name}}"
  consumes:
    - type: http
      namespace: salesforce-opp
      baseUri: "https://cvs-health.my.salesforce.com/services/data/v58.0"
      authentication:
        type: bearer
        token: "$secrets.salesforce_token"
      resources:
        - name: opportunities
          path: "/sobjects/Opportunity/{{opportunity_id}}"
          inputParameters:
            - name: opportunity_id
              in: path
          operations:
            - name: get-opportunity
              method: GET
    - type: http
      namespace: sap-contracts
      baseUri: "https://cvs-s4.sap.com/sap/opu/odata/sap/API_CUSTOMER_CONTRACT_SRV"
      authentication:
        type: basic
        username: "$secrets.sap_user"
        password: "$secrets.sap_password"
      resources:
        - name: contracts
          path: "/A_CustomerContract"
          operations:
            - name: create-contract
              method: POST

Routes CVS Health procurement requests through SAP approval workflow and notifies finance.

naftiko: "0.5"
info:
  title: SAP CVS Procurement Approval
  version: "1.0"
  description: Routes CVS Health procurement requests through SAP approval workflow and notifies finance.
  tags: [procurement, sap, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: process_cvs_procurement
        description: Gets requisition, submits approval, and notifies finance.
        inputParameters:
          - name: requisition_id
            in: body
            required: true
            type: string
          - name: department
            in: body
            required: true
            type: string
        steps:
          - name: get-req
            call:
              operationId: getRequisition
              input:
                requisitionId: "{{requisition_id}}"
          - name: submit
            call:
              operationId: submitApproval
              input:
                requisitionId: "{{requisition_id}}"
                department: "{{department}}"
                amount: "{{get-req.total_amount}}"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "finance-approvals"
                message: "Procurement {{requisition_id}} for {{department}} submitted."
  consumes:
    - type: http
      baseUri: https://cvshealth-sap.com/api/v1
      authentication:
        type: bearer
        token: $secrets.sap_token
      resources:
        - path: /requisitions/{requisitionId}
          operations:
            - id: getRequisition
              method: GET
    - type: http
      baseUri: https://cvshealth-sap.com/api/v1
      authentication:
        type: bearer
        token: $secrets.sap_token
      resources:
        - path: /approvals
          operations:
            - id: submitApproval
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

When a purchase order in SAP S/4HANA awaits approval, retrieves PO details and routes it to the appropriate approver via ServiceNow workflow, notifying the approver in Microsoft Teams.

naftiko: "0.5"
info:
  label: "SAP Purchase Order Approval Workflow"
  description: "When a purchase order in SAP S/4HANA awaits approval, retrieves PO details and routes it to the appropriate approver via ServiceNow workflow, notifying the approver in Microsoft Teams."
  tags:
    - finance
    - procurement
    - sap
    - servicenow
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: procurement
      port: 8080
      tools:
        - name: route-po-for-approval
          description: "Given a SAP purchase order number pending approval, retrieve the PO header and line items, create a ServiceNow approval request, and notify the approver via Microsoft Teams. Use for POs above the auto-approval threshold requiring human review."
          inputParameters:
            - name: po_number
              in: body
              type: string
              description: "SAP purchase order number (e.g., '4500012345')."
            - name: approver_upn
              in: body
              type: string
              description: "UPN of the designated approver."
          steps:
            - name: get-po
              type: call
              call: sap.get-po
              with:
                po_number: "{{po_number}}"
            - name: create-approval-request
              type: call
              call: servicenow-approval.create-incident
              with:
                short_description: "PO Approval Required: {{po_number}} — ${{get-po.total_amount}}"
                category: "Procurement"
                description: "PO: {{po_number}}\nVendor: {{get-po.vendor_name}}\nAmount: ${{get-po.total_amount}} {{get-po.currency}}\nRequester: {{get-po.created_by}}"
            - name: notify-approver
              type: call
              call: msteams-approval.send-message
              with:
                recipient_upn: "{{approver_upn}}"
                message: "Purchase Order {{po_number}} for ${{get-po.total_amount}} requires your approval. Vendor: {{get-po.vendor_name}}. ServiceNow: {{create-approval-request.number}}"
  consumes:
    - type: http
      namespace: sap
      baseUri: "https://cvs-s4.sap.com/sap/opu/odata/sap/MM_PUR_PO_MAINT_V2_SRV"
      authentication:
        type: basic
        username: "$secrets.sap_user"
        password: "$secrets.sap_password"
      resources:
        - name: purchase-orders
          path: "/A_PurchaseOrder('{{po_number}}')"
          inputParameters:
            - name: po_number
              in: path
          operations:
            - name: get-po
              method: GET
              outputRawFormat: xml
    - type: http
      namespace: servicenow-approval
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msteams-approval
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: messages
          path: "/users/{{recipient_upn}}/sendMail"
          inputParameters:
            - name: recipient_upn
              in: path
          operations:
            - name: send-message
              method: POST

Retrieves an open vendor invoice from SAP S/4HANA, validates it against the purchase order, and routes it for three-way match approval via ServiceNow.

naftiko: "0.5"
info:
  label: "SAP Vendor Invoice Processing"
  description: "Retrieves an open vendor invoice from SAP S/4HANA, validates it against the purchase order, and routes it for three-way match approval via ServiceNow."
  tags:
    - finance
    - accounts-payable
    - sap
    - servicenow
capability:
  exposes:
    - type: mcp
      namespace: accounts-payable
      port: 8080
      tools:
        - name: process-vendor-invoice
          description: "Given a SAP vendor invoice ID, retrieve the invoice and matching PO from SAP, perform three-way match validation, and create a ServiceNow approval task if the invoice requires manual review. Use for AP invoice processing automation."
          inputParameters:
            - name: invoice_id
              in: body
              type: string
              description: "SAP vendor invoice document number."
            - name: fiscal_year
              in: body
              type: string
              description: "SAP fiscal year for the invoice (e.g., '2025')."
          steps:
            - name: get-invoice
              type: call
              call: sap-ap.get-invoice
              with:
                invoice_id: "{{invoice_id}}"
                fiscal_year: "{{fiscal_year}}"
            - name: create-approval-task
              type: call
              call: servicenow-ap.create-incident
              with:
                short_description: "Invoice Approval: {{invoice_id}} — {{get-invoice.vendor_name}} ${{get-invoice.amount}}"
                category: "Accounts Payable"
                description: "Invoice: {{invoice_id}}\nVendor: {{get-invoice.vendor_name}}\nAmount: ${{get-invoice.amount}} {{get-invoice.currency}}\nPO: {{get-invoice.po_number}}\nPayment Terms: {{get-invoice.payment_terms}}"
  consumes:
    - type: http
      namespace: sap-ap
      baseUri: "https://cvs-s4.sap.com/sap/opu/odata/sap/API_SUPPLIER_INVOICE_SRV"
      authentication:
        type: basic
        username: "$secrets.sap_user"
        password: "$secrets.sap_password"
      resources:
        - name: invoices
          path: "/A_SupplierInvoice(SupplierInvoice='{{invoice_id}}',FiscalYear='{{fiscal_year}}')"
          inputParameters:
            - name: invoice_id
              in: path
            - name: fiscal_year
              in: path
          operations:
            - name: get-invoice
              method: GET
              outputRawFormat: xml
    - type: http
      namespace: servicenow-ap
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST

Retrieves the current status and assignment details of an IT incident ticket from CVS Health ServiceNow.

naftiko: "0.5"
info:
  title: ServiceNow CVS IT Ticket Status
  version: "1.0"
  description: Retrieves the current status and assignment details of an IT incident ticket from CVS Health ServiceNow.
  tags: [itsm, servicenow, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: get_cvs_ticket_status
        description: Returns ticket state, assigned group, priority, and resolution notes.
        inputParameters:
          - name: incident_number
            in: query
            required: true
            type: string
        call:
          operationId: getIncident
          input:
            number: "{{incident_number}}"
        outputParameters:
          - name: state
            type: string
          - name: assigned_to
            type: string
          - name: priority
            type: string
  consumes:
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: getIncident
              method: GET

When a P1 IT incident is raised in ServiceNow, pages the on-call engineer via PagerDuty and creates a Microsoft Teams war room channel for incident coordination.

naftiko: "0.5"
info:
  label: "ServiceNow IT Incident Response Escalation"
  description: "When a P1 IT incident is raised in ServiceNow, pages the on-call engineer via PagerDuty and creates a Microsoft Teams war room channel for incident coordination."
  tags:
    - itsm
    - incident-response
    - servicenow
    - pagerduty
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: incident-response
      port: 8080
      tools:
        - name: escalate-p1-incident
          description: "Given a ServiceNow P1 incident number, retrieve incident details, trigger a PagerDuty alert for the on-call engineer, and create a Microsoft Teams channel for war room coordination. Use when critical IT incidents require immediate cross-team response."
          inputParameters:
            - name: incident_number
              in: body
              type: string
              description: "ServiceNow incident number (e.g., 'INC0012345')."
          steps:
            - name: get-incident
              type: call
              call: servicenow-p1.get-incident
              with:
                incident_number: "{{incident_number}}"
            - name: page-on-call
              type: call
              call: pagerduty.create-incident
              with:
                title: "P1 Incident: {{get-incident.short_description}}"
                severity: "critical"
                body: "SNOW: {{incident_number}} | {{get-incident.short_description}} | Category: {{get-incident.category}}"
            - name: create-teams-channel
              type: call
              call: msteams-incident.create-channel
              with:
                display_name: "INC-{{incident_number}}-war-room"
                description: "War room for P1 incident {{incident_number}}: {{get-incident.short_description}}"
  consumes:
    - type: http
      namespace: servicenow-p1
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          inputParameters:
            - name: incident_number
              in: query
          operations:
            - name: get-incident
              method: GET
    - type: http
      namespace: pagerduty
      baseUri: "https://api.pagerduty.com"
      authentication:
        type: apikey
        key: "Authorization"
        value: "$secrets.pagerduty_token"
        placement: header
      resources:
        - name: incidents
          path: "/incidents"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msteams-incident
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channels
          path: "/teams/{{team_id}}/channels"
          inputParameters:
            - name: team_id
              in: path
          operations:
            - name: create-channel
              method: POST

Queries the Snowflake analytics warehouse for pharmacy claims utilization metrics and trends.

naftiko: "0.5"
info:
  title: Snowflake Pharmacy Claims Query
  version: "1.0"
  description: Queries the Snowflake analytics warehouse for pharmacy claims utilization metrics and trends.
  tags: [pharmacy, analytics, snowflake]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: query_pharmacy_claims
        description: Returns pharmacy claims aggregates by drug category and time period.
        inputParameters:
          - name: drug_category
            in: query
            required: true
            type: string
          - name: period
            in: query
            required: true
            type: string
        call:
          operationId: executeQuery
          input:
            statement: "SELECT drug_category, total_claims, avg_cost, fill_count FROM pharmacy_claims WHERE category='{{drug_category}}' AND period='{{period}}'"
        outputParameters:
          - name: results
            type: array
  consumes:
    - type: http
      baseUri: https://cvs-analytics.snowflakecomputing.com/api/v2
      authentication:
        type: bearer
        token: $secrets.snowflake_token
      resources:
        - path: /statements
          operations:
            - id: executeQuery
              method: POST

Monitors the Snowflake data pipeline that feeds the retail pharmacy sales reporting layer and alerts the data engineering team via Microsoft Teams if any partition load fails or is delayed.

naftiko: "0.5"
info:
  label: "Snowflake Retail Pharmacy Sales Pipeline Monitoring"
  description: "Monitors the Snowflake data pipeline that feeds the retail pharmacy sales reporting layer and alerts the data engineering team via Microsoft Teams if any partition load fails or is delayed."
  tags:
    - data
    - monitoring
    - snowflake
    - microsoft-teams
    - pharmacy
capability:
  exposes:
    - type: mcp
      namespace: data-pipeline-ops
      port: 8080
      tools:
        - name: monitor-pharmacy-sales-pipeline
          description: "Query Snowflake pipeline metadata to identify any failed or stale partition loads in the retail pharmacy sales data pipeline. Alert the data engineering team in Teams if load SLA is breached. Use in scheduled pipeline health monitoring."
          inputParameters:
            - name: sla_minutes
              in: body
              type: integer
              description: "Maximum acceptable minutes since last successful partition load."
          steps:
            - name: check-pipeline-status
              type: call
              call: snowflake-pipeline.run-query
              with:
                statement: "SELECT pipeline_name, partition_date, MAX(loaded_at) as last_load, DATEDIFF(minute, MAX(loaded_at), CURRENT_TIMESTAMP()) as minutes_stale FROM pharmacy.etl_pipeline_log WHERE loaded_at < DATEADD(minute, -{{sla_minutes}}, CURRENT_TIMESTAMP()) GROUP BY 1,2 ORDER BY minutes_stale DESC LIMIT 10"
            - name: alert-data-team
              type: call
              call: msteams-data.send-message
              with:
                channel_id: "data-engineering-alerts"
                message: "PIPELINE ALERT: Pharmacy sales pipeline stale. Pipeline: {{check-pipeline-status.pipeline_name}} | Last load: {{check-pipeline-status.last_load}} | Stale by: {{check-pipeline-status.minutes_stale}} minutes"
  consumes:
    - type: http
      namespace: snowflake-pipeline
      baseUri: "https://cvs.snowflakecomputing.com/api/v2"
      authentication:
        type: bearer
        token: "$secrets.snowflake_token"
      resources:
        - name: statements
          path: "/statements"
          operations:
            - name: run-query
              method: POST
    - type: http
      namespace: msteams-data
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

Correlates security events from Splunk and escalates suspicious activity to the security operations center.

naftiko: "0.5"
info:
  title: Splunk CVS Security Event Correlation
  version: "1.0"
  description: Correlates security events from Splunk and escalates suspicious activity to the security operations center.
  tags: [security, compliance, healthcare, splunk]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: correlate_cvs_security
        description: Queries Splunk, creates escalation tickets, and notifies SOC.
        inputParameters:
          - name: time_window
            in: body
            required: true
            type: string
          - name: event_type
            in: body
            required: true
            type: string
        steps:
          - name: query
            call:
              operationId: searchEvents
              input:
                query: "index=security event_type={{event_type}} earliest={{time_window}}"
                output_mode: "json"
          - name: escalate
            call:
              operationId: createIncident
              input:
                short_description: "Security correlation: {{event_type}}"
                urgency: "1"
                category: "security"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "soc-alerts"
                message: "Security escalation: {{event_type}}. Incident: {{escalate.number}}."
  consumes:
    - type: http
      baseUri: https://cvshealth-splunk.com:8089/services
      authentication:
        type: bearer
        token: $secrets.splunk_token
      resources:
        - path: /search/jobs
          operations:
            - id: searchEvents
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/incident
          operations:
            - id: createIncident
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Provisions HIPAA-compliant infrastructure using Terraform and registers in the CMDB.

naftiko: "0.5"
info:
  title: Terraform CVS Infrastructure Provisioner
  version: "1.0"
  description: Provisions HIPAA-compliant infrastructure using Terraform and registers in the CMDB.
  tags: [infrastructure, devops, healthcare, terraform]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: provision_cvs_infra
        description: Triggers Terraform, registers CMDB, and notifies team.
        inputParameters:
          - name: env_name
            in: body
            required: true
            type: string
          - name: workspace_id
            in: body
            required: true
            type: string
        steps:
          - name: apply
            call:
              operationId: triggerRun
              input:
                workspaceId: "{{workspace_id}}"
                message: "Provisioning {{env_name}}"
          - name: register
            call:
              operationId: createCI
              input:
                name: "{{env_name}}"
                category: "cloud_infrastructure"
          - name: notify
            call:
              operationId: sendTeamsMessage
              input:
                channelId: "platform-engineering"
                message: "Environment {{env_name}} provisioned."
  consumes:
    - type: http
      baseUri: https://app.terraform.io/api/v2
      authentication:
        type: bearer
        token: $secrets.terraform_token
      resources:
        - path: /runs
          operations:
            - id: triggerRun
              method: POST
    - type: http
      baseUri: https://cvshealth.service-now.com/api/now/v1
      authentication:
        type: basic
        username: $secrets.snow_user
        password: $secrets.snow_password
      resources:
        - path: /table/cmdb_ci
          operations:
            - id: createCI
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /teams/messages
          operations:
            - id: sendTeamsMessage
              method: POST

Initiates the annual performance review cycle in Workday for a specified business unit, sending review completion reminders via Microsoft Teams to all managers with pending reviews.

naftiko: "0.5"
info:
  label: "Workday Annual Performance Review Cycle Launch"
  description: "Initiates the annual performance review cycle in Workday for a specified business unit, sending review completion reminders via Microsoft Teams to all managers with pending reviews."
  tags:
    - hr
    - performance-management
    - workday
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: performance-management
      port: 8080
      tools:
        - name: launch-performance-review-cycle
          description: "Given a business unit ID and review period, retrieve the list of managers with pending performance reviews in Workday, then send Microsoft Teams reminder messages to each manager. Use at the start of the annual performance review cycle."
          inputParameters:
            - name: business_unit_id
              in: body
              type: string
              description: "Workday business unit ID for the performance review cycle."
            - name: review_period
              in: body
              type: string
              description: "Performance review period label (e.g., 'FY2025 Annual Review')."
            - name: submission_deadline
              in: body
              type: string
              description: "Review submission deadline date in YYYY-MM-DD format."
          steps:
            - name: get-pending-managers
              type: call
              call: workday-perf.list-pending-reviews
              with:
                business_unit_id: "{{business_unit_id}}"
                review_period: "{{review_period}}"
            - name: send-manager-reminder
              type: call
              call: msteams-perf.send-message
              with:
                channel_id: "hr-announcements"
                message: "Performance Review Reminder: {{review_period}} reviews are due by {{submission_deadline}}. {{get-pending-managers.count}} managers have pending reviews in your business unit. Please complete in Workday."
  consumes:
    - type: http
      namespace: workday-perf
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: performance-reviews
          path: "/cvs-health/performanceReviews/pending"
          inputParameters:
            - name: business_unit_id
              in: query
            - name: review_period
              in: query
          operations:
            - name: list-pending-reviews
              method: GET
    - type: http
      namespace: msteams-perf
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: channel-messages
          path: "/teams/{{team_id}}/channels/{{channel_id}}/messages"
          inputParameters:
            - name: team_id
              in: path
            - name: channel_id
              in: path
          operations:
            - name: send-message
              method: POST

When a manager submits a compensation adjustment in Workday, retrieves the adjustment details and routes it through a ServiceNow approval workflow based on the percentage change threshold.

naftiko: "0.5"
info:
  label: "Workday Compensation Adjustment Approval"
  description: "When a manager submits a compensation adjustment in Workday, retrieves the adjustment details and routes it through a ServiceNow approval workflow based on the percentage change threshold."
  tags:
    - hr
    - compensation
    - workday
    - servicenow
    - approval
capability:
  exposes:
    - type: mcp
      namespace: compensation-ops
      port: 8080
      tools:
        - name: route-compensation-adjustment
          description: "Given a Workday compensation adjustment event ID, retrieve the change details and route to the appropriate approval level in ServiceNow based on the percentage change (standard, director, or executive approval). Use for merit cycle and off-cycle compensation change processing."
          inputParameters:
            - name: adjustment_event_id
              in: body
              type: string
              description: "Workday compensation change event ID."
            - name: approver_upn
              in: body
              type: string
              description: "UPN of the required approver for the compensation change."
          steps:
            - name: get-adjustment
              type: call
              call: workday-comp.get-comp-change
              with:
                event_id: "{{adjustment_event_id}}"
            - name: create-approval-request
              type: call
              call: servicenow-comp.create-incident
              with:
                short_description: "Compensation Adjustment Approval: {{get-adjustment.worker_name}} — {{get-adjustment.change_pct}}% increase"
                category: "HR Compensation"
                description: "Worker: {{get-adjustment.worker_name}}\nEvent: {{adjustment_event_id}}\nCurrent Base: ${{get-adjustment.current_salary}}\nProposed Base: ${{get-adjustment.proposed_salary}}\nChange: {{get-adjustment.change_pct}}%\nEffective Date: {{get-adjustment.effective_date}}"
  consumes:
    - type: http
      namespace: workday-comp
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: compensation-changes
          path: "/cvs-health/compensationChanges/{{event_id}}"
          inputParameters:
            - name: event_id
              in: path
          operations:
            - name: get-comp-change
              method: GET
    - type: http
      namespace: servicenow-comp
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST

Synchronizes employee benefit elections from Workday to Aetna enrollment systems.

naftiko: "0.5"
info:
  title: Workday CVS Benefits Enrollment Sync
  version: "1.0"
  description: Synchronizes employee benefit elections from Workday to Aetna enrollment systems.
  tags: [enrollment, human-resources, workday, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: sync_cvs_benefits
        description: Retrieves elections, syncs enrollment, and sends confirmation.
        inputParameters:
          - name: employee_id
            in: body
            required: true
            type: string
          - name: period
            in: body
            required: true
            type: string
        steps:
          - name: get-elections
            call:
              operationId: getBenefitElections
              input:
                employeeId: "{{employee_id}}"
                period: "{{period}}"
          - name: sync
            call:
              operationId: syncEnrollment
              input:
                employeeId: "{{employee_id}}"
                elections: "{{get-elections.selections}}"
          - name: confirm
            call:
              operationId: sendEmail
              input:
                to: "{{employee_id}}@cvshealth.com"
                subject: "Benefits Enrollment Confirmed"
                body: "Your elections for {{period}} have been processed."
  consumes:
    - type: http
      baseUri: https://wd5-impl-services1.workday.com/ccx/api/v1/cvshealth
      authentication:
        type: bearer
        token: $secrets.workday_token
      resources:
        - path: /benefits/elections
          operations:
            - id: getBenefitElections
              method: GET
    - type: http
      baseUri: https://api.aetna.com/enrollment/v1
      authentication:
        type: bearer
        token: $secrets.aetna_enrollment_token
      resources:
        - path: /sync
          operations:
            - id: syncEnrollment
              method: POST
    - type: http
      baseUri: https://graph.microsoft.com/v1.0
      authentication:
        type: bearer
        token: $secrets.ms_graph_token
      resources:
        - path: /me/sendMail
          operations:
            - id: sendEmail
              method: POST

Onboards new CVS Health employees by creating Workday profile, provisioning access, and assigning training.

naftiko: "0.5"
info:
  title: Workday CVS Employee Onboarding
  version: "1.0"
  description: Onboards new CVS Health employees by creating Workday profile, provisioning access, and assigning training.
  tags: [human-resources, workday, healthcare]
capability:
  exposes:
    type: mcp
    port: 8080
    tools:
      - name: onboard_cvs_employee
        description: Creates profile, provisions Okta access, and assigns compliance training.
        inputParameters:
          - name: employee_id
            in: body
            required: true
            type: string
          - name: department
            in: body
            required: true
            type: string
          - name: role
            in: body
            required: true
            type: string
        steps:
          - name: create-worker
            call:
              operationId: createWorker
              input:
                employeeId: "{{employee_id}}"
                department: "{{department}}"
                role: "{{role}}"
          - name: provision-access
            call:
              operationId: provisionAccess
              input:
                employeeId: "{{employee_id}}"
                roleTemplate: "{{role}}"
          - name: assign-training
            call:
              operationId: assignLearning
              input:
                employeeId: "{{employee_id}}"
                courses: "HIPAA_101,CVS_Orientation,Pharmacy_Safety"
  consumes:
    - type: http
      baseUri: https://wd5-impl-services1.workday.com/ccx/api/v1/cvshealth
      authentication:
        type: bearer
        token: $secrets.workday_token
      resources:
        - path: /workers
          operations:
            - id: createWorker
              method: POST
    - type: http
      baseUri: https://cvshealth.okta.com/api/v1
      authentication:
        type: bearer
        token: $secrets.okta_token
      resources:
        - path: /apps/assignments
          operations:
            - id: provisionAccess
              method: POST
    - type: http
      baseUri: https://wd5-impl-services1.workday.com/ccx/api/v1/cvshealth
      authentication:
        type: bearer
        token: $secrets.workday_token
      resources:
        - path: /learning/assignments
          operations:
            - id: assignLearning
              method: POST

When a Workday leave of absence request is approved, updates the employee's Microsoft 365 account with an out-of-office reply, reassigns Salesforce cases to a backup agent, and creates a ServiceNow leave tracking task.

naftiko: "0.5"
info:
  label: "Workday Leave of Absence Processing"
  description: "When a Workday leave of absence request is approved, updates the employee's Microsoft 365 account with an out-of-office reply, reassigns Salesforce cases to a backup agent, and creates a ServiceNow leave tracking task."
  tags:
    - hr
    - leave-management
    - workday
    - salesforce
    - servicenow
capability:
  exposes:
    - type: mcp
      namespace: leave-management
      port: 8080
      tools:
        - name: process-leave-of-absence
          description: "Given a Workday leave request for a customer service employee, configure an out-of-office auto-reply in Microsoft 365, reassign their open Salesforce cases to a backup agent, and create a ServiceNow leave management task. Use when customer-facing employees take approved LOA."
          inputParameters:
            - name: worker_id
              in: body
              type: string
              description: "Workday worker ID of the employee taking leave."
            - name: leave_start_date
              in: body
              type: string
              description: "Leave start date in YYYY-MM-DD format."
            - name: leave_end_date
              in: body
              type: string
              description: "Expected leave end date in YYYY-MM-DD format."
            - name: backup_agent_id
              in: body
              type: string
              description: "Salesforce user ID of the backup agent to receive reassigned cases."
          steps:
            - name: get-worker
              type: call
              call: workday-leave.get-worker
              with:
                worker_id: "{{worker_id}}"
            - name: set-oof-reply
              type: call
              call: msgraph-leave.set-auto-reply
              with:
                user_principal_name: "{{get-worker.work_email}}"
                message: "I am on approved leave from {{leave_start_date}} to {{leave_end_date}}. Please contact my team for urgent matters."
            - name: create-leave-task
              type: call
              call: servicenow-leave.create-incident
              with:
                short_description: "Leave of Absence: {{get-worker.full_name}} ({{leave_start_date}} to {{leave_end_date}})"
                category: "HR Leave Management"
                description: "Worker: {{worker_id}}\nEmployee: {{get-worker.full_name}}\nLeave: {{leave_start_date}} to {{leave_end_date}}\nBackup Agent: {{backup_agent_id}}"
  consumes:
    - type: http
      namespace: workday-leave
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: workers
          path: "/cvs-health/workers/{{worker_id}}"
          inputParameters:
            - name: worker_id
              in: path
          operations:
            - name: get-worker
              method: GET
    - type: http
      namespace: msgraph-leave
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: auto-reply
          path: "/users/{{user_principal_name}}/mailboxSettings"
          inputParameters:
            - name: user_principal_name
              in: path
          operations:
            - name: set-auto-reply
              method: PATCH
    - type: http
      namespace: servicenow-leave
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST

When a new employee is created in Workday, opens a ServiceNow onboarding ticket, provisions Microsoft 365 access via Microsoft Graph, and sends a Microsoft Teams welcome message to the hiring manager.

naftiko: "0.5"
info:
  label: "Workday New Hire Onboarding Orchestration"
  description: "When a new employee is created in Workday, opens a ServiceNow onboarding ticket, provisions Microsoft 365 access via Microsoft Graph, and sends a Microsoft Teams welcome message to the hiring manager."
  tags:
    - hr
    - onboarding
    - workday
    - servicenow
    - microsoft-teams
capability:
  exposes:
    - type: mcp
      namespace: hr-onboarding
      port: 8080
      tools:
        - name: trigger-employee-onboarding
          description: "Given a Workday employee ID and start date, retrieve worker details, create a ServiceNow onboarding ticket, provision Microsoft 365 access, and send a Teams welcome notification to the hiring manager. Use when new hires are confirmed in Workday."
          inputParameters:
            - name: worker_id
              in: body
              type: string
              description: "Workday worker ID for the new hire."
            - name: start_date
              in: body
              type: string
              description: "Employee start date in ISO 8601 format (YYYY-MM-DD)."
          steps:
            - name: get-worker
              type: call
              call: workday.get-worker
              with:
                worker_id: "{{worker_id}}"
            - name: open-onboarding-ticket
              type: call
              call: servicenow.create-incident
              with:
                short_description: "New hire onboarding: {{get-worker.full_name}}"
                category: "HR"
                description: "Worker ID: {{worker_id}}\nStart Date: {{start_date}}\nDepartment: {{get-worker.department}}\nManager: {{get-worker.manager_name}}"
            - name: provision-m365
              type: call
              call: msgraph.create-user
              with:
                user_principal_name: "{{get-worker.work_email}}"
                display_name: "{{get-worker.full_name}}"
                department: "{{get-worker.department}}"
            - name: notify-manager
              type: call
              call: msteams.send-message
              with:
                recipient_upn: "{{get-worker.manager_email}}"
                message: "Your new team member {{get-worker.full_name}} starts on {{start_date}}. Onboarding ticket: {{open-onboarding-ticket.number}}."
  consumes:
    - type: http
      namespace: workday
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: workers
          path: "/cvs-health/workers/{{worker_id}}"
          inputParameters:
            - name: worker_id
              in: path
          operations:
            - name: get-worker
              method: GET
    - type: http
      namespace: servicenow
      baseUri: "https://cvshealth.service-now.com/api/now"
      authentication:
        type: basic
        username: "$secrets.servicenow_user"
        password: "$secrets.servicenow_password"
      resources:
        - name: incidents
          path: "/table/incident"
          operations:
            - name: create-incident
              method: POST
    - type: http
      namespace: msgraph
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: users
          path: "/users"
          operations:
            - name: create-user
              method: POST
    - type: http
      namespace: msteams
      baseUri: "https://graph.microsoft.com/v1.0"
      authentication:
        type: bearer
        token: "$secrets.msgraph_token"
      resources:
        - name: messages
          path: "/users/{{recipient_upn}}/sendMail"
          inputParameters:
            - name: recipient_upn
              in: path
          operations:
            - name: send-message
              method: POST

Retrieves current headcount and FTE distribution by department and business unit from Workday for HR and finance planning cycles.

naftiko: "0.5"
info:
  label: "Workday Payroll Headcount Snapshot"
  description: "Retrieves current headcount and FTE distribution by department and business unit from Workday for HR and finance planning cycles."
  tags:
    - hr
    - finance
    - workday
    - reporting
capability:
  exposes:
    - type: mcp
      namespace: hr-finance
      port: 8080
      tools:
        - name: get-headcount-snapshot
          description: "Retrieve the current headcount and FTE breakdown by department, business unit, and employment type from Workday. Use for monthly HR reporting, headcount planning, and budget variance analysis."
          call: workday-hc.headcount-report
          outputParameters:
            - name: total_headcount
              type: string
              mapping: "$.report.totalHeadcount"
            - name: total_fte
              type: number
              mapping: "$.report.totalFTE"
            - name: departments
              type: array
              mapping: "$.report.departments"
              items:
                - name: department_name
                  type: string
                  mapping: "$.name"
                - name: fte_count
                  type: number
                  mapping: "$.fteCount"
                - name: headcount
                  type: number
                  mapping: "$.headcount"
  consumes:
    - type: http
      namespace: workday-hc
      baseUri: "https://wd2-impl-services1.workday.com/ccx/api/v1"
      authentication:
        type: bearer
        token: "$secrets.workday_token"
      resources:
        - name: headcount-report
          path: "/cvs-health/reports/headcount"
          operations:
            - name: headcount-report
              method: GET