Integrate Keap with Braintree

Appy Pie Connect allows you to automate multiple workflows between Keap and Braintree

  • No code
  • No Credit Card
  • Lightning Fast Setup
20 Million man hours saved

Award Winning App Integration Platform

About Keap

Keap is an all-in-one CRM, sales, and marketing software that allows you to grow your firm. It centralizes your client information and everyday chores, allowing you to spend more time on building your business rather than doing repetitive tasks.

About Braintree

Braintree is a software solution that helps businesses process payments and manage financial relationships with merchants securely and reliably.

Braintree Integrations
Braintree Alternatives

Looking for the Braintree Alternatives? Here is the list of top Braintree Alternatives

  • Stripe Integration Stripe
  • Paypal Integration Paypal

Best Keap and Braintree Integrations

  • Keap Integration Braintree Integration

    Keap + Braintree

    Create Customer to Braintree from New Task in Keap Read More...
    Close
    When this happens...
    Keap Integration New Task
     
    Then do this...
    Braintree Integration Create Customer
  • Keap Integration Braintree Integration

    Keap + Braintree

    Create Customer to Braintree from New Contact in Keap Read More...
    Close
    When this happens...
    Keap Integration New Contact
     
    Then do this...
    Braintree Integration Create Customer
  • Keap Integration Braintree Integration

    Keap + Braintree

    Create Customer to Braintree from New Appointment in Keap Read More...
    Close
    When this happens...
    Keap Integration New Appointment
     
    Then do this...
    Braintree Integration Create Customer
  • Keap Integration Braintree Integration

    Keap + Braintree

    Create Customer from Braintree from Updated Contact to Keap Read More...
    Close
    When this happens...
    Keap Integration Updated Contact
     
    Then do this...
    Braintree Integration Create Customer
  • Keap Integration Braintree Integration

    Keap + Braintree

    Create Customer to Braintree from New Company in Keap Read More...
    Close
    When this happens...
    Keap Integration New Company
     
    Then do this...
    Braintree Integration Create Customer
  • Keap Integration {{item.actionAppName}} Integration

    Keap + {{item.actionAppName}}

    {{item.message}} Read More...
    Close
    When this happens...
    {{item.triggerAppName}} Integration {{item.triggerTitle}}
     
    Then do this...
    {{item.actionAppName}} Integration {{item.actionTitle}}
Connect Keap + Braintree in easier way

It's easy to connect Keap + Braintree without coding knowledge. Start creating your own business flow.

    Triggers
  • New Appointment

    Triggers when a new appointment created.

  • New Company

    Triggers when a new company created.

  • New Contact

    Triggers when a new contact created.

  • New Invoice

    Trigger when a new invoice created.

  • New Payment

    Trigger when a new payment received.

  • New Tag

    Triggers when new tag is created.

  • New Task

    Triggers when a new task is created.

  • Tag Added to Contact in Keap

    Triggers when a tag is added to a contact the first time.

  • Updated Contact

    Triggers when an existing contact is updated.

  • New Customer

    Triggers when you add a new customer.

  • New Transaction

    Triggers when you add a new transaction.

    Actions
  • Create Company

    Creates a new company.

  • Create Invoice

    Creates a new invoice.

  • Create Note

    Creates a new note on a contact record.

  • Create Task

    Creates a new task.

  • Create or Update Contact

    Creates a new contact or updates an existing contact.

  • Tag Contact

    Apply tags to a contact.

  • Create Customer

    Create a new customer.

Compliance Certifications and Memberships

Highly rated by thousands of customers all over the world

We’ve been featured on

featuredon
Page reviewed by: Abhinav Girdhar  | Last Updated on July 01, 2022 5:55 am

How Keap & Braintree Integrations Work

  1. Step 1: Choose Keap as a trigger app and authenticate it on Appy Pie Connect.

    (30 seconds)

  2. Step 2: Select "Trigger" from the Triggers List.

    (10 seconds)

  3. Step 3: Pick Braintree as an action app and authenticate.

    (30 seconds)

  4. Step 4: Select a resulting action from the Action List.

    (10 seconds)

  5. Step 5: Select the data you want to send from Keap to Braintree.

    (2 minutes)

  6. Your Connect is ready! It's time to start enjoying the benefits of workflow automation.

Integration of Keap and Braintree

Keap?

Keap is an open source project that allows you to add a security layer to your application. Keap is a security framework that makes it easy to add a secure layer to your application, and it can be easily integrated with existing systems. It does this by letting developers plug in a custom security provider, where the provider will handle all of the cryptographic operations. The current security providers are bcrypt and scrypt.

Braintree?

Braintree is a company based in Chicago that provides payment services for companies to accept payments from their customers. They provide things like credit card processing, ACH/eCheck processing, and recurring billing. They offer both a Gateway product that enables merchants to accept credit card transactions from a variety of payment methods and a Hosted Checkout product that allows merchants to process credit cards without a merchant account through a 3rd party processor. They also have a Mobile SDK that can be used to accept payments on mobile devices using a variety of different methods. There is a PHP library provided by Braintree for all of these products.

Integration of Keap and Braintree

