Mews · Arazzo Workflow

Mews Refund Payment

Version 1.0.0

Find a refundable payment on a reservation, then refund it.

1 workflow 1 source API 1 provider
View Spec View on GitHub HospitalityHotelPMSProperty ManagementTravelBookingReservationsCloudSoftware-as-a-ServiceArazzoWorkflows

Provider

mews-com

Workflows

refund-payment
Locate a reservation payment and refund it.
Lists the payments on a reservation and, when one is present, refunds the first payment against its account for the supplied reason and value.
2 steps inputs: accessToken, client, clientToken, enterpriseId, reason, reservationId, valueToRefund outputs: refundId, refundedPaymentId, reservationId
1
listPayments
List the payments tied to the reservation to identify a payment that can be refunded.
2
refundPayment
Refund the identified payment against its account for the supplied reason and optional value.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Mews Refund Payment
  summary: Find a refundable payment on a reservation, then refund it.
  description: >-
    The Mews refund pattern. The Connector API payments/getAll action lists the
    payments on a reservation and the flow branches: when a payment is found it is
    refunded with payments/refund, optionally as a partial refund. Each step
    inlines its action-style POST body with the ClientToken, AccessToken, and
    Client authentication fields Mews requires so the flow reads and runs without
    opening the OpenAPI description.
  version: 1.0.0
  x-realizes-capability-ids:
  - BC-4020.60
  x-capability-derivation:
    method: 'deterministic join: sourceDescriptions -> per-tag OpenAPI -> tag/capability edge. No classification at this step.'
    min_confidence: 0.7
    sources:
    - capability_id: BC-4020.60
      capability_name: Booking Payment & Settlement
      spec: mews-com-payments-api-openapi.yml
      confidence: 0.7
    model: Turbo EA Capabilities by Vincent Verdet — Turbo EA, https://github.com/vincentmakes/turbo-ea-capabilities, CC BY 4.0
sourceDescriptions:
- name: paymentsApi
  url: ../openapi/mews-com-payments-api-openapi.yml
  type: openapi
workflows:
- workflowId: refund-payment
  summary: Locate a reservation payment and refund it.
  description: >-
    Lists the payments on a reservation and, when one is present, refunds the
    first payment against its account for the supplied reason and value.
  inputs:
    type: object
    required:
    - clientToken
    - accessToken
    - client
    - enterpriseId
    - reservationId
    - reason
    properties:
      clientToken:
        type: string
        description: The Mews ClientToken identifying the integration.
      accessToken:
        type: string
        description: The Mews AccessToken identifying the enterprise.
      client:
        type: string
        description: The client application name and version.
      enterpriseId:
        type: string
        description: The enterprise (property) the refund is recorded against.
      reservationId:
        type: string
        description: The reservation whose payment is refunded.
      reason:
        type: string
        description: The reason for the refund.
      valueToRefund:
        type: number
        description: Optional amount for a partial refund; omit for a full refund.
  steps:
  - stepId: listPayments
    description: >-
      List the payments tied to the reservation to identify a payment that can be
      refunded.
    operationId: payments_getAll
    requestBody:
      contentType: application/json
      payload:
        ClientToken: $inputs.clientToken
        AccessToken: $inputs.accessToken
        Client: $inputs.client
        ReservationIds:
        - $inputs.reservationId
        EnterpriseIds:
        - $inputs.enterpriseId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      paymentId: $response.body#/Payments/0/Id
      accountId: $response.body#/Payments/0/AccountId
    onSuccess:
    - name: hasPayment
      type: goto
      stepId: refundPayment
      criteria:
      - context: $response.body
        condition: $.Payments.length > 0
        type: jsonpath
    - name: noPayment
      type: end
      criteria:
      - context: $response.body
        condition: $.Payments.length == 0
        type: jsonpath
  - stepId: refundPayment
    description: >-
      Refund the identified payment against its account for the supplied reason
      and optional value.
    operationId: payments_refund
    requestBody:
      contentType: application/json
      payload:
        ClientToken: $inputs.clientToken
        AccessToken: $inputs.accessToken
        Client: $inputs.client
        PaymentId: $steps.listPayments.outputs.paymentId
        AccountId: $steps.listPayments.outputs.accountId
        Reason: $inputs.reason
        ValueToRefund: $inputs.valueToRefund
        EnterpriseId: $inputs.enterpriseId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      refundId: $response.body#/RefundId
      refundState: $response.body#/State
  outputs:
    reservationId: $inputs.reservationId
    refundedPaymentId: $steps.listPayments.outputs.paymentId
    refundId: $steps.refundPayment.outputs.refundId

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/mews-com-refund-payment-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.