---
schema_version: "1"
id: 26ab9d64293f885f9a40ad338bdb2886c43f03cde138e04c7a87a0e9d93a0179
title: Create an Apex Class to Process Payments Status
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/service/264-0-0/messaging_whatsapp_pay_create_apex.md
canonical_url: https://help.salesforce.com/s/articleView?id=service.messaging_whatsapp_pay_create_apex.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 631e5f2d3b2dac2e024668e41c83a63671c009868377eec7ad62d41185ccd85a
description: On the Apex Classes page in Setup, create an Apex class to facilitate payment status processing.
products:
  - Service Cloud
  - Digital Engagement
release: "264"
---
# Create an Apex Class to Process Payments Status

On the Apex Classes page in Setup, create an Apex class to facilitate payment status processing.

When a customer makes a requested payment, the payment status is sent back to this Apex class so that the status can be used for further processing. For example, you can use the status for sending notifications, inventory management, order tracking, and so on. For more information on how to create an Apex class, see [Create an Apex Class](https://trailhead.salesforce.com/content/learn/projects/quickstart-apex/quickstart-apex-1).

For details and an example, see [ProcessPaymentStatusHandler Interface](https://developer.salesforce.com/docs/atlas.en-us.apexref.meta/apexref/apex_interface_RichMessaging_ProcessPaymentStatusHandler.htm) and [Sample Code Snippets for Apex Classes](https://help.salesforce.com/s/articleView?id=service.messaging_whatsapp_payment_apex_snippets.htm&release=264.0.0&type=5 "Use these Apex classes to define the parameters required for WhatsApp Pay integration.").