Eway provides a way to add invoice ref and description by adding params like InvoiceDescription and InvoiceReference in alterPaymentProcessorParams hook provided by civicrm.

Unfortunately this does not work for recurring payments.

Eway does not seem to provide any flexibility to set Invoice reference or Invoice Description for a recurring payment. See the parameter that could be set - https://eway.io/api-v3/#recurring-payments.

Any thoughts for an alternative way to set these field values?

We are using Eway recurring extension to record payments in civi - https://civicrm.org/extensions/eway-recurring-payment-processor

  • Have you had a look at the 'other' eWAY Recurring extension? github.com/agileware/au.com.agileware.ewayrecurring I haven't tried it but the code at least seems to use InvoiceDescription and InvoiceReference. Commented Nov 22, 2018 at 0:39
  • The above extension also seems to be providing invoice description and reference for one-off payments only. Commented Nov 22, 2018 at 3:57
  • what about the Omnipay option?
    – petednz - fuzion
    Commented Nov 23, 2018 at 20:30

1 Answer 1


ok - this has fixed for us and the reason was the incorrect param sent to the ProcessPayment operation. The correct way of sending the invoice params is -

$client = CRM_Core_Payment_EwayUtils::getClient($params['payment_processor_id']);
$endPoint = 'https://www.eway.com.au/gateway/managedpayment/ProcessPayment';

$paymentInfo = array(
  'man:managedCustomerID' => $params['managed_customer_id'],
  'man:amount' => $params['amount_in_cents'],
  'man:invoiceReference' => $params['invoice_id'],
  'man:invoiceDescription' => $params['description'],
$result = $client->call('man:ProcessPayment', $paymentInfo, '', $endPoint);

Note the correct usage of man:invoiceReference and man:invoiceDescription. It should be case-sensitive.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.