Getting started

Note: If you haven’t chosen your integration method yet, begin by selecting your method and following the ‘What to do next’ steps first.

Easily handle simple and secure payments on your back-end with the Judopay server side PHP SDK.


Integration

Requirements

  • PHP 5.3.3 and above
  • PHP cURL extension
  • Composer

Using Composer Package Manager, add the Judopay package to your composer.json file:

"require": {
    "judopay/judopay-sdk": "~2.0"
}

Then execute:

$ composer install

Make the Judopay SDK classes available within your application by requiring the ‘vendor/autoload.php’ file.

See Composer for more information on getting started.


Setup

To start setting up your app, please complete all the relevant integration steps in the setup section. By following these steps, you are ensuring that your app will be secure and frictionless for you and your customers.

When you have completed the setup, start using Judopay’s PHP SDK by adding your app’s token and secret to your app configuration when initializing the SDK:

$judopay = new \Judopay(
    array(
        'apiToken' => 'your-token,
        'apiSecret' => 'your-secret',
        'judoId' => 'your-judo-id',
        //Set to true on production, defaults to false which is the sandbox
        'useProduction' => false
    )
);

Remember, if you perform payments only from your backend, you should only enable the ‘Register Card Transactions’ permission for your app and create a separate app for your backend with only the ‘Make Payments’ permission enabled.

Note: Processing transactions with AmEx cards requires that your account supports it as well. Please contact us first if you are planning to accept AmEx.

The SDK allows further configuration. These are the options:

  • Logging – You will be able to attach a logger library to help you debugging your Judopay integration. Any PSR-3 standard library is compatible, but we recommend use Monolog.

Payment types

Setup the payment types you require for your app. Depending on your chosen integration method you have a variety of payment types.


Test sandbox payments

Test your app quickly and securely with different payment types. The Sandbox testing guide will provide you all the details you need to ensure a solid integration. Here are some highlights:

  • Ensure that the SDK is properly configured for sandbox environment.
  • Use the test cards provided in the dashboard, under ‘Tools › Generating transactions’.
  • If 3D Secure is enabled and you want to simulate the 3D Secure screen, contact us for card details.

Note: Test all the payment types you require in the sandbox environment before going live.


Device DNA

To protect your app from fraud in real-time, Device DNA™ is an essential component of JudoShield that enables Judopay to capture data and device signals at the time of the transaction.

If you are integrating the ‘Mobile and your server side method’, you need to use Device DNA on the mobile in conjunction with your backend when making a payment:

  • To setup Device DNA for your server side SDK please follow the Getting started guide.
  • To setup Device DNA for your mobile app, please follow the Getting started guides for iOSAndroid.

Learn more about Device DNA.


Ready to go live?

When you have completed these steps, you are ensuring that your app will be secure and frictionless for you and your customers.

Follow the next steps in the Going live guide.