EcommerceGet started ecommercePayment gatewaysBuilding a custom payment gateway

Building a Custom Payment Gateway

Prerequisites

  • Good understanding of Liquid

  • Good understanding of JavaScript

  • Good understanding of GraphQL, including queries, related_models, mutations and using mutations to send API calls.

  • Good understanding of APIs

Introduction

Siteglide have built integrations between its eCommerce Module and three Payment Gateways:

  • Stripe - integrated with all Siteglide eCommerce Features

  • PayPal - for Checkout and Basic Payment Forms

  • Authorize.net - for Basic Payment Forms

In order to focus on improving features for the Payment Gateways we have, we won't be building integrations to any other Payment Gateways at this point. Instead, this Article is intended to help experienced Siteglide Partners build their own Payment Gateway Integrations.


Payment Gateway Configuration

We've opened up the Payment Gateway model (model_schema_name: "module_14/payment_gateway") to allow you to customize it to suit your own Payment Gateway:

Field NameField IDPurpose/Notes
Namemodule_field_14/payment_gateway_1Payment Gateway Display Name
Activemodule_field_14/payment_gateway_2Boolean Only one Payment Gateway should be active at a time.
Typemodule_field_14/payment_gateway_5Payment Gateway Name in snake_case - Must be unique to your Payment Gateway
In test mode?module_field_14/payment_gateway_8Boolean
Custom Payment Gateway Partial Pathmodule_field_14/payment_gateway_19Folder path for the partials you will use to include your Gateway code on the Form (see next section)

Use GraphQL to create a record in this table using the filelds above.

Next Steps

Now your Payment Gateway exists, it's time to give it some functionality. You can add support for one or more of the following:

How is this guide?

Last updated on

Powered by Holocron

Documentation