Braintree

FREE
By Atomoworks
Updated 7 days ago
Payments
4.3/10
Popularity Score
242ms
Latency
-
Success Rate

Braintree API Documentation

Accept web and mobile payments via PayPal, Venmo, credit and debit cards, Apple Pay, Google Pay and more.

View API Details
Quick Test
POSTping
POSTping

Basic Braintree API request / test

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
Braintree-VersionSTRING
REQUIRED
AuthorizationSTRING
REQUIREDBasic PUBLICKEY:PRIVATEKEY
Content-TypeSTRING
REQUIRED
Code Snippet
unirest.post("https://braintree.p.rapidapi.com/ping")
.header("X-RapidAPI-Host", "braintree.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Braintree-Version", "2019-07-11")
.header("Authorization", "Basic 7k27drydyq5v5nnk:217bc6f0a20c5951d5fe1ca2ee2d0c23")
.header("Content-Type", "application/json")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
Sample Response
General
Request URL: https://braintree.p.rapidapi.com/ping
Request Method: POST
Response Headers
"content-type": "application/json"
"date": "Sat, 13 Jul 2019 05:45:09 GMT"
"server": "openresty/1.13.6.1"
"content-length": "16"
"connection": "Close"
Response Body

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.post("https://braintree.p.rapidapi.com/ping")
.header("X-RapidAPI-Host", "braintree.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Braintree-Version", "2019-07-11")
.header("Authorization", "Basic 7k27drydyq5v5nnk:217bc6f0a20c5951d5fe1ca2ee2d0c23")
.header("Content-Type", "application/json")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication