Checkout

Initiates the payment process, returns a URL which the user will be redirected

get
/v3/checkout

https://apis.sandbox.flexshopper.com/v3/checkout
Request
Response
Request
Headers
Authorization
required
string
Authorization token
Body Parameters
items.shipping.method
required
string
The item's shipping method.
items.shipping.date
required
string
The item's shipping date.
items.shipping.cost
required
number
The item's shipping cost.
customer
optional
object
Customer Info Object
customer.firstName
optional
string
Customer first name
customer.lastName
optional
string
Customer Last Name
customer.email
optional
string
Customer Email address
customer.phones.home
optional
string
Customer home phone number
customer.phones.mobile
optional
string
Customer mobile phone number
customer.address
optional
object
Customer address Object
customer.address.street1
required
string
Main Street Address
customer.address.street2
optional
string
Secondary Street address
customer.address.city
required
string
City
customer.address.region
required
string
Region or State
customer.address.postalCode
required
string
Zip Code
transactionId
required
string
The transaction ID provided at checkout.
items
required
array
A list of items to be added to the lease.
items.brand
required
string
The item's brand.
items.sku
required
string
The item's SKU (can be vendor-specific)
items.description
required
string
The item's description.
items.cost
required
number
The item's cost in dollars.
items.quantity
required
integer
The quantity of this item to add to the lease.
items.condition
required
string
Allowed values are: new, used and refurbished
items.productId
required
string
The item's product identifier.
items.images
required
array
Collection of product image URLs.
couponCode
optional
string
Coupon code for discounts to be calculated into the lease.
Response
200: OK
{
"data": {
"id": "44222abc17c76611009a0665",
"redirectUri": "https://pay.flexshopper.com/?id=example-id"
}
}

Request Payload Example

{
"transactionId": "5a6f7da94eb929002de90542",
"items": [
{
"description": "Macbook Pro 13",
"sku": "ABC123",
"productId": "58ac31fc2e074def0426b7cd",
"cost": 120.34,
"brand": "Apple",
"condition": "new",
"quantity": 1,
"images": [
"https://dummyimage.com/600x400/000/fff.png"
],
"shipping": {
"cost": 12.34,
"date": "2018-03-05",
"method": "ground"
}
}
],
"couponCode": "save",
"customer": {
"firstName": "John",
"lastName": "Doe",
"email": "johndoe@flexshopper.com",
"phones": {
"home": "1234567890",
"mobile": "1234567890"
},
"address": {
"street1": "2700 N Military Trail",
"street2": "Suite 200",
"city": "Boca Raton",
"region": "FL",
"postalCode": "33441"
}
}
}

Response Parameters

A successful request returns the HTTP 200 OK status code and a JSON response body that shows the checkout response

Key

Type

Description

redirectUri

String

Url which the customer should be redirected to complete the payment process