The way Keap works is that it calls into a cryptographic provider to provide cryptographic operations, instead of handling them within the application itself. In order to use this, you need to have a secure cryptographic provider set up already. If you do not, you can go ahead and use the bcrypt or scrypt security providers that are included with the Keap module. You just need to include the security provider into your app's composer dependencies directory, then run composer install. For example, if I wanted to use the scrypt provider, I would include "keap/keap". "1.*" in my composer.php file, then run composer install. Now you need to require the keap library in your application's bootstrap file. You can do so like so:

<?php require_once __DIR__ . '/vendor/autpoad.php'; $provider = new VptKeapProvidersScrypt($secret); $security = new VptKeapKeap($provider); $app = new VptKeapKeapContainer($security); $app->run();

Now all you need to do is change your configuration file (config/app.php. to point it at one of your payment gateways (in my case I am pointing it at Braintree):

'gateway' => 'braintree', // This is your gateway key 'host' => 'secure.braintreegateway.com', // This is your hostname 'public_key' => '*******************', // This is your public key 'private_key' => '*****************************', // This is your private key 'merchant_id' => '********************', // This is your merchant ID 'environment' => 'live', // This determines whether you are testing or live 'failover' => array( // This is for failover options array('backup_uri' => 'false'. ), );

Note. Make sure you have an account with Braintree before attempting to integrate the two together!

Now that we have everything set up, let's look at some code! If you are using Vpt's default contrpler generator, every contrpler has some code injected into it that will allow it to create an API endpoint for us. We are going to use this code snippet to create an endpoint where we can sign up our users with our Braintree account:

<?php namespace AppHttpContrplers; use VptRestContrpler; use AppHttpContrplersContrpler; use IlluminateHttpRequest; class RegisterContrpler extends Contrpler { /** * Show the registration form for the application. / public function registerAction(. { return $this->api()->post('register'); } /* * Create a new resource. * * @param Request $request * @return RestResponse */ public function postRegister(Request $request. { $data = $request->only('email', 'password'); $user = $this->braintree->createUser($data); return $this->createStatusCode([200], ['success' => $user->email]); } }

If we send a POST request to /register we can successfully register a user with our Braintree account! Let's take a look at creating a customer as well:

public function createCustomerAction(. { return $this->api()->post('customers', [ 'email' => $email, 'password' => $password ]); } public function updateCustomerAction(. { return $this->api()->put('customers', [ 'email' => $email, 'password' => $password ]); } /** * Customer resource. * * @param Request $request * @return RestResponse / public function postCustomers(Request $request. { if ($request->has('email'). { $user = User::where('email', '=', $request->get('email'))->first(); if (!$user. { throw new InvalidEmailException(); } else { try { if ($request->has('password'). { $user->setPassword($request->get('password')); } else { throw new InvalidPasswordException(); } } catch (Exception $e. { return response()->json(['error' => true], 500); } } } else { throw new InvalidRequestException(); } return response()->json(['status' => true], 200); } /* * Customer resource. * * @param Request $request * @return RestResponse / public function putCustomers(Request $request. { if ($request->has('email'). { try { if ($request->has('password'). { User::updateOrCreate($request->get('email'), ['password' => $request->get('password')]); } else { throw new InvalidPasswordException(); } } catch (Exception $e. { return response()->json(['error' => true], 500); } } else { throw new InvalidRequestException(); } return response()->json(['status' => true], 200); } /* * Customer resource. * * @param Request $request * @return RestResponse / public function deleteCustomers(Request $request. { if ($request->has('email'). { try { User::destroy($request->get('email')); return response()->json(['status' => true], 200); } catch (Exception $e. { return response()->json(['error' => true], 500); } } else { throw new InvalidRequestException(); } return response()->json(['status' => true], 200); } /* * Customer resource. * * @param Request $request * @return RestResponse */ public function getCustomers(Request $request. { return response()->json(['status' => true], 200); } ?>

We have exposed all of the necessary RESTful actions in order to create, update, retrieve, and destroy customers in our system. To go along with these actions, we also have some helper methods that will allow us to check whether any given email address exists in our database or not. These helper methods are exposed in our contrpler via the magic of IoC. After creating our contrpler, we are ready to go! And don't worry about having to create any sort of frontend while you are working on your backend - while you are working on your back end, Vpt will automatically generate React components based on your models. If you want to see what they look like, simply run npm run watch in your terminal while you are working on the webpack dev server! It will automatically rebuild your React components whenever you make changes! Now let's talk about how we can test our contrplers! Let's create some tests for our register contrpler:

/** * Test for creating users via Braintree gateway. */ public function testRegisterUser(. { // Create an instance of the contrpler under test (AppHttpContrplersRegisterContrpler::class. $contrpler = app(AppHttpContrplersRegisterContrpler::class); // Create an instance of our test database adapter (VptTestDatabaseAdapter::class. $db = app(VptTestDatabaseAdapter::class); // Create an instance of our test storage adapter (TestStorage::class. $storage = app(TestStorage::class); // Create an instance of our test "payload" object (AppPayloadsRegisterUserPayload

The process to integrate Keap and Braintree may seem complicated and intimidating. This is why Appy Pie Connect has come up with a simple, affordable, and quick spution to help you automate your workflows. Click on the button below to begin.