PAYMENTS
SIMPLIFIED


Offer all the payment features your
customers want with a fast integration
that limits your PCI scope.

GET STARTED

API Base URLs

  • Production Server

    For processing live transactions

    https://api.payjunction.com

  • Test Server

    For development

    https://api.payjunctionlabs.com

Most Commonly Referred to Articles

POST /invoices

Create a new invoice and send an email to the customer.

required name format description
* amountBase Money, Format: X.XX
Ex: 1000.00

Base amount to charge
  attachmentId Valid file ID File to attach to the invoice email
* customerEmail Max Length 255 Email of the customer the Invoice will be sent to
  customerFirstName Max Length 16 The customer's first name
  customerIdentifier Max Length 64 Customer ID, if you have your own customer ID you would like to associate with the invoice
  customerLastName Max Length 32 The customer's last name
  invoiceNumber Max Length 32 An invoice number
  message Max Length 2048 Message to the customer, displayed in the email
  notificationType "EMAIL" or "NONE" Determines whether an email notification is sent to the customer. Defaults to "EMAIL".
* terminalId Valid Terminal ID The terminal on which to process the transaction when the invoice is paid
To attach a PDF file to the Invoice you must first save it to the Invoice system using POST /invoices/files
Invoices can be voided and reopened after creation but they cannot be edited. If an Invoice must be corrected, the original must be voided and a new Invoice created.

Example Request (please replace placeholder values)

curl -X POST https://api.payjunction.com/invoices \
  -u "login:password" \
  -H "Accept: application/json" \
  -H "X-PJ-Application-Key: YOUR_PRODUCTION_APP_KEY" \
  -d amountBase=1.99 \
  -d customerEmail=jdoe@payjunction.com \
  -d customerFirstName=John \
  -d customerLastName=Doe \
  -d invoiceNumber="TO-123456" \
  -d message="Invoice for takeout order #123456" \
  -d terminalId=1

Example Request in the "Labs Demo" account

curl -X POST https://api.payjunctionlabs.com/invoices \
-u "pj-ql-01:pj-ql-01p" \
-H "Accept: application/json" \
-H "X-PJ-Application-Key: c0d73641-65ae-4e9b-bbab-fb6215d7ee98" \
-d amountBase=1.99 \
-d customerEmail=jdoe@payjunction.com \
-d customerFirstName=John \
-d customerLastName=Doe \
-d invoiceNumber="TO-123456" \
-d message="Invoice for takeout order #123456" \
-d terminalId=1

Example Response

{
  "amountBase" : "1.99",
  "created" : "2020-11-24T01:19:23Z",
  "customerEmail" : "jdoe@payjunction.com",
  "customerFirstName" : "John",
  "customerIdentifier" : "customer-id",
  "customerLastName" : "Doe",
  "hostedInvoiceUrl" : "https://www.payjunction.com/trinity/invoice#/e321790e-c030-4501-aa99-09e35158c1a6"
  "invoiceId" : "e321790e-c030-4501-aa99-09e35158c1a6",
  "invoiceNumber" : "TO-123456",
  "lastModified" : "2020-11-24T01:19:23Z",
  "message" : "Invoice for takeout order #123456",
  "status" : "OPEN",
  "terminalId" : 1
}