API Reference

Payment Gateway

Payment Gateway

The EdfaPay Payment Gateway enables your website or mobile application to securely process payments across various methods, including credit cards, Mada, and Apple Pay.

Our gateway is engineered to handle:

  • Secure communication between your system and financial institutions.
  • Full compliance with PCI-DSS and 3D Secure standards.
  • Real-time transaction status updates and callback notifications.

Payment Flow

The following diagram illustrates the EdfaPay Payment Flow, detailing the interaction between your system, the customer, and the EdfaPay gateway.


  1. Initiate Payment Request: Your system sends a request to the EdfaPay API to create a new payment transaction.
  2. Receive Payment URL: EdfaPay responds with a secure, hosted payment page URL.
  3. Redirect Customer: You redirect your customer to the provided URL to complete the payment.
  4. Customer Completes Payment: The customer selects their preferred payment method (Card, Mada, Apple Pay) and finalizes the transaction on EdfaPay’s secure page.
  5. Payment Processing: EdfaPay securely processes the payment through the relevant card network or bank.
  6. Callback Notification: EdfaPay sends the transaction result to your backend via the configured callback URL.
  7. Customer Redirect: Upon payment completion, EdfaPay redirects the customer to your designated success or failure URL.
  8. Final Order Update: Your system updates the order status based on the received callback response.

Payment Gateway Endpoints

Below is a summary of the key API endpoints available for integration with the EdfaPay Payment Gateway:

EndpointDescription
/payment/initiateInitiates a new payment transaction.
/payment/statusRetrieves the status of a payment transaction.
/payment/refundInitiates a refund for a completed transaction.
/payment/RecurringVoids (cancels) an authorized payment.

Integration Types

We offer two robust integration models to align with your technical requirements and desired level of control:

Hosted CheckoutServer-to-Server (S2S)
Redirects customers to EdfaPay’s secure hosted payment page.Merchants build and maintain their own checkout user interface.
No sensitive card data is handled by the merchant.Card data is securely transmitted from the merchant backend to EdfaPay via API.
PCI compliance is fully managed by EdfaPay.The merchant assumes full responsibility for PCI compliance.
Offers rapid implementation with minimal development effort.Provides complete control over UI/UX and customer payment workflows.
Supports all available payment methods.Ideal for mobile applications and highly customized platforms.

Supported Features

Our platform is equipped with a comprehensive suite of features to enhance your payment processing capabilities:

  • Authorization & Capture: Allows pre-authorization of funds with subsequent capture.
  • Refunds: Supports full or partial refunds initiated via API.
  • Recurring Payments: Facilitates subscription models through the use of recurring tokens.
  • Webhooks: Delivers real-time transaction updates to your system.
  • Fraud Checks: Incorporates integrated mechanisms for fraud detection.