Skip to content

Fix: Adjust endpoints as per full-pipeline QA findings

stephen requested to merge initial-civi-pipeline-qa-responses into main

Now that donate-neo staging and Civi staging share an environment and are talking to one another, it's possible to perform testing against the entire life cycle of a donation, from initial pageload to CRM record. As a result, both myself and @mathieu have been working busily to ensure each end of the pipeline is ready to communicate in a way that the other will understand.

This MR smooths out this communication in two ways:

  1. CiviCRM does not actually need to know about failed one-time transactions. The teams who gather data against failed transactions either do so from Stripe (who are better able to generate metrics around which failed one-times were genuine) or the TPA team (who are better able to generate metrics around which failed one-times were clearly malicious). This commit keeps failed one-time Stripe or Paypal donations from being passed along to civi.report_donation(), but we still log the failures. (Metrics will be extended to cover this behavior once those metrics are finalized - see #77 (closed) and !105 (merged) for more context.)
  2. Paypal subscription data was not being prepared properly on the donate-neo side of things for CiviCRM's benefit. This commit enforces two patterns for all CiviCRM-bound Paypal info: 2a. args["trxn_id"] always refers to an ID unique to the transaction being logged 2b. args["recurring_contribution_transaction_id"] always refers to an ID common to the subscription being billed against

These changes have been confirmed by both @mattlav and @mathieu to represent proper downstream messaging handling (but of course bug fixes etc are always welcome :D).

Merge request reports