Fave · Arazzo Workflow

Accept a FavePay Omni payment and refund it

Version 1.0.0

Create a QR-code charge, confirm it succeeded via transaction lookup, then issue a full refund. All operationIds are verified against the FavePay Omni OpenAPI.

1 workflow 1 source API 1 provider
View Spec View on GitHub CompanyPaymentsFintechQR PaymentsLoyaltyCashbackMerchant ServicesSoutheast AsiaWebhooksArazzoWorkflows

Provider

fave

Workflows

acceptAndRefund
Create a charge, confirm success, then refund it.
3 steps inputs: app_id, country_code, omni_reference, outlet_id, sign, total_amount_cents outputs: confirmed_status
1
createCharge
createQrCode
2
confirmPayment
getTransaction
3
refund
refundTransaction

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Accept a FavePay Omni payment and refund it
  version: 1.0.0
  description: >-
    Create a QR-code charge, confirm it succeeded via transaction lookup, then
    issue a full refund. All operationIds are verified against the FavePay Omni
    OpenAPI.
sourceDescriptions:
  - name: favepayOmni
    url: ../openapi/fave-favepay-omni-openapi.yml
    type: openapi
workflows:
  - workflowId: acceptAndRefund
    summary: Create a charge, confirm success, then refund it.
    inputs:
      type: object
      required: [country_code, app_id, outlet_id, omni_reference, total_amount_cents, sign]
      properties:
        country_code: { type: string }
        app_id: { type: string }
        outlet_id: { type: integer }
        omni_reference: { type: string }
        total_amount_cents: { type: integer }
        sign: { type: string }
    steps:
      - stepId: createCharge
        operationId: createQrCode
        parameters:
          - name: country_code
            in: path
            value: $inputs.country_code
        requestBody:
          contentType: application/json
          payload:
            omni_reference: $inputs.omni_reference
            total_amount_cents: $inputs.total_amount_cents
            app_id: $inputs.app_id
            outlet_id: $inputs.outlet_id
            sign: $inputs.sign
        successCriteria:
          - condition: $statusCode == 200
      - stepId: confirmPayment
        operationId: getTransaction
        parameters:
          - name: country_code
            in: path
            value: $inputs.country_code
          - name: app_id
            in: query
            value: $inputs.app_id
          - name: omni_reference
            in: query
            value: $inputs.omni_reference
          - name: sign
            in: query
            value: $inputs.sign
        successCriteria:
          - condition: $statusCode == 200
        outputs:
          status: $response.body#/status
      - stepId: refund
        operationId: refundTransaction
        parameters:
          - name: country_code
            in: path
            value: $inputs.country_code
        requestBody:
          contentType: application/json
          payload:
            omni_reference: $inputs.omni_reference
            app_id: $inputs.app_id
            status: refunded
            sign: $inputs.sign
        successCriteria:
          - condition: $statusCode == 200
    outputs:
      confirmed_status: $steps.confirmPayment.outputs.status