younifyd
Menu

updatePayment

Updates an existing 'Payment'.

Use it in a workflow

  1. Add a step and choose the Fluent Commerce connector.
  2. Pick the updatePayment action (under Update).
  3. Fill in the fields below, then reference the result from later steps as {{updatepayment.response.data}}.

Query

This is the mutation the action sends by default. Edit it in the step's Query field to change which fields come back.

graphql
mutation UpdatePayment($input: UpdatePaymentInput) {
  updatePayment(input: $input) {
    amount {
      amount
      scale
      unscaledValue
    }
    attributes {
      name
      type
      value
    }
    billingAccount {
      address {
        city
        companyName
        country
        latitude
        longitude
        name
        postcode
        region
        state
        street
        timeZone
      }
      attributes {
        name
        type
        value
      }
      createdOn
      customer {
        ref
      }
      id
      name
      ref
      retailer {
        id
      }
      status
      type
      updatedOn
      workflow {
        ref
        version
      }
      workflowRef
      workflowVersion
    }
    createdOn
    id
    ref
    retailer {
      id
    }
    status
    type
    updatedOn
    workflow {
      ref
      version
    }
    workflowRef
    workflowVersion
  }
}

Variables

Pass these as a JSON object in the step's Variables field.

inputobject
attributesarray<object>3 fields
billingAccountobject1 fields
refstringrequired
statusstring
json
{
  "input": {
    "ref": "string",
    "attributes": [
      {
        "name": "string",
        "type": "string",
        "value": "string"
      }
    ],
    "billingAccount": {
      "ref": "string"
    },
    "status": "string"
  }
}

Response

Read the result with {{updatepayment.response.data.data.updatePayment}}. If the API returns errors, the step fails and they are at {{updatepayment.response.data.errors}}.

amountobject
amountnumber
scalenumber
unscaledValuenumber
attributesarray<object>
nameobject
typeobject
valueobject
billingAccountobject
addressobject11 fields
attributesarray<object>
createdOnstring
customerobject1 fields
idstring
namestring
refstring
retailerobject1 fields
statusstring
typestring
updatedOnstring
workflowobject2 fields
workflowRefstring
workflowVersionstring
createdOnstring
idstring
refstring
retailerobject
idstring
statusstring
typestring
updatedOnstring
workflowobject
refstring
versionnumber
workflowRefstring
workflowVersionnumber

Need more? See the Fluent Commerce guide for connection setup and behaviour shared by every action.