Poynt API


Just install the Poynt Node.js SDK (GitHub) and you are ready to go!

npm install poynt --save

Just install the Poynt Python SDK (GitHub) and you are ready to go!

pip install poynt

Introduction

Poynt REST APIs provide applications an ability to integrate with Poynt Services in the cloud.


Standards

All Poynt APIs are built with commonly used RESTful design patterns in the industry. Below you’ll see all the Poynt Services and Entities exposed as Resources that you can access through standard HTTP semantics. HTTP status codes are used to communicate the success/failures states, OAuth2.0 is used for API Authentication and Authorization, and HTTP methods are used to operate on the resources.

Please take a note of the common patterns listed below that would help in simplifying your integration process.

Endpoint

All Poynt APIs can be accessed at: https://services.poynt.net.

HTTP Headers

All Poynt APIs should be invoked with the following standard HTTP headers unless otherwise specified:

HTTP Status Code

All Poynt APIs return one or more of the following codes.

Dates/Times

All date time values are in GMT and is formatted in ISO 8601 format YYYY-MM-DDThh:mm:ssZ.

Resource Updates

HTTP PATCH method is used to allow updates to existing Resources using json-patch as the request payload. Currently only add, remove, and replace operations are supported.

Pagination

Pagination is controlled by five parameters for most GET collection APIs. These parameters determine the result set and allow you to paginate through them.

If-Modified-Since header
ISO8601 Time to filters result by item’s last updated time.
startAt query
ISO8601 Time to filters result by a specific start time.
startOffset query
Integer offset from first item.
endAt query
ISO8601 Time to filters result by a specific end time.
limit query
Integer value 1 to 100 to limit the number of items returned. Default is 10.

Clients are encouraged to begin paging through a collection by specifying the If-Modified-Since header at the start of their paging request. A limit should also be specified to control the number of returned items. Should there be more items than can be returned, a HATEOAS link will also be returned.

If, however, the client wishes to specify a specific time window, it should use the startAt/endAt time window. This time window will be used to filter items out based on the item’s updatedAt time. When startAt is specified, the server will ignore the If-Modified-Since header. If no endAt time is specified, it is assumed to be up to the latest time (now).

Clients should generally not need to use the startOffset parameter. This parameter is used by the server to control the paging range in the HATEOAS links that it generates.


Oauth

Poynt APIs are secured with OAuth 2.0 to allow merchants to share data with developer applications as appropriate. The Poynt OAuth2.0 authorization API consist of a single token resource (end point) where client applications can obtain access tokens that can be used to invoke all other APIs.


Definition

POST /token

Sample Request

curl -H "api-version:1.2" -d "grantType=urn:ietf:params:oauth:grant-type:jwt-bearer&assertion=MY.SELFSIGNED.JWT" https://services.poynt.net/token
curl -H "api-version:1.2" -H "Authorization: MY.SELFSIGNED.JWT" -d "grantType=PASSWORD&businessId=d4b4ec82-0b3a-49c9-8424-1a6c16e3562a&username=Kelly&password=1234" https://services.poynt.net/token

Sample Response

{"expiresIn":900, "accessToken":"POYNT.ISSUED.JWT", "refreshToken":"REFRESH_TOKEN", "scope":"ALL", "tokenType":"BEARER"}

Definition

In the Node.js SDK, token generation and refresh is done automatically, behind the scenes, and so you don’t have to worry about it yourself. Simply initialize the poynt service with your application ID and either a filename or a string containing your PEM-encoded private key you downloaded from Poynt.net:

var poynt = require('poynt')({
  applicationId: 'urn:aid:your-application-id',
  filename: __dirname + '/key.pem'
});

or

var poynt = require('poynt')({
  applicationId: 'urn:aid:your-application-id',
  key: '-----BEGIN RSA PRIVATE KEY-----\n.....\n-----END RSA PRIVATE KEY-----'
});

Definition

In the Python SDK, token generation and refresh is done automatically, behind the scenes, and so you don’t have to worry about it yourself. Simply initialize the poynt service with your application ID and either a filename or a string containing your PEM-encoded private key you downloaded from Poynt.net:

import poynt

poynt.application_id = 'urn:aid:your-application-id'
poynt.filename = '/path/to/your/key.pem'

or

import poynt

poynt.application_id = 'urn:aid:your-application-id'
poynt.key = '-----BEGIN RSA PRIVATE KEY-----\n.....\n-----END RSA PRIVATE KEY-----'

Token

Generate an access token with either Json Web Token (JWT) bearer, password, or refresh token grant type.

The JWT bearer grant requires that the input grantType form parameter be urn:ietf:params:oauth:grant-type:jwt-bearer as defined by the JWT Profile for OAuth 2.0 specification. A self-signed JWT token must be provided by the client that is signed using the client’s private key.

The password grant requires that a self-signed JWT token be provided via the Authorization http header in addition to the business user’s businessId, username, and password.

Refresh token is also granted along with Access tokens to allow applications to refresh tokens that have expired. These tokens must always be stored securely by the applications.

Response

Returns a TokenResponse.


Payments


Orders

Orders resource represents a customer’s request to purchase one or more items (goods or services) from a business. As such an order contains details about all the items that we purchased, discounts applied and transactions that paid for the order. An order can be in Opened, Cancelled or Completed states. The only thing these states really tell is whether the order is active from the merchant’s perspective or not. An active order will be in Opened state. An order that the merchant is done with will be in Completed or Cancelled state. Similarly items have their own states (Ordered, Fulfilled and Returned) and transactions their own (see documentation for Transactions). Typically a merchant would want to keep the Order in Opened state until all items in the order have either been Fulfilled or Returned and all payments have been completed.


Definition

GET /businesses/{businessId}/orders

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getOrders = function getOrders(options, next) { ... }
/**
 * Get all orders at a business.
 * @param {String} options.businessId
 * @param {String} options.startAt (optional) - the time from which to start fetching orders
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional) - the time at which to stop fetching orders
 * @param {Integer} options.limit (optional) - the number of orders to fetch
 * @param {String} options.cardNumberFirst6 (optional) - limit results to orders with transactions done by cards starting with these 6 numbers
 * @param {String} options.cardNumberLast4 (optional) - limit results to orders with transactions done by cards ending with these 4 numbers
 * @param {Integer} options.cardExpirationMonth (optional) - limit results to orders with transactions done by cards expiring in this month
 * @param {Integer} options.cardExpirationYear (optional) - limit results to orders with transactions done by cards expiring in this year
 * @param {String} options.cardHolderFirstName (optional) - limit results to orders with transactions done by cards with this card holder first name
 * @param {String} options.cardHolderLastName (optional) - limit results to orders with transactions done by cards with this card holder last name
 * @param {String} options.storeId (optional) - only fetch orders for this store
 * @param {String} options.includeStaysAll (optional)
 * @return {OrderList} orders
 */

Sample Request

poynt.getOrders({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
})

Sample Response

{
  "count": 1,
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/orders?startAt=2017-02-03T02%3A34%3A14Z&endAt=2017-08-28T06%3A26%3A45Z&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ],
  "orders": [
    {
      "amounts": {
        "capturedTotals": {
          "cashbackAmount": 0,
          "currency": "USD",
          "orderAmount": 625,
          "tipAmount": 68,
          "transactionAmount": 693
        },
        "currency": "USD",
        "discountTotal": 0,
        "feeTotal": 0,
        "netTotal": 625,
        "subTotal": 625,
        "taxTotal": 0
      },
      "context": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "employeeUserId": 5247870,
        "source": "INSTORE",
        "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
        "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
        "transactionInstruction": "NONE"
      },
      "createdAt": "2017-02-03T01:40:21Z",
      "customerUserId": 5249839,
      "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
      "items": [
        {
          "createdAt": "2017-02-03T01:40:21Z",
          "discount": 0,
          "fee": 0,
          "id": 1,
          "name": "water",
          "productId": "f9faac3a-be56-4bff-b60b-84987cf021cb",
          "quantity": 5,
          "sku": "water",
          "status": "FULFILLED",
          "tax": 0,
          "taxExempted": false,
          "unitOfMeasure": "EACH",
          "unitPrice": 125,
          "updatedAt": "2017-02-03T01:40:21Z"
        }
      ],
      "orderNumber": "4",
      "statuses": {
        "fulfillmentStatus": "FULFILLED",
        "status": "OPENED",
        "transactionStatusSummary": "COMPLETED"
      },
      "taxExempted": false,
      "transactions": [
        {
          "action": "AUTHORIZE",
          "actionVoid": false,
          "adjusted": true,
          "amounts": {
            "cashbackAmount": 0,
            "currency": "USD",
            "customerOptedNoTip": false,
            "orderAmount": 625,
            "tipAmount": 68,
            "transactionAmount": 693
          },
          "amountsAdjusted": true,
          "authOnly": false,
          "context": {
            "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
            "businessType": "TEST_MERCHANT",
            "employeeUserId": 5247870,
            "mcc": "5812",
            "source": "INSTORE",
            "sourceApp": "co.poynt.services",
            "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
            "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
            "transmissionAtLocal": "2017-02-03T01:40:08Z"
          },
          "createdAt": "2017-02-03T01:40:09Z",
          "customerUserId": 5249839,
          "fundingSource": {
            "card": {
              "cardHolderFirstName": "LAWRENCE",
              "cardHolderFullName": "LUK/LAWRENCE",
              "cardHolderLastName": "LUK",
              "expirationDate": 31,
              "expirationMonth": 8,
              "expirationYear": 2019,
              "id": 244219,
              "numberFirst6": "414720",
              "numberLast4": "4308",
              "status": "ACTIVE",
              "type": "VISA"
            },
            "debit": false,
            "emvData": {
              "emvTags": {
                "0x50": "5649534120435245444954",
                "0x5F20": "4C554B2F4C415752454E434520",
                "0x5F24": "190831",
                "0x5F2A": "0840",
                "0x5F34": "02",
                "0x82": "3C00",
                "0x84": "A0000000031010",
                "0x95": "0080008000",
                "0x9A": "170202",
                "0x9B": "E800",
                "0x9C": "00",
                "0x9F02": "000000000625",
                "0x9F03": "000000000000",
                "0x9F06": "A0000000031010",
                "0x9F10": "06010A03A0A802",
                "0x9F12": "43484153452056495341",
                "0x9F1A": "0840",
                "0x9F26": "376393F3F6B156AA",
                "0x9F27": "80",
                "0x9F33": "E0F0C8",
                "0x9F34": "5E0000",
                "0x9F35": "21",
                "0x9F36": "0036",
                "0x9F37": "94F3A4C5"
              }
            },
            "entryDetails": {
              "customerPresenceStatus": "PRESENT",
              "entryMode": "INTEGRATED_CIRCUIT_CARD"
            },
            "type": "CREDIT_DEBIT"
          },
          "id": "624fbc0f-794c-4866-a211-0f5be53b8345",
          "links": [
            {
              "href": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c",
              "method": "GET",
              "rel": "CAPTURE"
            }
          ],
          "partiallyApproved": false,
          "pinCaptured": false,
          "processorResponse": {
            "acquirer": "CHASE_PAYMENTECH",
            "approvalCode": "534216",
            "approvedAmount": 625,
            "batchId": "1",
            "emvTags": {
              "0x89": "454139324645",
              "0x8A": "3030"
            },
            "processor": "MOCK",
            "retrievalRefNum": "624fbc0f-794c-4866-a211-0f5be53b8345",
            "status": "Successful",
            "statusCode": "1",
            "statusMessage": "Successful",
            "transactionId": "624fbc0f-794c-4866-a211-0f5be53b8345"
          },
          "references": [
            {
              "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
              "type": "POYNT_ORDER"
            }
          ],
          "settled": false,
          "signatureCaptured": true,
          "signatureRequired": false,
          "status": "CAPTURED",
          "updatedAt": "2017-02-03T02:34:14Z",
          "voided": false
        },
        {
          "action": "CAPTURE",
          "actionVoid": false,
          "adjusted": false,
          "amounts": {
            "cashbackAmount": 0,
            "currency": "USD",
            "customerOptedNoTip": false,
            "orderAmount": 625,
            "tipAmount": 68,
            "transactionAmount": 693
          },
          "amountsAdjusted": false,
          "authOnly": false,
          "context": {
            "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
            "businessType": "TEST_MERCHANT",
            "employeeUserId": 5247870,
            "mcc": "5812",
            "source": "INSTORE",
            "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
            "storeId": "c394627f-4f68-47fb-90a5-684ea801a352"
          },
          "createdAt": "2017-02-03T02:34:14Z",
          "customerUserId": 5249839,
          "fundingSource": {
            "card": {
              "cardHolderFirstName": "LAWRENCE",
              "cardHolderFullName": "LUK/LAWRENCE",
              "cardHolderLastName": "LUK",
              "expirationDate": 31,
              "expirationMonth": 8,
              "expirationYear": 2019,
              "id": 244219,
              "numberFirst6": "414720",
              "numberLast4": "4308",
              "status": "ACTIVE",
              "type": "VISA"
            },
            "debit": false,
            "entryDetails": {
              "customerPresenceStatus": "PRESENT",
              "entryMode": "INTEGRATED_CIRCUIT_CARD"
            },
            "type": "CREDIT_DEBIT"
          },
          "id": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c",
          "links": [
            {
              "href": "624fbc0f-794c-4866-a211-0f5be53b8345",
              "method": "GET",
              "rel": "AUTHORIZE"
            }
          ],
          "parentId": "624fbc0f-794c-4866-a211-0f5be53b8345",
          "partiallyApproved": false,
          "pinCaptured": false,
          "processorResponse": {
            "acquirer": "CHASE_PAYMENTECH",
            "approvalCode": "283042",
            "batchId": "1",
            "processor": "MOCK",
            "status": "Successful",
            "statusCode": "1",
            "statusMessage": "Successful",
            "transactionId": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c"
          },
          "references": [
            {
              "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
              "type": "POYNT_ORDER"
            }
          ],
          "settled": false,
          "signatureCaptured": true,
          "signatureRequired": false,
          "status": "CAPTURED",
          "updatedAt": "2017-02-03T02:34:14Z",
          "voided": false
        }
      ],
      "updatedAt": "2017-02-03T01:40:21Z"
    }
  ]
}

Definition

@classmethod
def get_orders(cls, business_id, start_at=None, start_offset=None,
               end_at=None, limit=None, card_number_first_6=None,
               card_number_last_4=None, card_expiration_month=None,
               card_expiration_year=None, card_holder_first_name=None,
               card_holder_last_name=None, store_id=None):
"""
Get all orders at a business by various criteria.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get orders created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get orders created before this time in seconds
limit (int, optional): how many orders to return (for pagination)
card_number_first_6 (str, optional): return orders with card numbers starting with this
card_number_last_4 (str, optional): return orders with card numbers ending with this
card_expiration_month (str, optional): return orders with this card expiration month
card_expiration_year (str, optional): return orders with this card expiration year
card_holder_first_name (str, optional): return orders with first name matching this
card_holder_last_name (str, optional): return orders with last name matching this
store_id (str, optional): return orders from this store
"""

Sample Request

doc, status_code = poynt.Order.get_orders(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'count': 20, u'orders': [{u'transactions': [{u'status': u'CAPTURED', u'adjusted': True, u'links': [{u'href': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'method': u'GET', u'rel': u'CAPTURE'}], u'voided': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'INTEGRATED_CIRCUIT_CARD'}, u'emvData': {u'emvTags': {u'0x5F34': u'02', u'0x9C': u'00', u'0x9B': u'E800', u'0x9F27': u'80', u'0x9F26': u'376393F3F6B156AA', u'0x9F03': u'000000000000', u'0x9F02': u'000000000625', u'0x9F06': u'A0000000031010', u'0x9F37': u'94F3A4C5', u'0x9A': u'170202', u'0x9F33': u'E0F0C8', u'0x84': u'A0000000031010', u'0x5F2A': u'0840', u'0x82': u'3C00', u'0x9F1A': u'0840', u'0x5F24': u'190831', u'0x9F36': u'0036', u'0x5F20': u'4C554B2F4C415752454E434520', u'0x9F34': u'5E0000', u'0x9F35': u'21', u'0x9F10': u'06010A03A0A802', u'0x9F12': u'43484153452056495341', u'0x50': u'5649534120435245444954', u'0x95': u'0080008000'}}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'LUK/LAWRENCE', u'cardHolderLastName': u'LUK', u'cardHolderFirstName': u'LAWRENCE', u'expirationYear': 2019, u'expirationDate': 31, u'numberLast4': u'4308', u'type': u'VISA', u'id': 244219, u'numberFirst6': u'414720'}, u'debit': False}, u'references': [{u'type': u'POYNT_ORDER', u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de'}], u'updatedAt': u'2017-02-03T02:34:14Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'534216', u'retrievalRefNum': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'batchId': u'1', u'emvTags': {u'0x8A': u'3030', u'0x89': u'454139324645'}, u'statusMessage': u'Successful', u'approvedAmount': 625, u'transactionId': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'processor': u'MOCK', u'acquirer': u'CHASE_PAYMENTECH', u'statusCode': u'1'}, u'id': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'createdAt': u'2017-02-03T01:40:09Z', u'amounts': {u'tipAmount': 68, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 625, u'transactionAmount': 693}, u'customerUserId': 5249839, u'partiallyApproved': False, u'authOnly': False, u'amountsAdjusted': True, u'pinCaptured': False, u'signatureRequired': False, u'actionVoid': False, u'signatureCaptured': True, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'sourceApp': u'co.poynt.services', u'source': u'INSTORE', u'employeeUserId': 5247870, u'transmissionAtLocal': u'2017-02-03T01:40:08Z', u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'action': u'AUTHORIZE', u'settled': False}, {u'status': u'CAPTURED', u'adjusted': False, u'links': [{u'href': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'method': u'GET', u'rel': u'AUTHORIZE'}], u'voided': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'INTEGRATED_CIRCUIT_CARD'}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'LUK/LAWRENCE', u'cardHolderLastName': u'LUK', u'cardHolderFirstName': u'LAWRENCE', u'expirationYear': 2019, u'expirationDate': 31, u'numberLast4': u'4308', u'type': u'VISA', u'id': 244219, u'numberFirst6': u'414720'}, u'debit': False}, u'references': [{u'type': u'POYNT_ORDER', u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de'}], u'updatedAt': u'2017-02-03T02:34:14Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'283042', u'batchId': u'1', u'acquirer': u'CHASE_PAYMENTECH', u'transactionId': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'processor': u'MOCK', u'statusMessage': u'Successful', u'statusCode': u'1'}, u'id': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'createdAt': u'2017-02-03T02:34:14Z', u'amounts': {u'tipAmount': 68, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 625, u'transactionAmount': 693}, u'customerUserId': 5249839, u'partiallyApproved': False, u'parentId': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'authOnly': False, u'amountsAdjusted': False, u'pinCaptured': False, u'signatureRequired': False, u'actionVoid': False, u'signatureCaptured': True, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'source': u'INSTORE', u'employeeUserId': 5247870, u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'action': u'CAPTURE', u'settled': False}], u'amounts': {u'netTotal': 625, u'capturedTotals': {u'currency': u'USD', u'tipAmount': 68, u'transactionAmount': 693, u'cashbackAmount': 0, u'orderAmount': 625}, u'currency': u'USD', u'discountTotal': 0, u'feeTotal': 0, u'subTotal': 625, u'taxTotal': 0}, u'items': [{u'status': u'FULFILLED', u'sku': u'water', u'unitOfMeasure': u'EACH', u'fee': 0, u'name': u'water', u'tax': 0, u'discount': 0, u'updatedAt': u'2017-02-03T01:40:21Z', u'taxExempted': False, u'productId': u'f9faac3a-be56-4bff-b60b-84987cf021cb', u'unitPrice': 125, u'id': 1, u'createdAt': u'2017-02-03T01:40:21Z', u'quantity': 5.0}], u'customerUserId': 5249839, u'orderNumber': u'4', u'statuses': {u'status': u'OPENED', u'transactionStatusSummary': u'COMPLETED', u'fulfillmentStatus': u'FULFILLED'}, u'context': {u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'source': u'INSTORE', u'employeeUserId': 5247870, u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652', u'transactionInstruction': u'NONE'}, u'updatedAt': u'2017-02-03T01:40:21Z', u'taxExempted': False, u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de', u'createdAt': u'2017-02-03T01:40:21Z'}], u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/orders?startAt=2017-02-03T02%3A34%3A14Z&endAt=2017-08-28T06%3A46%3A08Z&limit=1', u'method': u'GET', u'rel': u'next'}]}

Get all orders

Get all orders that match the specified filters. If no filter is specified it will fetch all orders for the business since it started. We currently return 10 records at a time with a HATEOS link to the next 10. The following optional filters are supported:

  1. startTimeSec: the time from which to start fetching transactions,
  2. limit: the number of order to fetch,
  3. cardNumberFirst6: limit results to orders with transactions done by cards starting with these 6 numbers,
  4. cardNumberLast4: limit results to orders with transactions done by cards ending with these 4 numbers,
  5. cardExpirationMonth: limit results to orders with transactions done by cards expiring in this month,
  6. cardExpirationYear: limit results to orders with transactions done by cards expiring in this year,
  7. cardHolderFirstName: limit results to orders with transactions done by cards with this card holder first name,
  8. cardHolderLastName: limit results to orders with transactions done by cards with this card holder last name,
  9. storeId: only fetch transactions for this store.
  10. orderStatus: only fetch orders with the status.
  11. includeStaysAll: inlcude stay orders.
  12. includeOrderHistories: include order histories for orders.
  13. includeOrderShipments: include orderShipments for orders.
  14. customerUserId: filter orders placed by the customer.

Arguments

businessId path
string (required)
If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
timeType query
string (optional)
limit query
integer (optional)
cardNumberFirst6 query
string (optional)
cardNumberLast4 query
string (optional)
cardExpirationMonth query
integer (optional)
cardExpirationYear query
integer (optional)
cardHolderFirstName query
string (optional)
cardHolderLastName query
string (optional)
storeId query
string (optional)
orderNumber query
string (optional)
orderStatus query
string (optional)
includeStaysAll query
boolean (optional)
includeOrderHistories query
boolean (optional)
includeOrderShipments query
boolean (optional)
customerUserId query
integer (optional)

Response

Returns a OrderList.


Definition

GET /businesses/{businessId}/orders/{orderId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getOrders = function getOrders(options, next) { ... }
/**
 * Get all orders at a business.
 * @param {String} options.businessId
 * @param {String} options.startAt (optional) - the time from which to start fetching orders
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional) - the time at which to stop fetching orders
 * @param {Integer} options.limit (optional) - the number of orders to fetch
 * @param {String} options.cardNumberFirst6 (optional) - limit results to orders with transactions done by cards starting with these 6 numbers
 * @param {String} options.cardNumberLast4 (optional) - limit results to orders with transactions done by cards ending with these 4 numbers
 * @param {Integer} options.cardExpirationMonth (optional) - limit results to orders with transactions done by cards expiring in this month
 * @param {Integer} options.cardExpirationYear (optional) - limit results to orders with transactions done by cards expiring in this year
 * @param {String} options.cardHolderFirstName (optional) - limit results to orders with transactions done by cards with this card holder first name
 * @param {String} options.cardHolderLastName (optional) - limit results to orders with transactions done by cards with this card holder last name
 * @param {String} options.storeId (optional) - only fetch orders for this store
 * @param {String} options.includeStaysAll (optional)
 * @return {OrderList} orders
 */

Sample Request

poynt.getOrder({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  orderId    : '01a0c6f9-015a-1000-e3ce-bbbd758e32de'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
})

Sample Response

{
  "amounts": {
    "capturedTotals": {
      "cashbackAmount": 0,
      "currency": "USD",
      "orderAmount": 625,
      "tipAmount": 68,
      "transactionAmount": 693
    },
    "currency": "USD",
    "discountTotal": 0,
    "feeTotal": 0,
    "netTotal": 625,
    "subTotal": 625,
    "taxTotal": 0
  },
  "context": {
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
    "employeeUserId": 5247870,
    "source": "INSTORE",
    "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
    "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
    "transactionInstruction": "NONE"
  },
  "createdAt": "2017-02-03T01:40:21Z",
  "customerUserId": 5249839,
  "discounts": [],
  "fees": [],
  "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
  "items": [
    {
      "createdAt": "2017-02-03T01:40:21Z",
      "discount": 0,
      "discounts": [],
      "fee": 0,
      "fees": [],
      "id": 1,
      "name": "water",
      "productId": "f9faac3a-be56-4bff-b60b-84987cf021cb",
      "quantity": 5,
      "selectedVariants": [],
      "sku": "water",
      "status": "FULFILLED",
      "tax": 0,
      "taxExempted": false,
      "taxes": [],
      "unitOfMeasure": "EACH",
      "unitPrice": 125,
      "updatedAt": "2017-02-03T01:40:21Z"
    }
  ],
  "orderNumber": "4",
  "statuses": {
    "fulfillmentStatus": "FULFILLED",
    "status": "OPENED",
    "transactionStatusSummary": "COMPLETED"
  },
  "taxExempted": false,
  "transactions": [
    {
      "action": "AUTHORIZE",
      "actionVoid": false,
      "adjusted": true,
      "amounts": {
        "cashbackAmount": 0,
        "currency": "USD",
        "customerOptedNoTip": false,
        "orderAmount": 625,
        "tipAmount": 68,
        "transactionAmount": 693
      },
      "amountsAdjusted": true,
      "authOnly": false,
      "context": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "businessType": "TEST_MERCHANT",
        "employeeUserId": 5247870,
        "mcc": "5812",
        "source": "INSTORE",
        "sourceApp": "co.poynt.services",
        "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
        "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
        "transmissionAtLocal": "2017-02-03T01:40:08Z"
      },
      "createdAt": "2017-02-03T01:40:09Z",
      "customerUserId": 5249839,
      "fundingSource": {
        "card": {
          "cardHolderFirstName": "LAWRENCE",
          "cardHolderFullName": "LUK/LAWRENCE",
          "cardHolderLastName": "LUK",
          "expirationDate": 31,
          "expirationMonth": 8,
          "expirationYear": 2019,
          "id": 244219,
          "numberFirst6": "414720",
          "numberLast4": "4308",
          "status": "ACTIVE",
          "type": "VISA"
        },
        "debit": false,
        "emvData": {
          "emvTags": {
            "0x50": "5649534120435245444954",
            "0x5F20": "4C554B2F4C415752454E434520",
            "0x5F24": "190831",
            "0x5F2A": "0840",
            "0x5F34": "02",
            "0x82": "3C00",
            "0x84": "A0000000031010",
            "0x95": "0080008000",
            "0x9A": "170202",
            "0x9B": "E800",
            "0x9C": "00",
            "0x9F02": "000000000625",
            "0x9F03": "000000000000",
            "0x9F06": "A0000000031010",
            "0x9F10": "06010A03A0A802",
            "0x9F12": "43484153452056495341",
            "0x9F1A": "0840",
            "0x9F26": "376393F3F6B156AA",
            "0x9F27": "80",
            "0x9F33": "E0F0C8",
            "0x9F34": "5E0000",
            "0x9F35": "21",
            "0x9F36": "0036",
            "0x9F37": "94F3A4C5"
          }
        },
        "entryDetails": {
          "customerPresenceStatus": "PRESENT",
          "entryMode": "INTEGRATED_CIRCUIT_CARD"
        },
        "type": "CREDIT_DEBIT"
      },
      "id": "624fbc0f-794c-4866-a211-0f5be53b8345",
      "links": [
        {
          "href": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c",
          "method": "GET",
          "rel": "CAPTURE"
        }
      ],
      "partiallyApproved": false,
      "pinCaptured": false,
      "processorResponse": {
        "acquirer": "CHASE_PAYMENTECH",
        "approvalCode": "534216",
        "approvedAmount": 625,
        "batchId": "1",
        "emvTags": {
          "0x89": "454139324645",
          "0x8A": "3030"
        },
        "processor": "MOCK",
        "retrievalRefNum": "624fbc0f-794c-4866-a211-0f5be53b8345",
        "status": "Successful",
        "statusCode": "1",
        "statusMessage": "Successful",
        "transactionId": "624fbc0f-794c-4866-a211-0f5be53b8345"
      },
      "references": [
        {
          "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
          "type": "POYNT_ORDER"
        }
      ],
      "settled": false,
      "signatureCaptured": true,
      "signatureRequired": false,
      "status": "CAPTURED",
      "updatedAt": "2017-02-03T02:34:14Z",
      "voided": false
    },
    {
      "action": "CAPTURE",
      "actionVoid": false,
      "adjusted": false,
      "amounts": {
        "cashbackAmount": 0,
        "currency": "USD",
        "customerOptedNoTip": false,
        "orderAmount": 625,
        "tipAmount": 68,
        "transactionAmount": 693
      },
      "amountsAdjusted": false,
      "authOnly": false,
      "context": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "businessType": "TEST_MERCHANT",
        "employeeUserId": 5247870,
        "mcc": "5812",
        "source": "INSTORE",
        "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
        "storeId": "c394627f-4f68-47fb-90a5-684ea801a352"
      },
      "createdAt": "2017-02-03T02:34:14Z",
      "customerUserId": 5249839,
      "fundingSource": {
        "card": {
          "cardHolderFirstName": "LAWRENCE",
          "cardHolderFullName": "LUK/LAWRENCE",
          "cardHolderLastName": "LUK",
          "expirationDate": 31,
          "expirationMonth": 8,
          "expirationYear": 2019,
          "id": 244219,
          "numberFirst6": "414720",
          "numberLast4": "4308",
          "status": "ACTIVE",
          "type": "VISA"
        },
        "debit": false,
        "entryDetails": {
          "customerPresenceStatus": "PRESENT",
          "entryMode": "INTEGRATED_CIRCUIT_CARD"
        },
        "type": "CREDIT_DEBIT"
      },
      "id": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c",
      "links": [
        {
          "href": "624fbc0f-794c-4866-a211-0f5be53b8345",
          "method": "GET",
          "rel": "AUTHORIZE"
        }
      ],
      "parentId": "624fbc0f-794c-4866-a211-0f5be53b8345",
      "partiallyApproved": false,
      "pinCaptured": false,
      "processorResponse": {
        "acquirer": "CHASE_PAYMENTECH",
        "approvalCode": "283042",
        "batchId": "1",
        "processor": "MOCK",
        "status": "Successful",
        "statusCode": "1",
        "statusMessage": "Successful",
        "transactionId": "1b622bd1-c0db-4271-9fe1-4ed9fbf6610c"
      },
      "references": [
        {
          "id": "01a0c6f9-015a-1000-e3ce-bbbd758e32de",
          "type": "POYNT_ORDER"
        }
      ],
      "settled": false,
      "signatureCaptured": true,
      "signatureRequired": false,
      "status": "CAPTURED",
      "updatedAt": "2017-02-03T02:34:14Z",
      "voided": false
    }
  ],
  "updatedAt": "2017-02-03T01:40:21Z"
}

Definition

@classmethod
def get_orders(cls, business_id, start_at=None, start_offset=None,
               end_at=None, limit=None, card_number_first_6=None,
               card_number_last_4=None, card_expiration_month=None,
               card_expiration_year=None, card_holder_first_name=None,
               card_holder_last_name=None, store_id=None):
"""
Get all orders at a business by various criteria.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get orders created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get orders created before this time in seconds
limit (int, optional): how many orders to return (for pagination)
card_number_first_6 (str, optional): return orders with card numbers starting with this
card_number_last_4 (str, optional): return orders with card numbers ending with this
card_expiration_month (str, optional): return orders with this card expiration month
card_expiration_year (str, optional): return orders with this card expiration year
card_holder_first_name (str, optional): return orders with first name matching this
card_holder_last_name (str, optional): return orders with last name matching this
store_id (str, optional): return orders from this store
"""

Sample Request

doc, status_code = poynt.Order.get_order(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '01a0c6f9-015a-1000-e3ce-bbbd758e32de'
)

if status_code < 300:
    print(doc)

Sample Response

{u'transactions': [{u'status': u'CAPTURED', u'adjusted': True, u'links': [{u'href': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'method': u'GET', u'rel': u'CAPTURE'}], u'voided': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'INTEGRATED_CIRCUIT_CARD'}, u'emvData': {u'emvTags': {u'0x5F34': u'02', u'0x9C': u'00', u'0x9B': u'E800', u'0x9F27': u'80', u'0x9F26': u'376393F3F6B156AA', u'0x9F03': u'000000000000', u'0x9F02': u'000000000625', u'0x9F06': u'A0000000031010', u'0x9F37': u'94F3A4C5', u'0x9A': u'170202', u'0x9F33': u'E0F0C8', u'0x84': u'A0000000031010', u'0x5F2A': u'0840', u'0x82': u'3C00', u'0x9F1A': u'0840', u'0x5F24': u'190831', u'0x9F36': u'0036', u'0x5F20': u'4C554B2F4C415752454E434520', u'0x9F34': u'5E0000', u'0x9F35': u'21', u'0x9F10': u'06010A03A0A802', u'0x9F12': u'43484153452056495341', u'0x50': u'5649534120435245444954', u'0x95': u'0080008000'}}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'LUK/LAWRENCE', u'cardHolderLastName': u'LUK', u'cardHolderFirstName': u'LAWRENCE', u'expirationYear': 2019, u'expirationDate': 31, u'numberLast4': u'4308', u'type': u'VISA', u'id': 244219, u'numberFirst6': u'414720'}, u'debit': False}, u'references': [{u'type': u'POYNT_ORDER', u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de'}], u'updatedAt': u'2017-02-03T02:34:14Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'534216', u'retrievalRefNum': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'batchId': u'1', u'emvTags': {u'0x8A': u'3030', u'0x89': u'454139324645'}, u'statusMessage': u'Successful', u'approvedAmount': 625, u'transactionId': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'processor': u'MOCK', u'acquirer': u'CHASE_PAYMENTECH', u'statusCode': u'1'}, u'id': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'createdAt': u'2017-02-03T01:40:09Z', u'amounts': {u'tipAmount': 68, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 625, u'transactionAmount': 693}, u'customerUserId': 5249839, u'partiallyApproved': False, u'authOnly': False, u'amountsAdjusted': True, u'pinCaptured': False, u'signatureRequired': False, u'actionVoid': False, u'signatureCaptured': True, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'sourceApp': u'co.poynt.services', u'source': u'INSTORE', u'employeeUserId': 5247870, u'transmissionAtLocal': u'2017-02-03T01:40:08Z', u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'action': u'AUTHORIZE', u'settled': False}, {u'status': u'CAPTURED', u'adjusted': False, u'links': [{u'href': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'method': u'GET', u'rel': u'AUTHORIZE'}], u'voided': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'INTEGRATED_CIRCUIT_CARD'}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'LUK/LAWRENCE', u'cardHolderLastName': u'LUK', u'cardHolderFirstName': u'LAWRENCE', u'expirationYear': 2019, u'expirationDate': 31, u'numberLast4': u'4308', u'type': u'VISA', u'id': 244219, u'numberFirst6': u'414720'}, u'debit': False}, u'references': [{u'type': u'POYNT_ORDER', u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de'}], u'updatedAt': u'2017-02-03T02:34:14Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'283042', u'batchId': u'1', u'acquirer': u'CHASE_PAYMENTECH', u'transactionId': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'processor': u'MOCK', u'statusMessage': u'Successful', u'statusCode': u'1'}, u'id': u'1b622bd1-c0db-4271-9fe1-4ed9fbf6610c', u'createdAt': u'2017-02-03T02:34:14Z', u'amounts': {u'tipAmount': 68, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 625, u'transactionAmount': 693}, u'customerUserId': 5249839, u'partiallyApproved': False, u'parentId': u'624fbc0f-794c-4866-a211-0f5be53b8345', u'authOnly': False, u'amountsAdjusted': False, u'pinCaptured': False, u'signatureRequired': False, u'actionVoid': False, u'signatureCaptured': True, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'source': u'INSTORE', u'employeeUserId': 5247870, u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'action': u'CAPTURE', u'settled': False}], u'amounts': {u'netTotal': 625, u'capturedTotals': {u'currency': u'USD', u'tipAmount': 68, u'transactionAmount': 693, u'cashbackAmount': 0, u'orderAmount': 625}, u'currency': u'USD', u'discountTotal': 0, u'feeTotal': 0, u'subTotal': 625, u'taxTotal': 0}, u'items': [{u'status': u'FULFILLED', u'sku': u'water', u'unitOfMeasure': u'EACH', u'fee': 0, u'name': u'water', u'discount': 0, u'selectedVariants': [], u'fees': [], u'tax': 0, u'taxes': [], u'discounts': [], u'updatedAt': u'2017-02-03T01:40:21Z', u'taxExempted': False, u'productId': u'f9faac3a-be56-4bff-b60b-84987cf021cb', u'unitPrice': 125, u'id': 1, u'createdAt': u'2017-02-03T01:40:21Z', u'quantity': 5.0}], u'updatedAt': u'2017-02-03T01:40:21Z', u'customerUserId': 5249839, u'orderNumber': u'4', u'discounts': [], u'statuses': {u'status': u'OPENED', u'transactionStatusSummary': u'COMPLETED', u'fulfillmentStatus': u'FULFILLED'}, u'context': {u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'source': u'INSTORE', u'employeeUserId': 5247870, u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652', u'transactionInstruction': u'NONE'}, u'fees': [], u'taxExempted': False, u'id': u'01a0c6f9-015a-1000-e3ce-bbbd758e32de', u'createdAt': u'2017-02-03T01:40:21Z'}

Get an order

Get an order (along with HATEOS links to all immediately related orders).

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
orderId path
string (required)

Response

Returns a Order.


Definition

GET /businesses/{businessId}/orders/{orderId}/shipments

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get order shipments

Get all order shipments for a given order.

Arguments

businessId path
string (required)
orderId path
string (required)

Response

Returns array of [OrderShipment].


Definition

GET /businesses/{businessId}/orders/{orderId}/histories

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get order history events

Get all order history events for a given order.

Arguments

businessId path
string (required)
orderId path
string (required)

Response

Returns array of [OrderHistory].


Definition

PUT /businesses/{businessId}/orders/{orderId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Record order

Record an order that has already happened. A full order object must be populated as this operation will simply record what is passed to it.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
orderId path
string (required)
order body
Order (optional)

Response

Returns a Order.


Definition

PATCH /businesses/{businessId}/orders/{orderId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Update order

Update an order. This takes a JsonPatch object as request. We allow updates to order level amounts and replace on /items and /discounts.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
orderId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Order.


Transactions

Transactions resource represents a financial transaction. It has operations to manage the entire lifecycle of a transaction initiated through MSR, manual key-in, NFC or EMV. It provides operations to:

  1. save a transaction at the Poynt server for later processing,
  2. record a transaction that has already happened – maybe offline or through some other path with the acquirer,
  3. initiate interaction with the acquirer to move funds (for a previously saved transaction or a brand new transaction),
  4. capture, void or update a previously authorized transaction,
  5. refund a previously completed transaction,
  6. record EMV tags associated with an authorized transaction or
  7. get details about all transactions meeting a certain filter criteria.

Definition

GET /businesses/{businessId}/transactions

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getTransactions = function getTransactions(options, next) { ... }
/**
 * Get all transactions that match the specified filters.
 * If no filter is specified it will fetch all transactions for the business
 * since it started.
 * @param {String} options.businessId
 * @param {String} options.startAt (optional) - the time from which to start fetching transactions
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional) - the time at which to stop fetching transactions
 * @param {Integer} options.limit (optional) - the number of transactions to fetch
 * @param {String} options.storeId (optional) - only fetch transactions for this store
 * @param {String} options.deviceId (optional) - only fetch transactions for this device
 * @param {String} options.searchKey (optional) - instead of specifying which exact field to look at, the client can simply pass this search key and the server will look at various different fields,
 * @param {String} options.cardNumberFirst6 (optional) - limit results to transactions done by cards starting with these 6 numbers
 * @param {String} options.cardNumberLast4 (optional) - limit results to transactions done by cards ending with these 4 numbers
 * @param {Integer} options.cardExpirationMonth (optional) - limit results to transactions done by cards expiring in this month
 * @param {Integer} options.cardExpirationYear (optional) - limit results to transactions done by cards expiring in this year
 * @param {String} options.cardHolderFirstName (optional) - limit results to transactions done by cards with this card holder first name
 * @param {String} options.cardHolderLastName (optional) - limit results to transactions done by cards with this card holder last name
 * @param {String} options.action (optional) - only fetch transactions with this action
 * @param {String} options.status (optional) - only fetch transactions with this status
 * @param {String} options.transactionIds (optional) - only fetch transactions matching these ids (comma separated)
 * @param {Boolean} options.authOnly (optional) - only fetch auth only transactions
 * @param {Boolean} options.unsettledOnly (optional) - only fetch unsettled transactions
 * @param {Boolean} options.creditDebitOnly (optional) - only fetch credit/debit transactions
 * @return {TransactionList} transactions
 */

Sample Request

poynt.getTransactions({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
})

Sample Response

{
  "count": 256,
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/transactions?startAt=2017-01-04T23%3A10%3A25Z&endAt=2017-08-28T06%3A56%3A17Z&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ],
  "transactions": [
    {
      "action": "AUTHORIZE",
      "actionVoid": false,
      "adjusted": false,
      "amounts": {
        "cashbackAmount": 0,
        "currency": "USD",
        "customerOptedNoTip": false,
        "orderAmount": 800,
        "tipAmount": 0,
        "transactionAmount": 800
      },
      "amountsAdjusted": false,
      "authOnly": false,
      "context": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "businessType": "TEST_MERCHANT",
        "employeeUserId": 5247838,
        "mcc": "5812",
        "source": "INSTORE",
        "sourceApp": "co.poynt.services",
        "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
        "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
        "transmissionAtLocal": "2017-01-04T22:20:40Z"
      },
      "createdAt": "2017-01-04T22:20:40Z",
      "customerUserId": 5247839,
      "fundingSource": {
        "card": {
          "cardHolderFirstName": "",
          "cardHolderFullName": "/",
          "cardHolderLastName": "",
          "expirationDate": 31,
          "expirationMonth": 8,
          "expirationYear": 2022,
          "id": 243043,
          "numberFirst6": "405413",
          "numberLast4": "0833",
          "status": "ACTIVE",
          "type": "VISA"
        },
        "debit": false,
        "emvData": {
          "emvTags": {
            "0x5F20": "202F",
            "0x5F24": "220831",
            "0x9C": "00",
            "0x9F02": "000000000800",
            "0x9F06": "A0000000031010",
            "0x9F37": "7619D4A6"
          }
        },
        "entryDetails": {
          "customerPresenceStatus": "PRESENT",
          "entryMode": "CONTACTLESS_MAGSTRIPE"
        },
        "type": "CREDIT_DEBIT"
      },
      "id": "9ee28946-cab1-48af-b30b-d111716128a2",
      "partiallyApproved": false,
      "pinCaptured": false,
      "processorResponse": {
        "acquirer": "CHASE_PAYMENTECH",
        "approvalCode": "667149",
        "approvedAmount": 800,
        "batchId": "1",
        "processor": "MOCK",
        "retrievalRefNum": "9ee28946-cab1-48af-b30b-d111716128a2",
        "status": "Successful",
        "statusCode": "1",
        "statusMessage": "Successful",
        "transactionId": "9ee28946-cab1-48af-b30b-d111716128a2"
      },
      "references": [
        {
          "customType": "referenceId",
          "id": "6b91d9a0-0159-1000-6f82-44ed3d4b4a5a",
          "type": "CUSTOM"
        }
      ],
      "settled": false,
      "signatureCaptured": true,
      "signatureRequired": false,
      "status": "AUTHORIZED",
      "updatedAt": "2017-01-04T22:20:40Z",
      "voided": false
    }
  ]
}

Definition


@classmethod
def get_transactions(cls, business_id, start_at=None, start_offset=None,
                     end_at=None, limit=None, card_number_first_6=None,
                     card_number_last_4=None, card_expiration_month=None,
                     card_expiration_year=None, card_holder_first_name=None,
                     card_holder_last_name=None, store_id=None, device_id=None,
                     search_key=None, action=None, status=None, transaction_ids=None,
                     auth_only=None, unsettled_only=None, credit_debit_only=None):
"""
Get all transactions at a business by various criteria.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get txns created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get txns created before this time in seconds
limit (int, optional): how many txns to return (for pagination)
card_number_first_6 (str, optional): return txns with card numbers starting with this
card_number_last_4 (str, optional): return txns with card numbers ending with this
card_expiration_month (str, optional): return txns with this card expiration month
card_expiration_year (str, optional): return txns with this card expiration year
card_holder_first_name (str, optional): return txns with first name matching this
card_holder_last_name (str, optional): return txns with last name matching this
store_id (str, optional): return txns from this store
device_id (str, optional): return txns from this device
search_key (str, optional): instead of specifying which exact field to look at, the
                            client can simply pass this search key and the server will
                            look at various different fields,
action (str, optional): only fetch txns with this action
status (str, optional): only fetch txns with this status
transaction_ids (str, optional): only fetch txns matching these ids (comma separated)
auth_only (bool, optional): only fetch auth only txns
unsettled_only (bool, optional): only fetch unsettled txns
credit_debit_only (bool, optional): only fetch credit/debit txns
"""

Sample Request

doc, status_code = poynt.Transaction.get_transactions(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'count': 256, u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/transactions?startAt=2017-01-04T23%3A10%3A25Z&endAt=2017-08-28T06%3A57%3A16Z&limit=1', u'method': u'GET', u'rel': u'next'}], u'transactions': [{u'authOnly': False, u'status': u'AUTHORIZED', u'adjusted': False, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'sourceApp': u'co.poynt.services', u'source': u'INSTORE', u'employeeUserId': 5247838, u'transmissionAtLocal': u'2017-01-04T22:20:40Z', u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'pinCaptured': False, u'id': u'9ee28946-cab1-48af-b30b-d111716128a2', u'action': u'AUTHORIZE', u'customerUserId': 5247839, u'amountsAdjusted': False, u'partiallyApproved': False, u'voided': False, u'signatureRequired': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'CONTACTLESS_MAGSTRIPE'}, u'emvData': {u'emvTags': {u'0x5F24': u'220831', u'0x9C': u'00', u'0x5F20': u'202F', u'0x9F02': u'000000000800', u'0x9F06': u'A0000000031010', u'0x9F37': u'7619D4A6'}}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'/', u'cardHolderLastName': u'', u'cardHolderFirstName': u'', u'expirationYear': 2022, u'expirationDate': 31, u'numberLast4': u'0833', u'type': u'VISA', u'id': 243043, u'numberFirst6': u'405413'}, u'debit': False}, u'amounts': {u'tipAmount': 0, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 800, u'transactionAmount': 800}, u'references': [{u'customType': u'referenceId', u'type': u'CUSTOM', u'id': u'6b91d9a0-0159-1000-6f82-44ed3d4b4a5a'}], u'actionVoid': False, u'updatedAt': u'2017-01-04T22:20:40Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'667149', u'retrievalRefNum': u'9ee28946-cab1-48af-b30b-d111716128a2', u'batchId': u'1', u'acquirer': u'CHASE_PAYMENTECH', u'approvedAmount': 800, u'transactionId': u'9ee28946-cab1-48af-b30b-d111716128a2', u'processor': u'MOCK', u'statusMessage': u'Successful', u'statusCode': u'1'}, u'settled': False, u'signatureCaptured': True, u'createdAt': u'2017-01-04T22:20:40Z'}]}

Get all transactions

Get all transactions that match the specified filters. If no filter is specified it will fetch all transactions for the business since it started. We currently return 10 records at a time with a HATEOS link to the next 10. The following optional filters are supported:

  1. If-Modified-Since: will only return transaction since If-Modified-Since,
  2. startAt: the time in seconds from which to start fetching transactions,
  3. startOffset: for all transactions at startAt the offset from where to start,
  4. endAt: the time in seconds at which to end,
  5. limit: the number of transactions to fetch in one go,
  6. storeId: only fetch transactions for this store,
  7. deviceId: only fetch transactions for this device,
  8. searchKey: instead of specifying which exact field to look at, the client can simply pass this search key and the server will look at various different fields,
  9. cardNumberFirst6: limit results to transactions done by cards starting with these 6 numbers,
  10. cardNumberLast4: limit results to transactions done by cards ending with these 4 numbers,
  11. cardExpirationMonth: limit results to transactions done by cards expiring in this month,
  12. cardExpirationYear: limit results to transactions done by cards expiring in this year,
  13. cardHolderFirstName: limit results to transactions done by cards with this card holder first name,
  14. cardHolderLastName: limit results to transactions done by cards with this card holder last name,
  15. transactionIds: only fetch transactions matching these transactionIds,
  16. authOny: only fetch authOnly transactions,
  17. unsettledOnly: only fetch unsettled transactions. note: this will limit result to creditDebitOnly,
  18. creditDebitOnly: only fetch credit-debit transactions. note: if one of the card filters or unsettledOnly filter above are enabled, it automatically limits result to credit-debit only,

Arguments

businessId path
string (required)
If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
timeType query
string (optional)
limit query
integer (optional)
storeId query
string (optional)
deviceId query
string (optional)
tid query
string (optional)
searchKey query
string (optional)
cardNumberFirst6 query
string (optional)
cardNumberLast4 query
string (optional)
cardExpirationMonth query
integer (optional)
cardExpirationYear query
integer (optional)
cardHolderFirstName query
string (optional)
cardHolderLastName query
string (optional)
action query
string (optional)
status query
string (optional)
transactionIds query
array (optional)
authOnly query
boolean (optional)
unsettledOnly query
boolean (optional)
creditDebitOnly query
boolean (optional)

Response

Returns a TransactionList.


Definition

POST /businesses/{businessId}/transactions

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Create transaction

Create a new authorize, sale or refund transaction. If process query parameter is set to true or not provided, the processor will be called to actually process the transaction. If the process query parameter is set to false, the transaction will just be saved, but the processor will not be called for processing. This operation returns the Transaction just created. If the transaction is declined before the processor is called, the client will get an error. If the transaction is declined by the processor, the Transaction object is returned with status set to DECLINED and processor response object containing the response from the processor.

Arguments

Poynt-Request-Id header
string (required)
process query
boolean (optional)
businessId path
string (required)
transaction body
Transaction (optional)

Response

Returns a Transaction.


Definition

GET /businesses/{businessId}/transactions/archive/{queryId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get archive query status

Get query status and return resource URL for fetching archived transaction (.csv format)

Arguments

businessId path
string (required)
queryId path
string (required)

Response

Returns a QueryStatus.


Definition

POST /businesses/{businessId}/transactions/cancel

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Cancel transaction

Cancel and void are similar. They can both undo auth, sale, capture or refund transactions (if the acquirer supports it). A Cancel operation carries a CancelReason request parameter where the caller can specify the exact reason for the undo. Also note that if the Cancel operation is unable to perform an undo, and the original transaction is a sale or capture, it will proceed to issue a refund.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
original-request-id query
string (optional)
transaction-id query
string (optional)
cancelRequest body
CancelRequest (optional)

Response

Returns a Transaction.


Definition

GET /businesses/{businessId}/transactions/{transactionId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getTransaction = function getTransaction(options, next) { ... }
/**
 * Get a single transaction at a business.
 * @param {String} options.businessId
 * @param {String} options.transactionId
 * @return {Transaction} transaction
 */

Sample Request

poynt.getTransaction({
  businessId    : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  transactionId : '9ee28946-cab1-48af-b30b-d111716128a2'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "action": "AUTHORIZE",
  "actionVoid": false,
  "adjusted": false,
  "amounts": {
    "cashbackAmount": 0,
    "currency": "USD",
    "customerOptedNoTip": false,
    "orderAmount": 800,
    "tipAmount": 0,
    "transactionAmount": 800
  },
  "amountsAdjusted": false,
  "authOnly": false,
  "context": {
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
    "businessType": "TEST_MERCHANT",
    "employeeUserId": 5247838,
    "mcc": "5812",
    "source": "INSTORE",
    "sourceApp": "co.poynt.services",
    "storeDeviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
    "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
    "transmissionAtLocal": "2017-01-04T22:20:40Z"
  },
  "createdAt": "2017-01-04T22:20:40Z",
  "customerUserId": 5247839,
  "fundingSource": {
    "card": {
      "cardHolderFirstName": "",
      "cardHolderFullName": "/",
      "cardHolderLastName": "",
      "expirationDate": 31,
      "expirationMonth": 8,
      "expirationYear": 2022,
      "id": 243043,
      "numberFirst6": "405413",
      "numberLast4": "0833",
      "status": "ACTIVE",
      "type": "VISA"
    },
    "debit": false,
    "emvData": {
      "emvTags": {
        "0x5F20": "202F",
        "0x5F24": "220831",
        "0x9C": "00",
        "0x9F02": "000000000800",
        "0x9F06": "A0000000031010",
        "0x9F37": "7619D4A6"
      }
    },
    "entryDetails": {
      "customerPresenceStatus": "PRESENT",
      "entryMode": "CONTACTLESS_MAGSTRIPE"
    },
    "type": "CREDIT_DEBIT"
  },
  "id": "9ee28946-cab1-48af-b30b-d111716128a2",
  "partiallyApproved": false,
  "pinCaptured": false,
  "processorResponse": {
    "acquirer": "CHASE_PAYMENTECH",
    "approvalCode": "667149",
    "approvedAmount": 800,
    "batchId": "1",
    "processor": "MOCK",
    "retrievalRefNum": "9ee28946-cab1-48af-b30b-d111716128a2",
    "status": "Successful",
    "statusCode": "1",
    "statusMessage": "Successful",
    "transactionId": "9ee28946-cab1-48af-b30b-d111716128a2"
  },
  "references": [
    {
      "customType": "referenceId",
      "id": "6b91d9a0-0159-1000-6f82-44ed3d4b4a5a",
      "type": "CUSTOM"
    }
  ],
  "settled": false,
  "signatureCaptured": true,
  "signatureRequired": false,
  "status": "AUTHORIZED",
  "updatedAt": "2017-01-04T22:20:40Z",
  "voided": false
}

Definition

@classmethod
def get_transaction(cls, business_id, transaction_id):
"""
Get a single transaction at a business.

Arguments:
business_id (str): the business ID
transaction_id (str): the transaction ID
"""

Sample Request

doc, status_code = poynt.Transaction.get_transaction(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '9ee28946-cab1-48af-b30b-d111716128a2'
)

if status_code < 300:
    print(doc)

Sample Response

{u'authOnly': False, u'status': u'AUTHORIZED', u'adjusted': False, u'context': {u'businessType': u'TEST_MERCHANT', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'mcc': u'5812', u'sourceApp': u'co.poynt.services', u'source': u'INSTORE', u'employeeUserId': 5247838, u'transmissionAtLocal': u'2017-01-04T22:20:40Z', u'storeDeviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'}, u'pinCaptured': False, u'id': u'9ee28946-cab1-48af-b30b-d111716128a2', u'action': u'AUTHORIZE', u'customerUserId': 5247839, u'amountsAdjusted': False, u'partiallyApproved': False, u'voided': False, u'signatureRequired': False, u'fundingSource': {u'entryDetails': {u'customerPresenceStatus': u'PRESENT', u'entryMode': u'CONTACTLESS_MAGSTRIPE'}, u'emvData': {u'emvTags': {u'0x5F24': u'220831', u'0x9C': u'00', u'0x5F20': u'202F', u'0x9F02': u'000000000800', u'0x9F06': u'A0000000031010', u'0x9F37': u'7619D4A6'}}, u'type': u'CREDIT_DEBIT', u'card': {u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'/', u'cardHolderLastName': u'', u'cardHolderFirstName': u'', u'expirationYear': 2022, u'expirationDate': 31, u'numberLast4': u'0833', u'type': u'VISA', u'id': 243043, u'numberFirst6': u'405413'}, u'debit': False}, u'amounts': {u'tipAmount': 0, u'cashbackAmount': 0, u'currency': u'USD', u'customerOptedNoTip': False, u'orderAmount': 800, u'transactionAmount': 800}, u'references': [{u'customType': u'referenceId', u'type': u'CUSTOM', u'id': u'6b91d9a0-0159-1000-6f82-44ed3d4b4a5a'}], u'actionVoid': False, u'updatedAt': u'2017-01-04T22:20:40Z', u'processorResponse': {u'status': u'Successful', u'approvalCode': u'667149', u'retrievalRefNum': u'9ee28946-cab1-48af-b30b-d111716128a2', u'batchId': u'1', u'acquirer': u'CHASE_PAYMENTECH', u'approvedAmount': 800, u'transactionId': u'9ee28946-cab1-48af-b30b-d111716128a2', u'processor': u'MOCK', u'statusMessage': u'Successful', u'statusCode': u'1'}, u'settled': False, u'signatureCaptured': True, u'createdAt': u'2017-01-04T22:20:40Z'}

Get a transaction

Get a transaction (along with HATEOS links to all immediately related transactions).

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
transactionId path
string (required)

Response

Returns a Transaction.


Definition

PATCH /businesses/{businessId}/transactions/{transactionId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Update transaction

Update a transaction. This only works on an authorization transaction. This takes a JsonPatch object as request. We currently support replacing all the fields in the /amounts object and adding on /receiptEmailAddress and /signature.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
transactionId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Transaction.


Definition

PUT /businesses/{businessId}/transactions/{transactionId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Record transaction

Record a transaction that has already happened. A full transaction object must be populated as this operation will simply record what is passed to it. If the references field in the body includes a POYNT_ORDER, this transaction will be attached to it.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
transactionId path
string (required)
transaction body
Transaction (optional)

Response

Returns a Transaction.


Definition

POST /businesses/{businessId}/transactions/{transactionId}/capture

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Capture transaction

Capture a previously authorized transaction. Multiple captures are allowed on a single authorization. This return the original authorization transaction with its status updated to CAPTURED if the capture operation succeeded and set to AUTHORIZED if the capture operation failed. The authorization transaction returned will also have a HATEOS link to the capture. In order to get capture specific details (e.g. the processor response), the client will have to perform a GET on the capture transaction from the HATEOS link.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
transactionId path
string (required)
capture body
AdjustTransactionRequest (optional)
allowDuplicates query
boolean (optional)

Response

Returns a Transaction.


Definition

POST /businesses/{businessId}/transactions/{transactionId}/void

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Void transaction

Void and Cancel are similar. They can both undo auth, sale, capture or refund transactions (if the acquirer supports it). A Void is always for the full amount. Hence there can only be one void for a transaction and no amount needs to be specified in the void request. This will result in the original transaction being marked as voided. In order to get to the specific void details (e.g. the specific response received from the processor for the void request), the client will have to follow the HATEOS links. Also note that for a Void operation is always assumed to have been MERCHANT_INITIATED.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
transactionId path
string (required)
voidRequest body
VoidRequest (optional)

Response

Returns a Transaction.


Definition

GET /businesses/{businessId}/transactions/{transactionId}/receipt

Sample Request

TODO: Add request

Sample Response

TODO: Add response

renderReceipt

renderReceipt

Arguments

businessId path
string (required)
transactionId path
string (required)
receiptTemplateId query
string (optional, default is default_txn_receipt_template_id)

Response

Returns a TransactionReceipt.


Customers

Operations for customers of a business


Definition

GET /businesses/{businessId}/customers

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getCustomers = function getCustomers(options, next) { ... }
/**
 * Get all customers of a business by various criteria.
 * @param {String} options.businessId
 * @param {String} options.startAt (optional)
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional)
 * @param {Integer} options.limit (optional)
 * @param {String} options.cardNumberFirst6 (optional)
 * @param {String} options.cardNumberLast4 (optional)
 * @param {Integer} options.cardExpirationMonth (optional)
 * @param {Integer} options.cardExpirationYear (optional)
 * @param {String} options.cardHolderFirstName (optional)
 * @param {String} options.cardHolderLastName (optional)
 * @return {CustomerList} customers
 */

Sample Request

poynt.getCustomers({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "count": 37,
  "customers": [
    {
      "attributes": {},
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "businessPreferences": {
        "emailReceipt": false,
        "preferredCardId": 0,
        "printPaperReceipt": false,
        "useCardOnFile": false
      },
      "cards": [
        {
          "cardHolderFirstName": "",
          "cardHolderFullName": "/",
          "cardHolderLastName": "",
          "expirationDate": 31,
          "expirationMonth": 8,
          "expirationYear": 2022,
          "id": 243043,
          "numberFirst6": "405413",
          "numberLast4": "0833",
          "status": "ACTIVE",
          "type": "VISA"
        }
      ],
      "createdAt": "2017-01-04T22:20:40Z",
      "emails": {},
      "firstName": "",
      "id": 5247839,
      "lastName": "",
      "loyaltyCustomers": [],
      "phones": {},
      "updatedAt": "2017-01-04T22:20:40Z"
    }
  ],
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/customers?startAt=2017-01-06T01%3A23%3A10Z&endAt=2017-08-28T07%3A03%3A20Z&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ]
}

Definition

@classmethod
def get_customers(cls, business_id, start_at=None, start_offset=None,
                  end_at=None, limit=None, card_number_first_6=None,
                  card_number_last_4=None, card_expiration_month=None,
                  card_expiration_year=None, card_holder_first_name=None,
                  card_holder_last_name=None):
"""
Get all customers of a business by various criteria.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get customers created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get customers created before this time in seconds
limit (int, optional): how many customers to return (for pagination)
card_number_first_6 (str, optional): return customers with card numbers starting with this
card_number_last_4 (str, optional): return customers with card numbers ending with this
card_expiration_month (str, optional): return customers with this card expiration month
card_expiration_year (str, optional): return customers with this card expiration year
card_holder_first_name (str, optional): return customers with first name matching this
card_holder_last_name (str, optional): return customers with last name matching this
"""

Sample Request

doc, status_code = poynt.Customer.get_customers(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'count': 37, u'customers': [{u'lastName': u'', u'loyaltyCustomers': [], u'firstName': u'', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'phones': {}, u'businessPreferences': {u'emailReceipt': False, u'preferredCardId': 0, u'printPaperReceipt': False, u'useCardOnFile': False}, u'emails': {}, u'updatedAt': u'2017-01-04T22:20:40Z', u'cards': [{u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'/', u'cardHolderLastName': u'', u'cardHolderFirstName': u'', u'expirationYear': 2022, u'expirationDate': 31, u'numberLast4': u'0833', u'type': u'VISA', u'id': 243043, u'numberFirst6': u'405413'}], u'attributes': {}, u'id': 5247839, u'createdAt': u'2017-01-04T22:20:40Z'}], u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/customers?startAt=2017-01-06T01%3A23%3A10Z&endAt=2017-08-28T07%3A03%3A53Z&limit=1', u'method': u'GET', u'rel': u'next'}]}

Search customers

Get all customers of a business by various criterias.

Arguments

businessId path
string (required)
If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
cardNumberFirst6 query
string (optional)
cardNumberLast4 query
string (optional)
cardExpirationMonth query
integer (optional)
cardExpirationYear query
integer (optional)
cardHolderFirstName query
string (optional)
cardHolderLastName query
string (optional)

Response

Returns a CustomerList.


Definition

GET /businesses/{businessId}/customers/{customerId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getCustomer = function getCustomer(options, next) { ... }
/**
 * Get a single customer at a business.
 * @param {String} options.businessId
 * @param {String} options.customerId
 * @return {Customer} customer
 */

Sample Request

poynt.getCustomer({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  customerId : 5247839
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "createdAt": "2017-01-04T22:20:40Z",
  "updatedAt": "2017-01-04T22:20:40Z",
  "businessPreferences": {
    "useCardOnFile": false,
    "emailReceipt": false,
    "printPaperReceipt": false,
    "preferredCardId": 0
  },
  "insights": {
    "since": "2017-01-04T22:20:40Z",
    "scores": [
      {
        "score": 8.59,
        "type": "OVERALL"
      }
    ],
    "totalOrders": 0
  },
  "cards": [
    {
      "type": "VISA",
      "status": "ACTIVE",
      "expirationDate": 31,
      "expirationMonth": 8,
      "expirationYear": 2022,
      "id": 243043,
      "numberFirst6": "405413",
      "numberLast4": "0833",
      "cardHolderFirstName": "",
      "cardHolderLastName": "",
      "cardHolderFullName": "/"
    }
  ],
  "loyaltyCustomers": [],
  "id": 5247839,
  "emails": {},
  "phones": {},
  "attributes": {},
  "firstName": "",
  "lastName": "",
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
}

Definition

@classmethod
def get_customer(cls, business_id, customer_id):
"""
Get a single customer at a business.

Arguments:
business_id (str): the business ID
customer_id (str): the customer ID
"""

Sample Request

doc, status_code = poynt.Customer.get_customer(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    5247839
)

if status_code < 300:
    print(doc)

Sample Response

{u'lastName': u'', u'loyaltyCustomers': [], u'firstName': u'', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'phones': {}, u'businessPreferences': {u'emailReceipt': False, u'preferredCardId': 0, u'printPaperReceipt': False, u'useCardOnFile': False}, u'emails': {}, u'updatedAt': u'2017-01-04T22:20:40Z', u'cards': [{u'status': u'ACTIVE', u'expirationMonth': 8, u'cardHolderFullName': u'/', u'cardHolderLastName': u'', u'cardHolderFirstName': u'', u'expirationYear': 2022, u'expirationDate': 31, u'numberLast4': u'0833', u'type': u'VISA', u'id': 243043, u'numberFirst6': u'405413'}], u'attributes': {}, u'id': 5247839, u'createdAt': u'2017-01-04T22:20:40Z', u'insights': {u'totalOrders': 0, u'since': u'2017-01-04T22:20:40Z', u'scores': [{u'score': 3.09, u'type': u'OVERALL'}]}}

Get By Id

Get customer by id.

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
customerId path
integer (required)

Response

Returns a Customer.


Definition

POST /businesses/{businessId}/customers

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Create a customer

Create a customer of a business.

Arguments

businessId path
string (required)
customer body
Customer (optional)

Response

Returns a Customer.


Definition

POST /businesses/{businessId}/customers/lookup

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Lookup by card

Find a customer by his card.

Arguments

businessId path
string (required)
card body
Card (optional)

Response

Returns a array.


Definition

PATCH /businesses/{businessId}/customers/{customerId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Update customer

Update a customer. This takes a JsonPatch object as request. We allow updates to all fields except id, businessId, createdAt, cards, devices and insights.

Arguments

Poynt-Request-Id header
string (required)
businessId path
string (required)
customerId path
integer (required)
patch body
JsonPatch (optional)

Response

Returns a Customer.


Apple Pay

Operations for apple pay


Definition

GET /businesses/{businessId}/apple-pay/domain-association-file

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get domain association file for ApplePay

Get domain association filebased on the environment that client is calling from.

Arguments

businessId path
string (required)

Definition

GET /businesses/{businessId}/apple-pay/merchant

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get merchant details

Get merchant details based on the informationsent during registration.

Arguments

businessId path
string (required)

Response

Returns a JsonNode.


Definition

POST /businesses/{businessId}/apple-pay/register

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Register merchant for ApplePay

Register merchant domain to ApplePayserver by business id and returns registered domains on-file.

Arguments

request body
ApplePayRegisterMerchantRequest (optional)
businessId path
string (required)

Response

Returns a JsonNode.


Definition

POST /businesses/{businessId}/apple-pay/unregister

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Unregister merchant for ApplePay

Unregister merchant domain from ApplePayserver by business id.

Arguments

request body
ApplePayUnregisterMerchantRequest (optional)
businessId path
string (required)

Merchants


Businesses

Business resource represents the merchant business. The Poynt system assumes the following business hierarchy. There is the parent business at the root. Each business could have 0 or more stores. Each store could have 0 or more terminals. This resource provides operations to create, update and view this entire hierarchy.


Definition

GET /businesses

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get by Parameters

Get a business by various parameters.

Arguments

acquirer query
string (optional)
storeDeviceId query
string (optional)
mid query
string (optional)
isBusinessLevelMid query
boolean (optional, default is false)
tid query
string (optional)
ignoreDeactivatedDevices query
boolean (optional, default is true)
includeField query
Set (optional)
If-Modified-Since header
string (optional)

Response

Returns a Business.


Definition

GET /businesses/{businessId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getBusiness = function getBusiness(options, next) { ... }
/**
 * Gets a business by ID.
 * @param {String} options.businessId
 * @return {Business} business
 */

Sample Request

poynt.getBusiness({
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "acquirer": "ELAVON",
  "activeSince": "1970-01-01T00:00:00Z",
  "address": {
    "city": "Palo Alto",
    "countryCode": "USA",
    "createdAt": "2017-01-04T22:04:33Z",
    "id": 48119,
    "line1": "4151 Middlefield Road",
    "line2": "Level 2",
    "postalCode": "94303",
    "status": "ADDED",
    "territory": "California",
    "territoryType": "STATE",
    "type": "BUSINESS",
    "updatedAt": "2017-08-25T01:05:33Z"
  },
  "attributes": { ... },
  "businessUrl": "http://lawrence-s-last-straw.com",
  "createdAt": "2017-01-04T22:04:34Z",
  "description": "Just another test merchant",
  "doingBusinessAs": "Lawrence's Last Straw",
  "emailAddress": "lawrence-s-last-straw@gmail.com",
  "externalMerchantId": "lawrence's0226",
  "id": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "industryType": "Restaurant",
  "legalName": "Lawrence's Last Straw",
  "mcc": "5812",
  "mockProcessor": false,
  "phone": {
    "areaCode": "575",
    "createdAt": "2017-01-04T22:04:33Z",
    "id": 50700,
    "ituCountryCode": "1",
    "localPhoneNumber": "2040375",
    "status": "ADDED",
    "type": "BUSINESS",
    "updatedAt": "2017-08-25T01:05:33Z"
  },
  "processor": "ELAVON",
  "sic": "5812",
  "status": "ACTIVATED",
  "stores": [
    {
      "acquirer": "ELAVON",
      "address": {
        "city": "Palo Alto",
        "countryCode": "USA",
        "createdAt": "2017-01-04T22:04:33Z",
        "id": 48120,
        "line1": "10617 Business Drive",
        "line2": "Suite 424",
        "postalCode": "94301",
        "status": "ADDED",
        "territory": "California",
        "territoryType": "STATE",
        "type": "BUSINESS",
        "updatedAt": "2017-08-16T02:59:42Z"
      },
      "attributes": { ... },
      "currency": "USD",
      "displayName": "Lawrence's Last Straw 488",
      "externalStoreId": "161779901711",
      "fixedLocation": true,
      "id": "c394627f-4f68-47fb-90a5-684ea801a352",
      "latitude": 37.4457,
      "longitude": -122.162,
      "mockProcessor": false,
      "phone": {
        "areaCode": "575",
        "createdAt": "2017-01-04T22:04:33Z",
        "id": 50701,
        "ituCountryCode": "1",
        "localPhoneNumber": "2040375",
        "status": "ADDED",
        "type": "BUSINESS",
        "updatedAt": "2017-08-16T02:59:42Z"
      },
      "processor": "ELAVON",
      "processorData": {},
      "status": "ACTIVE",
      "storeDevices": [
        {
          "businessAgreements": {
            "EULA": {
              "acceptedAt": "2017-07-25T01:36:14Z",
              "current": true,
              "type": "EULA",
              "userId": 5247838,
              "version": "1f",
              "versionOutdated": false
            }
          },
          "catalogId": "9deca670-8761-4133-b1a9-b05b9fb01cb6",
          "createdAt": "2017-01-04T22:10:00Z",
          "deviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
          "externalTerminalId": "8024696638530",
          "name": "LAWRENCE'S LAST STRAW DON'T MESS",
          "publicKey": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyl+Sa2C1E6xcv9d9Mm9N\ngtzDtSsjWd9k7PZPDLy3JRq3dhGU9rQtopfEUrtqRUDRS7xpP3842enns39Z427+\nwOuAq7aqVLHzCIio8+D0m21mmsKpE8rSH54dCKciSypuj/MF4o+jIMA43+ov6dba\nN/6WFH/+c4MzTqz673XldP9RAvrK8k55lKoZW5bvX5Bx0xmFbtey17Uyby+y6kT+\nTyQArYwzEFBA2RQ+LKf/XwIgoh6RcdMVlNahe5LNW2rl5FQGm+HxnvYG6ZQGQ4oX\nFEGClsvOQabdjVXNNA6rVmJeeKmSekVNFjA3ZqEcmq8E6ijmT/H1upmiZ5fI0Eag\nSwIDAQAB\n-----END PUBLIC KEY-----\n",
          "serialNumber": "P61SWA231FS000416",
          "status": "ACTIVATED",
          "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
          "type": "TERMINAL",
          "updatedAt": "2017-08-16T04:26:19Z"
        }
      ],
      "timezone": "America/Los_Angeles"
    }
  ],
  "timezone": "America/Los_Angeles",
  "type": "TEST_MERCHANT",
  "updatedAt": "2017-08-25T01:05:33Z"
}

Definition

@classmethod
def get_business(cls, business_id):
"""
Gets a business by ID.

Arguments:
business_id (str): the business ID to get
"""

Sample Request

doc, status_code = poynt.Business.get_business(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb'
)

if status_code < 300:
    print(doc)

Sample Response

{u'stores': [{u'status': u'ACTIVE', u'processorData': {}, u'externalStoreId': u'161779901711', u'displayName': u"Lawrence's Last Straw 488", u'currency': u'USD', u'mockProcessor': False, u'longitude': -122.162, u'id': u'c394627f-4f68-47fb-90a5-684ea801a352', u'storeDevices': [{u'status': u'ACTIVATED', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'name': u"LAWRENCE'S LAST STRAW DON'T MESS", u'serialNumber': u'P61SWA231FS000416', u'businessAgreements': {u'EULA': {u'userId': 5247838, u'versionOutdated': False, u'current': True, u'version': u'1f', u'acceptedAt': u'2017-07-25T01:36:14Z', u'type': u'EULA'}}, u'externalTerminalId': u'8024696638530', u'publicKey': u'-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyl+Sa2C1E6xcv9d9Mm9N\ngtzDtSsjWd9k7PZPDLy3JRq3dhGU9rQtopfEUrtqRUDRS7xpP3842enns39Z427+\nwOuAq7aqVLHzCIio8+D0m21mmsKpE8rSH54dCKciSypuj/MF4o+jIMA43+ov6dba\nN/6WFH/+c4MzTqz673XldP9RAvrK8k55lKoZW5bvX5Bx0xmFbtey17Uyby+y6kT+\nTyQArYwzEFBA2RQ+LKf/XwIgoh6RcdMVlNahe5LNW2rl5FQGm+HxnvYG6ZQGQ4oX\nFEGClsvOQabdjVXNNA6rVmJeeKmSekVNFjA3ZqEcmq8E6ijmT/H1upmiZ5fI0Eag\nSwIDAQAB\n-----END PUBLIC KEY-----\n', u'deviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652', u'updatedAt': u'2017-08-16T04:26:19Z', u'catalogId': u'9deca670-8761-4133-b1a9-b05b9fb01cb6', u'type': u'TERMINAL', u'createdAt': u'2017-01-04T22:10:00Z'}], u'phone': {u'status': u'ADDED', u'areaCode': u'575', u'localPhoneNumber': u'2040375', u'updatedAt': u'2017-08-16T02:59:42Z', u'ituCountryCode': u'1', u'type': u'BUSINESS', u'id': 50701, u'createdAt': u'2017-01-04T22:04:33Z'}, u'timezone': u'America/Los_Angeles', u'acquirer': u'ELAVON', u'address': {u'status': u'ADDED', u'city': u'Palo Alto', u'countryCode': u'USA', u'line2': u'Suite 424', u'line1': u'10617 Business Drive', u'territoryType': u'STATE', u'updatedAt': u'2017-08-16T02:59:42Z', u'postalCode': u'94301', u'territory': u'California', u'type': u'BUSINESS', u'id': 48120, u'createdAt': u'2017-01-04T22:04:33Z'}, u'latitude': 37.4457, u'attributes': {}, u'processor': u'ELAVON', u'fixedLocation': True}], u'businessUrl': u'http://lawrence-s-last-straw.com', u'updatedAt': u'2017-08-25T01:05:33Z', u'timezone': u'America/Los_Angeles', u'id': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'industryType': u'Restaurant', u'sic': u'5812', u'acquirer': u'ELAVON', u'type': u'TEST_MERCHANT', u'status': u'ACTIVATED', u'description': u'Just another test merchant', u'mockProcessor': False, u'mcc': u'5812', u'activeSince': u'1970-01-01T00:00:00Z', u'phone': {u'status': u'ADDED', u'areaCode': u'575', u'localPhoneNumber': u'2040375', u'updatedAt': u'2017-08-25T01:05:33Z', u'ituCountryCode': u'1', u'type': u'BUSINESS', u'id': 50700, u'createdAt': u'2017-01-04T22:04:33Z'}, u'emailAddress': u'lawrence-s-last-straw@gmail.com', u'address': {u'status': u'ADDED', u'city': u'Palo Alto', u'countryCode': u'USA', u'line2': u'Level 2', u'line1': u'4151 Middlefield Road', u'territoryType': u'STATE', u'updatedAt': u'2017-08-25T01:05:33Z', u'postalCode': u'94303', u'territory': u'California', u'type': u'BUSINESS', u'id': 48119, u'createdAt': u'2017-01-04T22:04:33Z'}, u'externalMerchantId': u"lawrence's0226", u'doingBusinessAs': u"Lawrence's Last Straw", u'createdAt': u'2017-01-04T22:04:34Z', u'legalName': u"Lawrence's Last Straw", u'attributes': {}, u'processor': u'ELAVON'}

Get by businessId

Get a business by id.

Arguments

businessId path
string (required)
storeDeviceId query
string (optional)
includeField query
Set (optional)
ignoreDeactivatedDevices query
boolean (optional, default is true)

Response

Returns a Business.


Definition

GET /businesses/{businessId}/stores/{storeId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get store by id

Get a store by businessId and storeId.

Arguments

businessId path
string (required)
storeId path
string (required)
includeField query
Set (optional)

Response

Returns a Store.


Definition

GET /businesses

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getBusinessByDeviceId = function getBusinessByDeviceId(options, next) { ... }
/**
 * Gets a business by device ID.
 * @param {String} options.deviceId
 * @return {Business} business
 */

Sample Request

poynt.getBusinessByDeviceId({
  deviceId: 'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "acquirer": "ELAVON",
  "activeSince": "1970-01-01T00:00:00Z",
  "address": {
    "city": "Palo Alto",
    "countryCode": "USA",
    "createdAt": "2017-01-04T22:04:33Z",
    "id": 48119,
    "line1": "4151 Middlefield Road",
    "line2": "Level 2",
    "postalCode": "94303",
    "status": "ADDED",
    "territory": "California",
    "territoryType": "STATE",
    "type": "BUSINESS",
    "updatedAt": "2017-08-25T01:05:33Z"
  },
  "attributes": { ... },
  "businessUrl": "http://lawrence-s-last-straw.com",
  "createdAt": "2017-01-04T22:04:34Z",
  "description": "Just another test merchant",
  "doingBusinessAs": "Lawrence's Last Straw",
  "emailAddress": "lawrence-s-last-straw@gmail.com",
  "externalMerchantId": "lawrence's0226",
  "id": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "industryType": "Restaurant",
  "legalName": "Lawrence's Last Straw",
  "mcc": "5812",
  "mockProcessor": false,
  "phone": {
    "areaCode": "575",
    "createdAt": "2017-01-04T22:04:33Z",
    "id": 50700,
    "ituCountryCode": "1",
    "localPhoneNumber": "2040375",
    "status": "ADDED",
    "type": "BUSINESS",
    "updatedAt": "2017-08-25T01:05:33Z"
  },
  "processor": "ELAVON",
  "sic": "5812",
  "status": "ACTIVATED",
  "stores": [
    {
      "acquirer": "ELAVON",
      "address": {
        "city": "Palo Alto",
        "countryCode": "USA",
        "createdAt": "2017-01-04T22:04:33Z",
        "id": 48120,
        "line1": "10617 Business Drive",
        "line2": "Suite 424",
        "postalCode": "94301",
        "status": "ADDED",
        "territory": "California",
        "territoryType": "STATE",
        "type": "BUSINESS",
        "updatedAt": "2017-08-16T02:59:42Z"
      },
      "attributes": { ... },
      "currency": "USD",
      "displayName": "Lawrence's Last Straw 488",
      "externalStoreId": "161779901711",
      "fixedLocation": true,
      "id": "c394627f-4f68-47fb-90a5-684ea801a352",
      "latitude": 37.4457,
      "longitude": -122.162,
      "mockProcessor": false,
      "phone": {
        "areaCode": "575",
        "createdAt": "2017-01-04T22:04:33Z",
        "id": 50701,
        "ituCountryCode": "1",
        "localPhoneNumber": "2040375",
        "status": "ADDED",
        "type": "BUSINESS",
        "updatedAt": "2017-08-16T02:59:42Z"
      },
      "processor": "ELAVON",
      "processorData": {},
      "status": "ACTIVE",
      "storeDevices": [
        {
          "businessAgreements": {
            "EULA": {
              "acceptedAt": "2017-07-25T01:36:14Z",
              "current": true,
              "type": "EULA",
              "userId": 5247838,
              "version": "1f",
              "versionOutdated": false
            }
          },
          "catalogId": "9deca670-8761-4133-b1a9-b05b9fb01cb6",
          "createdAt": "2017-01-04T22:10:00Z",
          "deviceId": "urn:tid:48c54303-6d51-39af-bdeb-4af53f621652",
          "externalTerminalId": "8024696638530",
          "name": "LAWRENCE'S LAST STRAW DON'T MESS",
          "publicKey": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyl+Sa2C1E6xcv9d9Mm9N\ngtzDtSsjWd9k7PZPDLy3JRq3dhGU9rQtopfEUrtqRUDRS7xpP3842enns39Z427+\nwOuAq7aqVLHzCIio8+D0m21mmsKpE8rSH54dCKciSypuj/MF4o+jIMA43+ov6dba\nN/6WFH/+c4MzTqz673XldP9RAvrK8k55lKoZW5bvX5Bx0xmFbtey17Uyby+y6kT+\nTyQArYwzEFBA2RQ+LKf/XwIgoh6RcdMVlNahe5LNW2rl5FQGm+HxnvYG6ZQGQ4oX\nFEGClsvOQabdjVXNNA6rVmJeeKmSekVNFjA3ZqEcmq8E6ijmT/H1upmiZ5fI0Eag\nSwIDAQAB\n-----END PUBLIC KEY-----\n",
          "serialNumber": "P61SWA231FS000416",
          "status": "ACTIVATED",
          "storeId": "c394627f-4f68-47fb-90a5-684ea801a352",
          "type": "TERMINAL",
          "updatedAt": "2017-08-16T04:26:19Z"
        }
      ],
      "timezone": "America/Los_Angeles"
    }
  ],
  "timezone": "America/Los_Angeles",
  "type": "TEST_MERCHANT",
  "updatedAt": "2017-08-25T01:05:33Z"
}

Definition

@classmethod
def get_business_by_device_id(cls, device_id):
"""
Get a business by a device id.

Arguments:
device_id (str): the device ID to get a business for
"""

Sample Request

doc, status_code = poynt.Business.get_business_by_device_id(
    'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652'
)

if status_code < 300:
    print(doc)

Sample Response

{u'stores': [{u'status': u'ACTIVE', u'processorData': {}, u'externalStoreId': u'161779901711', u'displayName': u"Lawrence's Last Straw 488", u'currency': u'USD', u'mockProcessor': False, u'longitude': -122.162, u'id': u'c394627f-4f68-47fb-90a5-684ea801a352', u'storeDevices': [{u'status': u'ACTIVATED', u'storeId': u'c394627f-4f68-47fb-90a5-684ea801a352', u'name': u"LAWRENCE'S LAST STRAW DON'T MESS", u'serialNumber': u'P61SWA231FS000416', u'businessAgreements': {u'EULA': {u'userId': 5247838, u'versionOutdated': False, u'current': True, u'version': u'1f', u'acceptedAt': u'2017-07-25T01:36:14Z', u'type': u'EULA'}}, u'externalTerminalId': u'8024696638530', u'publicKey': u'-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyl+Sa2C1E6xcv9d9Mm9N\ngtzDtSsjWd9k7PZPDLy3JRq3dhGU9rQtopfEUrtqRUDRS7xpP3842enns39Z427+\nwOuAq7aqVLHzCIio8+D0m21mmsKpE8rSH54dCKciSypuj/MF4o+jIMA43+ov6dba\nN/6WFH/+c4MzTqz673XldP9RAvrK8k55lKoZW5bvX5Bx0xmFbtey17Uyby+y6kT+\nTyQArYwzEFBA2RQ+LKf/XwIgoh6RcdMVlNahe5LNW2rl5FQGm+HxnvYG6ZQGQ4oX\nFEGClsvOQabdjVXNNA6rVmJeeKmSekVNFjA3ZqEcmq8E6ijmT/H1upmiZ5fI0Eag\nSwIDAQAB\n-----END PUBLIC KEY-----\n', u'deviceId': u'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652', u'updatedAt': u'2017-08-16T04:26:19Z', u'catalogId': u'9deca670-8761-4133-b1a9-b05b9fb01cb6', u'type': u'TERMINAL', u'createdAt': u'2017-01-04T22:10:00Z'}], u'phone': {u'status': u'ADDED', u'areaCode': u'575', u'localPhoneNumber': u'2040375', u'updatedAt': u'2017-08-16T02:59:42Z', u'ituCountryCode': u'1', u'type': u'BUSINESS', u'id': 50701, u'createdAt': u'2017-01-04T22:04:33Z'}, u'timezone': u'America/Los_Angeles', u'acquirer': u'ELAVON', u'address': {u'status': u'ADDED', u'city': u'Palo Alto', u'countryCode': u'USA', u'line2': u'Suite 424', u'line1': u'10617 Business Drive', u'territoryType': u'STATE', u'updatedAt': u'2017-08-16T02:59:42Z', u'postalCode': u'94301', u'territory': u'California', u'type': u'BUSINESS', u'id': 48120, u'createdAt': u'2017-01-04T22:04:33Z'}, u'latitude': 37.4457, u'attributes': {}, u'processor': u'ELAVON', u'fixedLocation': True}], u'businessUrl': u'http://lawrence-s-last-straw.com', u'updatedAt': u'2017-08-25T01:05:33Z', u'timezone': u'America/Los_Angeles', u'id': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'industryType': u'Restaurant', u'sic': u'5812', u'acquirer': u'ELAVON', u'type': u'TEST_MERCHANT', u'status': u'ACTIVATED', u'description': u'Just another test merchant', u'mockProcessor': False, u'mcc': u'5812', u'activeSince': u'1970-01-01T00:00:00Z', u'phone': {u'status': u'ADDED', u'areaCode': u'575', u'localPhoneNumber': u'2040375', u'updatedAt': u'2017-08-25T01:05:33Z', u'ituCountryCode': u'1', u'type': u'BUSINESS', u'id': 50700, u'createdAt': u'2017-01-04T22:04:33Z'}, u'emailAddress': u'lawrence-s-last-straw@gmail.com', u'address': {u'status': u'ADDED', u'city': u'Palo Alto', u'countryCode': u'USA', u'line2': u'Level 2', u'line1': u'4151 Middlefield Road', u'territoryType': u'STATE', u'updatedAt': u'2017-08-25T01:05:33Z', u'postalCode': u'94303', u'territory': u'California', u'type': u'BUSINESS', u'id': 48119, u'createdAt': u'2017-01-04T22:04:33Z'}, u'externalMerchantId': u"lawrence's0226", u'doingBusinessAs': u"Lawrence's Last Straw", u'createdAt': u'2017-01-04T22:04:34Z', u'legalName': u"Lawrence's Last Straw", u'attributes': {}, u'processor': u'ELAVON'}

Get by device Id

Get a business by a device id.

Arguments

storeDeviceId query
string (required)

Response

Returns a Business.


Business Users

Operations for owners and employees of a business


Definition

GET /businesses/{businessId}/businessUsers

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getBusinessUsers = function getBusinessUsers(options, next) { ... }
/**
 * Get all users at a business.
 * @param {String} options.businessId
 * @return {BusinessUser[]} businessusers
 */

Sample Request

poynt.getBusinessUsers({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

[
  {
    "status": "EMPLOYED",
    "employmentDetails": {
      "role": "OWNER",
      "startAt": 1483568424,
      "endAt": 0
    },
    "credentials": [
      {
        "publicCredentialType": "USERNAME",
        "id": 33250,
        "publicCredentialValue": "law"
      }
    ],
    "userId": 5247838,
    "firstName": "law",
    "lastName": "",
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
  },
  {
    "status": "EMPLOYED",
    "employmentDetails": {
      "role": "EMPLOYEE",
      "startAt": 0,
      "endAt": 0
    },
    "credentials": [
      {
        "publicCredentialType": "USERNAME",
        "id": 33266,
        "publicCredentialValue": "sample"
      }
    ],
    "userId": 5247869,
    "firstName": "Sample",
    "lastName": "Person",
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
  },
  {
    "status": "EMPLOYED",
    "employmentDetails": {
      "role": "EMPLOYEE",
      "startAt": 0,
      "endAt": 0
    },
    "credentials": [
      {
        "publicCredentialType": "USERNAME",
        "id": 33267,
        "publicCredentialValue": "Test"
      }
    ],
    "userId": 5247870,
    "firstName": "Test",
    "lastName": "Person",
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
  },
  {
    "status": "EMPLOYED",
    "employmentDetails": {
      "role": "OWNER",
      "startAt": 1487789772,
      "endAt": 0
    },
    "credentials": [
      {
        "publicCredentialType": "USERNAME",
        "id": 35355,
        "publicCredentialValue": "yan"
      }
    ],
    "userId": 5253478,
    "firstName": "yan",
    "lastName": "",
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
  }
]

Definition

@classmethod
def get_business_users(cls, business_id):
"""
Get all users at a business.

Arguments:
business_id (str): the business ID
"""

Sample Request

doc, status_code = poynt.BusinessUser.get_business_users(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb'
)

if status_code < 300:
    print(doc)

Sample Response

[{u'status': u'EMPLOYED', u'firstName': u'law', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'lastName': u'', u'userId': 5247838, u'employmentDetails': {u'startAt': 1483568424, u'role': u'OWNER', u'endAt': 0}, u'credentials': [{u'publicCredentialType': u'USERNAME', u'publicCredentialValue': u'law', u'id': 33250}]}, {u'status': u'EMPLOYED', u'firstName': u'Sample', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'lastName': u'Person', u'userId': 5247869, u'employmentDetails': {u'startAt': 0, u'role': u'EMPLOYEE', u'endAt': 0}, u'credentials': [{u'publicCredentialType': u'USERNAME', u'publicCredentialValue': u'sample', u'id': 33266}]}, {u'status': u'EMPLOYED', u'firstName': u'Test', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'lastName': u'Person', u'userId': 5247870, u'employmentDetails': {u'startAt': 0, u'role': u'EMPLOYEE', u'endAt': 0}, u'credentials': [{u'publicCredentialType': u'USERNAME', u'publicCredentialValue': u'Test', u'id': 33267}]}, {u'status': u'EMPLOYED', u'firstName': u'yan', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'lastName': u'', u'userId': 5253478, u'employmentDetails': {u'startAt': 1487789772, u'role': u'OWNER', u'endAt': 0}, u'credentials': [{u'publicCredentialType': u'USERNAME', u'publicCredentialValue': u'yan', u'id': 35355}]}]

Get All Users

Get all users at a business.

Arguments

businessId path
string (required)
api-version header
string (optional)

Response

Returns a array.


Definition

GET /businesses/{businessId}/businessUsers/{businessUserId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getBusinessUser = function getBusinessUser(options, next) { ... }
/**
 * Get a single user at a business.
 * @param {String} options.businessId
 * @param {String} options.businessUserId
 * @return {BusinessUser} businessuser
 */

Sample Request

poynt.getBusinessUser({
  businessId     : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  businessUserId : 5247838
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "credentials": [
    {
      "id": 33250,
      "publicCredentialType": "USERNAME",
      "publicCredentialValue": "law"
    }
  ],
  "employmentDetails": {
    "endAt": 0,
    "role": "OWNER",
    "startAt": 1483568424
  },
  "firstName": "law",
  "lastName": "",
  "status": "EMPLOYED",
  "userId": 5247838
}

Definition

@classmethod
def get_business_user(cls, business_id, business_user_id):
"""
Get a single user at a business.

Arguments:
business_id (str): the business ID
business_user_id (str): the user ID
"""

Sample Request

doc, status_code = poynt.BusinessUser.get_business_user(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    5247838
)

if status_code < 300:
    print(doc)

Sample Response

{u'status': u'EMPLOYED', u'firstName': u'law', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'lastName': u'', u'userId': 5247838, u'employmentDetails': {u'startAt': 1483568424, u'role': u'OWNER', u'endAt': 0}, u'credentials': [{u'publicCredentialType': u'USERNAME', u'publicCredentialValue': u'law', u'id': 33250}]}

Get User

Get a user at a business.

Arguments

businessId path
string (required)
businessUserId path
integer (required)
api-version header
string (optional)

Response

Returns a BusinessUser.



Inventory

Operations for inventory


Definition

GET /businesses/{businessId}/inventory

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get Inventory Summary List

Get a list of inventory summary.

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
storeId query
string (optional)
productId query
string (optional)
sku query
string (optional)
businessId path
string (required)

Response

Returns a InventorySummaryList.


Definition

PUT /businesses/{businessId}/products/{productId}/inventory

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Add Inventory

Add a new inventory at a store.

Arguments

businessId path
string (required)
productId path
string (required)
inventory body
Inventory (optional)

Response

Returns a Inventory.


Definition

GET /businesses/{businessId}/products/{productId}/inventory/{storeId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get Inventory

Get an inventory at a store.

Arguments

businessId path
string (required)
productId path
string (required)
storeId path
string (required)

Response

Returns a Inventory.


Definition

POST /businesses/{businessId}/products/{productId}/inventory/{storeId}/decrement

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Decrement inventory

Decrement an inventory.

Arguments

businessId path
string (required)
productId path
string (required)
storeId path
string (required)
delta query
number (required)

Response

Returns a Inventory.


Definition

POST /businesses/{businessId}/products/{productId}/inventory/{storeId}/increment

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Increment inventory

Increment an inventory.

Arguments

businessId path
string (required)
productId path
string (required)
storeId path
string (required)
delta query
number (required)

Response

Returns a Inventory.


Definition

PUT /businesses/{businessId}/products/{productId}/variants/{sku}/inventory

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Add Variant Inventory

Add a new variant inventory at a store.

Arguments

businessId path
string (required)
productId path
string (required)
sku path
string (required)
inventory body
Inventory (optional)

Response

Returns a Inventory.


Definition

GET /businesses/{businessId}/products/{productId}/variants/{sku}/inventory/{storeId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Get Variant Inventory

Get a variant inventory at a store.

Arguments

businessId path
string (required)
productId path
string (required)
sku path
string (required)
storeId path
string (required)

Response

Returns a Inventory.


Definition

POST /businesses/{businessId}/products/{productId}/variants/{sku}/inventory/{storeId}/decrement

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Decrement variant inventory

Decrement a variant inventory.

Arguments

businessId path
string (required)
productId path
string (required)
sku path
string (required)
storeId path
string (required)
delta query
number (required)

Response

Returns a Inventory.


Definition

POST /businesses/{businessId}/products/{productId}/variants/{sku}/inventory/{storeId}/increment

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

TODO: Add definition

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Increment variant inventory

Increment a variant inventory.

Arguments

businessId path
string (required)
productId path
string (required)
sku path
string (required)
storeId path
string (required)
delta query
number (required)

Response

Returns a Inventory.


Products

Products are what a merchant sell at their business. Products have a name, shortCode, sku, and price. sku should be unique for tracking inventory purpose. shortCode should be unique and represents an easily remembered identifier for the business user.


Definition

GET /businesses/{businessId}/products

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getProducts = function getProducts(options, next) { ... }
/**
 * Get a list of products
 * @param {String} options.businessId
 * @param {String} options.startAt (optional)
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional)
 * @param {Integer} options.limit (optional)
 * @return {ProductList} products
 */

Sample Request

poynt.getProducts({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/products?startAt=2017-01-04T22%3A04%3A34Z&endAt=2017-08-28T07%3A23%3A30Z&startOffset=1&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ],
  "products": [
    {
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-01-04T22:04:34Z",
      "description": "Cappuccino",
      "id": "080aae58-93fe-4754-93f4-8fbf9420b49d",
      "name": "Cappuccino",
      "price": {
        "amount": 350,
        "currency": "USD"
      },
      "shortCode": "Cappu",
      "sku": "082011500008",
      "status": "ACTIVE",
      "type": "SIMPLE",
      "updatedAt": "2017-01-04T22:04:34Z"
    }
  ]
}

Definition

@classmethod
def get_products(cls, business_id, start_at=None, start_offset=None,
             end_at=None, limit=None):
"""
Get a list of products at a business.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get products created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get products created before this time in seconds
limit (int, optional): how many products to return (for pagination)
"""

Sample Request

doc, status_code = poynt.Product.get_products(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'products': [{u'status': u'ACTIVE', u'sku': u'082011500008', u'name': u'Cappuccino', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 350}, u'updatedAt': u'2017-01-04T22:04:34Z', u'shortCode': u'Cappu', u'id': u'080aae58-93fe-4754-93f4-8fbf9420b49d', u'createdAt': u'2017-01-04T22:04:34Z', u'description': u'Cappuccino'}], u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/products?startAt=2017-01-04T22%3A04%3A34Z&endAt=2017-08-28T07%3A24%3A08Z&startOffset=1&limit=1', u'method': u'GET', u'rel': u'next'}]}

Get List

Get all product since time. Result is paginated

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId path
string (required)

Response

Returns a ProductList.


Definition

POST /businesses/{businessId}/products

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createProduct = function createProduct(options, product, next) { ... }
/**
 * Creates a product on a business.
 * @param {String} options.businessId
 * @param {Product} product
 * @return {Product} product
 */

Sample Request

poynt.createProduct({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, {
  price: {
    currency: 'USD',
    amount: 500
  },
  status: 'ACTIVE',
  shortCode: 'FOO',
  sku: 'FOO',
  name: 'Foo Product'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T07:26:29Z",
  "id": "e989e7eb-5c59-4c4d-9a80-006147f0740f",
  "name": "Foo Product",
  "price": {
    "amount": 500,
    "currency": "USD"
  },
  "shortCode": "FOO",
  "sku": "FOO",
  "status": "ACTIVE",
  "type": "SIMPLE",
  "updatedAt": "2017-08-28T07:26:29Z"
}

Definition

@classmethod
def create_product(cls, business_id, product):
"""
Creates a product on a business.

Arguments:
business_id (str): the business ID
product (dict): the full product object
"""

Sample Request

doc, status_code = poynt.Product.create_product(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    {
        'price': {
            'currency': 'USD',
            'amount': 500
        },
        'status': 'ACTIVE',
        'shortCode': 'FOO',
        'sku': 'FOO',
        'name': 'Foo Product'
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'status': u'ACTIVE', u'sku': u'FOO', u'name': u'Foo Product', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 500}, u'updatedAt': u'2017-08-28T07:25:23Z', u'shortCode': u'FOO', u'id': u'd92cc4d6-0298-47cf-9537-b45b1870454c', u'createdAt': u'2017-08-28T07:25:23Z'}

Create

Create a product definition for a business.

Arguments

businessId path
string (required)
product body
Product (optional)

Response

Returns a Product.


Definition

GET /businesses/{businessId}/products/lookup

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.lookupProducts = function lookupProducts(options, next) { ... }
/**
 * Get a list of products by ID.
 * @param {String} options.businessId
 * @param {String[]} options.ids
 * @return {ProductList} products
 */

Sample Request

poynt.lookupProducts({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  ids        : ['e989e7eb-5c59-4c4d-9a80-006147f0740f']
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

[
  {
    "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
    "createdAt": "2017-08-28T07:26:29Z",
    "id": "e989e7eb-5c59-4c4d-9a80-006147f0740f",
    "name": "Foo Product",
    "price": {
      "amount": 500,
      "currency": "USD"
    },
    "shortCode": "FOO",
    "sku": "FOO",
    "status": "ACTIVE",
    "type": "SIMPLE",
    "updatedAt": "2017-08-28T07:26:29Z"
  }
]

Definition

@classmethod
def lookup_products(cls, business_id, product_ids):
"""
Get a list of products by ID.

Arguments:
business_id (str): the business ID
product_ids (list of str): a list of product ids
"""

Sample Request

doc, status_code = poynt.Product.lookup_products(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    ['e989e7eb-5c59-4c4d-9a80-006147f0740f']
)

if status_code < 300:
    print(doc)

Sample Response

{u'products': [{u'status': u'ACTIVE', u'sku': u'FOO', u'name': u'Foo Product', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 500}, u'updatedAt': u'2017-08-28T07:26:29Z', u'shortCode': u'FOO', u'id': u'e989e7eb-5c59-4c4d-9a80-006147f0740f', u'createdAt': u'2017-08-28T07:26:29Z'}]}

Get Multiple Id

Get multiple products by ids.

Arguments

businessId path
string (required)
ids query
string (required)

Response

Returns a ProductList.


Definition

GET /businesses/{businessId}/products/summary

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getProductsSummary = function getProductsSummary(options, next) { ... }
/**
 * Get a list of  summaries at a business. Product summaries contain product
 * shortCode, price, businessId, name, and id.
 * @param {String} options.businessId
 * @param {String} options.startAt (optional)
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional)
 * @param {Integer} options.limit (optional)
 * @return {ProductList} products
 */

Sample Request

poynt.getProductsSummary({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/products/summary?startAt=2017-01-04T22%3A04%3A34Z&endAt=2017-08-28T07%3A30%3A34Z&startOffset=1&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ],
  "products": [
    {
      "id": "080aae58-93fe-4754-93f4-8fbf9420b49d",
      "name": "Cappuccino",
      "price": {
        "amount": 350,
        "currency": "USD"
      },
      "shortCode": "Cappu"
    }
  ]
}

Definition

@classmethod
def get_products_summary(cls, business_id, start_at=None, start_offset=None,
                         end_at=None, limit=None):
"""
Get a list of product summaries at a business. Product summaries contain
product shortCode, price, businessId, name, and id.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get products created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get products created before this time in seconds
limit (int, optional): how many products to return (for pagination)
"""

Sample Request

doc, status_code = poynt.Product.get_products_summary(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'products': [{u'price': {u'currency': u'USD', u'amount': 350}, u'shortCode': u'Cappu', u'id': u'080aae58-93fe-4754-93f4-8fbf9420b49d', u'name': u'Cappuccino'}], u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/products/summary?startAt=2017-01-04T22%3A04%3A34Z&endAt=2017-08-28T07%3A30%3A01Z&startOffset=1&limit=1', u'method': u'GET', u'rel': u'next'}]}

Get Summary

Get all product summary. Result is paginated

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId path
string (required)

Response

Returns a ProductSummaryList.


Definition

DELETE /businesses/{businessId}/products/{productId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.deleteProduct = function deleteProduct(options, next) { ... }
/**
 * Deactivates a product. Deactivated products will be removed from all catalog
 * references.
 * @param {String} options.businessId
 * @param {String} options.productId
 * @return {Product} product
 */

Sample Request

poynt.deleteProduct({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  productId  : '080aae58-93fe-4754-93f4-8fbf9420b49d'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def delete_product(cls, business_id, product_id):
"""
Deactivates a product. Deactivated products will be removed from all
catalog references.

Arguments:
business_id (str): the business ID
product_id (str): the product ID
"""

Sample Request

doc, status_code = poynt.Product.delete_product(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '080aae58-93fe-4754-93f4-8fbf9420b49d'
)

if status_code < 300:
    print(doc)

Sample Response

None

Deactivate

Deactivate a product. Deactivated product will be removed from all catalog references.

Arguments

businessId path
string (required)
productId path
string (required)

Definition

GET /businesses/{businessId}/products/{productId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getProduct = function getProduct(options, next) { ... }
/**
 * Get a single product for a business.
 * @param {String} options.businessId
 * @param {String} options.productId
 * @return {Product} product
 */

Sample Request

poynt.getProduct({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  productId  : '0cb54922-0ef2-4509-8735-72ccb373c464'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-01-04T22:04:34Z",
  "description": "Apple Pie",
  "id": "0cb54922-0ef2-4509-8735-72ccb373c464",
  "name": "Apple Pie",
  "price": {
    "amount": 300,
    "currency": "USD"
  },
  "shortCode": "ApPie",
  "sku": "082011500001",
  "status": "ACTIVE",
  "type": "SIMPLE",
  "updatedAt": "2017-01-04T22:04:34Z"
}

Definition

@classmethod
def get_product(cls, business_id, product_id):
"""
Get a single product for a business.

Arguments:
business_id (str): the business ID
product_id (str): the product ID
"""

Sample Request

doc, status_code = poynt.Product.get_product(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '0cb54922-0ef2-4509-8735-72ccb373c464'
)

if status_code < 300:
    print(doc)

Sample Response

{u'status': u'ACTIVE', u'sku': u'082011500001', u'name': u'Apple Pie', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 300}, u'updatedAt': u'2017-01-04T22:04:34Z', u'shortCode': u'ApPie', u'id': u'0cb54922-0ef2-4509-8735-72ccb373c464', u'createdAt': u'2017-01-04T22:04:34Z', u'description': u'Apple Pie'}

Get By Id

Get a business product by id.

Arguments

businessId path
string (required)
If-Modified-Since header
string (optional)
productId path
string (required)

Response

Returns a Product.


Definition

PATCH /businesses/{businessId}/products/{productId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.updateProduct = function updateProduct(options, productOrPatch, next) { ... }
/**
 * Updates a product by ID. Can either specify the whole product, or an array
 * of JSON Patch instructions.
 * @param {String} options.businessId - the business ID
 * @param {String} options.productId - the product ID
 * @param {Boolean} options.noRemove - don't remove any keys from old product in
 *                                     the patch. safer this way. defaults to true
 * @param {Object} productOrPatch - if is an array, will treat as JSON patch;
 *                                  if object, will treat as product
 * @return {Product} product
 */

Sample Request

poynt.updateProduct({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  productId  : '0cb54922-0ef2-4509-8735-72ccb373c464'
}, {
  price : {
    currency : 'USD',
    amount   : 600
  }
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-01-04T22:04:34Z",
  "description": "Apple Pie",
  "id": "0cb54922-0ef2-4509-8735-72ccb373c464",
  "name": "Apple Pie",
  "price": {
    "amount": 600,
    "currency": "USD"
  },
  "shortCode": "ApPie",
  "sku": "082011500001",
  "status": "ACTIVE",
  "type": "SIMPLE",
  "updatedAt": "2017-08-28T07:35:51Z"
}

Definition

@classmethod
def update_product(cls, business_id, product_id, product=None, patch=None, no_remove=True):
"""
Updates a product by ID. Can either specify the whole product, or an array
of JSON Patch instructions.

Arguments:
business_id (str): the business ID
product_id (str): the product ID

Keyword arguments:
product (dict): the full product object
patch (list of dict): JSON Patch update instructions
no_remove (boolean, optional): don't remove any keys from old product in the patch.
                               safer this way. defaults to True
"""

Sample Request

doc, status_code = poynt.Product.update_product(
  '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  '0cb54922-0ef2-4509-8735-72ccb373c464',
  product={
    'price': {
        'currency': 'USD',
        'amount': 600
    }
  }
)

if status_code < 300:
    print(doc)

Sample Response

{u'status': u'ACTIVE', u'sku': u'082011500001', u'name': u'Apple Pie', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 600}, u'updatedAt': u'2017-08-28T07:36:15Z', u'shortCode': u'ApPie', u'id': u'0cb54922-0ef2-4509-8735-72ccb373c464', u'createdAt': u'2017-01-04T22:04:34Z', u'description': u'Apple Pie'}

Update By Id

Update a product by id.

Arguments

businessId path
string (required)
productId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Product.


Definition

PUT /businesses/{businessId}/products/{productId}/variants

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Upsert variant

Upsert a variant of a product, retaining its inventory, if any.

Arguments

businessId path
string (required)
productId path
string (required)
variant body
Variant (optional)

Response

Returns a Variant.


Definition

GET /businesses/{businessId}/products/{productId}/variants

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Get all variants

Get all variants of this product.

Arguments

businessId path
string (required)
productId path
string (required)

Response

Returns a array.


Definition

DELETE /businesses/{businessId}/products/{productId}/variants/{sku}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Delete variant

Delete a variant of a product

Arguments

businessId path
string (required)
productId path
string (required)
sku path
string (required)

Catalogs

A catalog is a complete list of products for sale by the merchant. Catalog can contain products and/or categories of products organized in a hierarchy. Catalogs, once defined, can be assigned to a store or individual Poynt Terminal.


Definition

GET /businesses/{businessId}/catalogs

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getCatalogs = function getCatalogs(options, next) { ... }
/**
 * Get a list of catalogs
 * @param {String} options.businessId
 * @param {String} options.startAt (optional)
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional)
 * @param {Integer} options.limit (optional)
 * @return {CatalogList} catalogs
 */

Sample Request

poynt.getCatalogs({
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "catalogs": [
    {
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-08-16T04:25:59Z",
      "displayMetadata": [
        {
          "horizontalScroll": "false",
          "numberOfColumns": 4,
          "numberOfRows": 6,
          "optimizedForPackage": "poynt-smart-terminal",
          "verticalScroll": "true"
        }
      ],
      "id": "9deca670-8761-4133-b1a9-b05b9fb01cb6",
      "name": "Leech Catalog",
      "products": [
        {
          "displayOrder": 1,
          "id": "74e9594a-4de0-40dd-a955-af2155dc10e3"
        },
        {
          "displayOrder": 7,
          "id": "8b86b625-b209-44cb-8e3e-c6a09af4e88e"
        },
        {
          "displayOrder": 10,
          "id": "c8bbc0f0-c7ad-4925-8a5e-1ab8eec22fcb"
        },
        {
          "displayOrder": 11,
          "id": "909b0361-79d8-4fd9-a6c7-85391787769e"
        },
        {
          "displayOrder": 12,
          "id": "c77ef1c5-9895-4515-9035-209d579a3af3"
        },
        {
          "displayOrder": 13,
          "id": "54127174-2b69-4cff-ad2d-5893795a12f2"
        },
        {
          "displayOrder": 14,
          "id": "691989f4-e610-4a3f-94b3-3b191fc68d40"
        },
        {
          "displayOrder": 17,
          "id": "6c34a14b-8184-4da4-bb5f-c87c78bdce8e"
        },
        {
          "displayOrder": 18,
          "id": "f77346e8-172d-43d8-9a62-c18ed9b4f787"
        },
        {
          "displayOrder": 23,
          "id": "6eec1971-5eab-4410-b124-27e1356ea6f7"
        }
      ],
      "updatedAt": "2017-08-19T02:28:14Z"
    },
    {
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-08-28T07:41:48Z",
      "id": "3301546f-aa10-404c-8dd2-44894db70f56",
      "name": "Foo catalog",
      "updatedAt": "2017-08-28T07:41:48Z"
    },
    {
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-08-28T07:42:19Z",
      "id": "ee85312d-7449-4003-8222-a22415fdfed9",
      "name": "Foo catalog",
      "updatedAt": "2017-08-28T07:42:19Z"
    }
  ]
}

Definition

@classmethod
def get_catalogs(cls, business_id, start_at=None, start_offset=None,
                 end_at=None, limit=None):
"""
Get all catalogs at a business.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get catalogs created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get catalogs created before this time in seconds
limit (int, optional): how many catalogs to return (for pagination)
"""

Sample Request

doc, status_code = poynt.Catalog.get_catalogs(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb'
)

if status_code < 300:
    print(doc)

Sample Response

{u'catalogs': [{u'name': u'Leech Catalog', u'displayMetadata': [{u'verticalScroll': u'true', u'numberOfColumns': 4, u'optimizedForPackage': u'poynt-smart-terminal', u'horizontalScroll': u'false', u'numberOfRows': 6}], u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'products': [{u'id': u'74e9594a-4de0-40dd-a955-af2155dc10e3', u'displayOrder': 1}, {u'id': u'8b86b625-b209-44cb-8e3e-c6a09af4e88e', u'displayOrder': 7}, {u'id': u'c8bbc0f0-c7ad-4925-8a5e-1ab8eec22fcb', u'displayOrder': 10}, {u'id': u'909b0361-79d8-4fd9-a6c7-85391787769e', u'displayOrder': 11}, {u'id': u'c77ef1c5-9895-4515-9035-209d579a3af3', u'displayOrder': 12}, {u'id': u'54127174-2b69-4cff-ad2d-5893795a12f2', u'displayOrder': 13}, {u'id': u'691989f4-e610-4a3f-94b3-3b191fc68d40', u'displayOrder': 14}, {u'id': u'6c34a14b-8184-4da4-bb5f-c87c78bdce8e', u'displayOrder': 17}, {u'id': u'f77346e8-172d-43d8-9a62-c18ed9b4f787', u'displayOrder': 18}, {u'id': u'6eec1971-5eab-4410-b124-27e1356ea6f7', u'displayOrder': 23}], u'updatedAt': u'2017-08-19T02:28:14Z', u'id': u'9deca670-8761-4133-b1a9-b05b9fb01cb6', u'createdAt': u'2017-08-16T04:25:59Z'}, {u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'id': u'3301546f-aa10-404c-8dd2-44894db70f56', u'createdAt': u'2017-08-28T07:41:48Z', u'updatedAt': u'2017-08-28T07:41:48Z'}, {u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'id': u'ee85312d-7449-4003-8222-a22415fdfed9', u'createdAt': u'2017-08-28T07:42:19Z', u'updatedAt': u'2017-08-28T07:42:19Z'}]}

Get List

Get all catalog since time. Result is paginated

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId path
string (required)

Response

Returns a CatalogList.


Definition

GET /businesses/{businessId}/catalogs/{catalogId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getCatalog = function getCatalog(options, next) { ... }
/**
 * Get a single catalog for a business.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @return {Catalog} catalog
 */

Sample Request

poynt.getCatalog({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T07:47:14Z",
  "id": "365febc2-28b6-411e-85d7-7a57f72ff597",
  "name": "Foo catalog",
  "products": [
    {
      "displayOrder": 1,
      "id": "74c89006-ea3c-4c28-8a13-408b77cbe16c"
    }
  ],
  "updatedAt": "2017-08-28T07:47:14Z"
}

Definition

@classmethod
def get_catalog(cls, business_id, catalog_id):
"""
Get a single catalog for a business.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
"""

Sample Request

doc, status_code = poynt.Catalog.get_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597'
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'products': [{u'id': u'74c89006-ea3c-4c28-8a13-408b77cbe16c', u'displayOrder': 1}], u'updatedAt': u'2017-08-28T07:47:14Z', u'id': u'365febc2-28b6-411e-85d7-7a57f72ff597', u'createdAt': u'2017-08-28T07:47:14Z'}

Get By Id

Get a catalog by id.

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
catalogId path
string (required)

Response

Returns a Catalog.


Definition

GET /businesses/{businessId}/catalogs/{catalogId}/full

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getFullCatalog = function getFullCatalog(options, next) { ... }
/**
 * Get a catalog by id with all product details info embedded in the Catalog.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @return {Catalog} catalog
 */

Sample Request

poynt.getFullCatalog({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "categories": [
    {
      "id": "d2c335c9-a771-469f-a0b3-633977aea290",
      "name": "Category 2",
      "shortCode": "Cat"
    }
  ],
  "createdAt": "2017-08-28T07:47:14Z",
  "id": "365febc2-28b6-411e-85d7-7a57f72ff597",
  "name": "Foo catalog",
  "products": [
    {
      "displayOrder": 1,
      "product": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "createdAt": "2017-08-28T07:47:14Z",
        "id": "74c89006-ea3c-4c28-8a13-408b77cbe16c",
        "name": "Foo 2",
        "price": {
          "amount": 600,
          "currency": "USD"
        },
        "shortCode": "Foo2",
        "sku": "Foo2",
        "status": "ACTIVE",
        "type": "SIMPLE",
        "updatedAt": "2017-08-28T07:47:14Z"
      }
    }
  ],
  "updatedAt": "2017-08-28T08:08:35Z"
}

Definition

@classmethod
def get_full_catalog(cls, business_id, catalog_id):
"""
Get a catalog by id with all product details info embedded in
the Catalog.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
"""

Sample Request

doc, status_code = poynt.Catalog.get_full_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597'
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'products': [{u'product': {u'status': u'ACTIVE', u'sku': u'Foo2', u'name': u'Foo 2', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 600}, u'updatedAt': u'2017-08-28T07:47:14Z', u'shortCode': u'Foo2', u'id': u'74c89006-ea3c-4c28-8a13-408b77cbe16c', u'createdAt': u'2017-08-28T07:47:14Z'}, u'displayOrder': 1}], u'createdAt': u'2017-08-28T07:47:14Z', u'updatedAt': u'2017-08-28T08:08:35Z', u'id': u'365febc2-28b6-411e-85d7-7a57f72ff597', u'categories': [{u'shortCode': u'Cat', u'id': u'd2c335c9-a771-469f-a0b3-633977aea290', u'name': u'Category 2'}]}

Get Full Catalog By Id

Get a catalog by id with all product details info embedded in the Catalog.

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
catalogId path
string (required)

Response

Returns a CatalogWithProduct.


Definition

POST /businesses/{businessId}/catalogs

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createCatalog = function createCatalog(options, catalog, next) { ... }
/**
 * Creates a catalog for a business.
 * @param {String} options.businessId
 * @param {Catalog} catalog
 * @return {Catalog} catalog
 */

Sample Request

poynt.createCatalog({
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, {
  name: 'Foo catalog'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T07:42:19Z",
  "id": "ee85312d-7449-4003-8222-a22415fdfed9",
  "name": "Foo catalog",
  "updatedAt": "2017-08-28T07:42:19Z"
}

Definition

@classmethod
def create_catalog(cls, business_id, catalog):
"""
Creates a catalog on a business.

Arguments:
business_id (str): the business ID
catalog (dict): the catalog object
"""

Sample Request

doc, status_code = poynt.Catalog.create_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    {
        'name': 'Foo catalog'
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'id': u'3301546f-aa10-404c-8dd2-44894db70f56', u'createdAt': u'2017-08-28T07:41:48Z', u'updatedAt': u'2017-08-28T07:41:48Z'}

Create

Create a catalog for a business.

Arguments

catalog body
Catalog (optional)
businessId path
string (required)

Response

Returns a Catalog.


Definition

POST /businesses/{businessId}/catalogs/full

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createFullCatalog = function createFullCatalog(options, catalog, next) { ... }
/**
 * Creates a catalog for a business. This differs from createCatalog as you can
 * create products and catalogs at the same time.
 * @param {String} options.businessId
 * @param {Catalog} catalog
 * @return {Catalog} catalog
 */

Sample Request

poynt.createFullCatalog({
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, {
  name: 'Foo catalog',
  products: [{
    product: {
      businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb',
      name: 'Foo 2',
      price: {
        currency: 'USD',
        amount: 600
      },
      sku: 'Foo2',
      shortCode: 'Foo2'
    },
    displayOrder: 1
  }]
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T07:48:28Z",
  "id": "e3e16774-321e-463f-8ed9-8a996094b1d9",
  "name": "Foo catalog",
  "products": [
    {
      "displayOrder": 1,
      "product": {
        "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
        "createdAt": "2017-08-28T07:48:28Z",
        "id": "0968d410-cb86-41a1-838c-c9a868ad0335",
        "name": "Foo 2",
        "price": {
          "amount": 600,
          "currency": "USD"
        },
        "shortCode": "Foo2",
        "sku": "Foo2",
        "status": "ACTIVE",
        "type": "SIMPLE",
        "updatedAt": "2017-08-28T07:48:28Z"
      }
    }
  ],
  "updatedAt": "2017-08-28T07:48:28Z"
}

Definition

@classmethod
def create_full_catalog(cls, business_id, full_catalog):
"""
Creates a catalog on a business with embedded products.
This differs from create_catalog as you can create products
and catalogs at the same time.

Arguments:
business_id (str): the business ID
full_catalog (dict): the full catalog object
"""

Sample Request

doc, status_code = poynt.Catalog.create_full_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    {
        'name': 'Foo catalog',
        'products': [{
            'product': {
                'businessId': '18f071cc-5ed4-4b33-80c1-305056d42bfb',
                'name': 'Foo 2',
                'price': {
                    'currency': 'USD',
                    'amount': 600
                },
                'sku': 'Foo2',
                'shortCode': 'Foo2'
            },
            'displayOrder': 1
        }]
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'products': [{u'product': {u'status': u'ACTIVE', u'sku': u'Foo2', u'name': u'Foo 2', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 600}, u'updatedAt': u'2017-08-28T07:47:14Z', u'shortCode': u'Foo2', u'id': u'74c89006-ea3c-4c28-8a13-408b77cbe16c', u'createdAt': u'2017-08-28T07:47:14Z'}, u'displayOrder': 1}], u'updatedAt': u'2017-08-28T07:47:14Z', u'id': u'365febc2-28b6-411e-85d7-7a57f72ff597', u'createdAt': u'2017-08-28T07:47:14Z'}

Create Full

Create a catalog with all its embedded products.

Arguments

catalog body
CatalogWithProduct (optional)
businessId path
string (required)

Response

Returns a CatalogWithProduct.


Definition

GET /businesses/{businessId}/catalogs/search

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Search Catalog

Search for a catalog by name or device id.

Arguments

businessId path
string (required)
name query
string (optional)
deviceId query
string (optional)

Response

Returns a Catalog.


Definition

PATCH /businesses/{businessId}/catalogs/{catalogId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.updateCatalog = function updateCatalog(options, catalogOrPatch, next) { ... }
/**
 * Updates a catalog by ID. Can either specify the whole catalog, or an array
 * of JSON Patch instructions.
 * @param {String} options.businessId - the business ID
 * @param {String} options.catalogId - the catalog ID
 * @param {Boolean} options.noRemove - don't remove any keys from old catalog in
 *                                     the patch. safer this way. defaults to true
 * @param {Object} catalogOrPatch - if is an array, will treat as JSON patch;
 *                                  if object, will treat as catalog
 * @return {Catalog} catalog
 */

Sample Request

poynt.updateCatalog({
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId: 'e3e16774-321e-463f-8ed9-8a996094b1d9'
}, {
  name: 'New foo catalog'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T07:48:28Z",
  "id": "e3e16774-321e-463f-8ed9-8a996094b1d9",
  "name": "New foo catalog",
  "products": [
    {
      "displayOrder": 1,
      "id": "0968d410-cb86-41a1-838c-c9a868ad0335"
    }
  ],
  "updatedAt": "2017-08-28T07:50:17Z"
}

Definition

@classmethod
def update_catalog(cls, business_id, catalog_id, catalog=None, patch=None, no_remove=True):
"""
Updates a catalog by ID. Can either specify the whole catalog, or an array
of JSON Patch instructions.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID

Keyword arguments:
catalog (dict): the catalog object. this should be a Catalog, not a CatalogWithProduct.
patch (list of dict): JSON Patch update instructions
no_remove (boolean, optional): don't remove any keys from old catalog in the patch.
                               safer this way. defaults to True
"""

Sample Request

doc, status_code = poynt.Catalog.update_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'e3e16774-321e-463f-8ed9-8a996094b1d9',
    catalog={
        'name': 'New foo catalog'
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Foo catalog', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'products': [{u'product': {u'status': u'ACTIVE', u'sku': u'Foo2', u'name': u'Foo 2', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'type': u'SIMPLE', u'price': {u'currency': u'USD', u'amount': 600}, u'updatedAt': u'2017-08-28T07:47:14Z', u'shortCode': u'Foo2', u'id': u'74c89006-ea3c-4c28-8a13-408b77cbe16c', u'createdAt': u'2017-08-28T07:47:14Z'}, u'displayOrder': 1}], u'updatedAt': u'2017-08-28T07:47:14Z', u'id': u'365febc2-28b6-411e-85d7-7a57f72ff597', u'createdAt': u'2017-08-28T07:47:14Z'}

Update catalog

Update a catalog.

Arguments

businessId path
string (required)
catalogId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Catalog.


Definition

DELETE /businesses/{businessId}/catalogs/{catalogId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.deleteCatalog = function deleteCatalog(options, next) { ... }
/**
 * Deletes a single catalog for a business.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 */

Sample Request

poynt.deleteCatalog({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : 'e3e16774-321e-463f-8ed9-8a996094b1d9'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def delete_catalog(cls, business_id, catalog_id):
"""
Deletes a single catalog for a business.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
"""

Sample Request

doc, status_code = poynt.Catalog.delete_catalog(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'e3e16774-321e-463f-8ed9-8a996094b1d9'
)

if status_code < 300:
    print(doc)

Sample Response

None

Delete catalog

Delete a catalog.

Arguments

businessId path
string (required)
catalogId path
string (required)

Definition

POST /businesses/{businessId}/catalogs/{catalogId}/categories

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createCategory = function createCategory(options, category, next) { ... }
/**
 * Creates a category on a catalog for a business.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @param {Category} category
 * @return {Category} category
 */

Sample Request

poynt.createCategory({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597'
}, {
  name      : 'Category',
  shortCode : 'Cat'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "id": "d2c335c9-a771-469f-a0b3-633977aea290",
  "name": "Category",
  "shortCode": "Cat"
}

Definition

@classmethod
def create_category(cls, business_id, catalog_id, category):
"""
Creates a category on a catalog on a business.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
category (dict): the category object
"""

Sample Request

doc, status_code = poynt.Catalog.create_category(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597',
    {
        'name': 'Category',
        'shortCode': 'Cat'
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'shortCode': u'Cat', u'id': u'4ab8a489-a3fc-4124-87f0-91f8b6044407', u'name': u'Category'}

Create category

Create a category for a catalog.

Arguments

businessId path
string (required)
catalogId path
string (required)
category body
Category (optional)

Response

Returns a Category.


Definition

GET /businesses/{businessId}/catalogs/{catalogId}/categories/lookup

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.lookupCategories = function lookupCategories(options, next) { ... }
/**
 * Gets multiple categories on a catalog by IDs.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @param {String[]} options.ids
 * @return {Category[]} categories
 */

Sample Request

poynt.lookupCategories({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597',
  ids        : ['4ab8a489-a3fc-4124-87f0-91f8b6044407']
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "categories": [
    {
      "id": "4ab8a489-a3fc-4124-87f0-91f8b6044407",
      "name": "Category",
      "shortCode": "Cat"
    }
  ]
}

Definition

@classmethod
def lookup_categories(cls, business_id, catalog_id, category_ids):
"""
Gets multiple categories on a catalog by IDs.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
category_ids (list of str): a list of category ids
"""

Sample Request

doc, status_code = poynt.Catalog.lookup_categories(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597',
    ['4ab8a489-a3fc-4124-87f0-91f8b6044407']
)

if status_code < 300:
    print(doc)

Sample Response

{u'categories': [{u'shortCode': u'Cat', u'id': u'4ab8a489-a3fc-4124-87f0-91f8b6044407', u'name': u'Category'}]}

Get Multiple Id

Get multiple category by ids.

Arguments

businessId path
string (required)
catalogId path
string (required)
ids query
string (required)

Response

Returns a CategoryList.


Definition

GET /businesses/{businessId}/catalogs/{catalogId}/categories/{categoryId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getCategory = function getCategory(options, next) { ... }
/**
 * Get a single category in a catalog for a business.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @param {String} options.categoryId
 * @return {Category} category
 */

Sample Request

poynt.getCategory({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597',
  categoryId : '4ab8a489-a3fc-4124-87f0-91f8b6044407'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "id": "4ab8a489-a3fc-4124-87f0-91f8b6044407",
  "name": "Category",
  "shortCode": "Cat"
}

Definition

@classmethod
def get_category(cls, business_id, catalog_id, category_id):
"""
Get a single category in a catalog for a business.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
category_id (str): the category ID
"""

Sample Request

doc, status_code = poynt.Catalog.get_category(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597',
    '4ab8a489-a3fc-4124-87f0-91f8b6044407'
)

if status_code < 300:
    print(doc)

Sample Response

{u'shortCode': u'Cat', u'id': u'4ab8a489-a3fc-4124-87f0-91f8b6044407', u'name': u'Category'}

Get category by id

Getall a category by id.

Arguments

businessId path
string (required)
catalogId path
string (required)
categoryId path
string (required)

Response

Returns a Category.


Definition

DELETE /businesses/{businessId}/catalogs/{catalogId}/categories/{categoryId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.deleteCategory = function deleteCategory(options, next) { ... }
/**
 * Deletes a category by ID.
 * @param {String} options.businessId
 * @param {String} options.catalogId
 * @param {String} options.categoryId
 * @return {Category} category
 */

Sample Request

poynt.deleteCategory({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597',
  categoryId : '4ab8a489-a3fc-4124-87f0-91f8b6044407'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def delete_category(cls, business_id, catalog_id, category_id):
"""
Deletes a category by ID.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
category_id (str): the category ID
"""

Sample Request

doc, status_code = poynt.Catalog.delete_category(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597',
    '4ab8a489-a3fc-4124-87f0-91f8b6044407'
)

if status_code < 300:
    print(doc)

Sample Response

None

Delete category

Delete a category.

Arguments

businessId path
string (required)
catalogId path
string (required)
categoryId path
string (required)

Definition

PATCH /businesses/{businessId}/catalogs/{catalogId}/categories/{categoryId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.updateCategory = function updateCategory(options, categoryOrPatch, next) { ... }
/**
 * Updates a category by ID. Can either specify the whole category, or an array
 * of JSON Patch instructions.
 * @param {String} options.businessId - the business ID
 * @param {String} options.catalogId - the catalog ID
 * @param {String} options.categoryId - the category ID
 * @param {Boolean} options.noRemove - don't remove any keys from old category in
 *                                     the patch. safer this way. defaults to true
 * @param {Object} categoryOrPatch - if is an array, will treat as JSON patch;
 *                                   if object, will treat as category
 * @return {Category} category
 */

Sample Request

poynt.updateCategory({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  catalogId  : '365febc2-28b6-411e-85d7-7a57f72ff597',
  categoryId : 'd2c335c9-a771-469f-a0b3-633977aea290'
}, {
  name : 'Category 2'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "id": "d2c335c9-a771-469f-a0b3-633977aea290",
  "name": "Category 2",
  "shortCode": "Cat"
}

Definition

@classmethod
def update_category(cls, business_id, catalog_id, category_id, category=None, patch=None, no_remove=True):
"""
Updates a category by ID. Can either specify the whole category, or an array
of JSON Patch instructions.

Arguments:
business_id (str): the business ID
catalog_id (str): the catalog ID
category_id (str): the category ID

Keyword arguments:
category (dict): the category object
patch (list of dict): JSON Patch update instructions
no_remove (boolean, optional): don't remove any keys from old category in the patch.
                               safer this way. defaults to True
"""

Sample Request

doc, status_code = poynt.Catalog.update_category(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    '365febc2-28b6-411e-85d7-7a57f72ff597',
    'd2c335c9-a771-469f-a0b3-633977aea290',
    category={
        'name': 'Category 2'
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'shortCode': u'Cat', u'id': u'd2c335c9-a771-469f-a0b3-633977aea290', u'name': u'Category 2'}

Update category

Update a category.

Arguments

businessId path
string (required)
catalogId path
string (required)
categoryId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Category.


Taxes

Merchants must collect appropriate taxes based on the location their business and the products they sell. A tax, once defined, can be associated at the catalog, category, or individual product level.


Definition

GET /businesses/{businessId}/taxes

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getTaxes = function getTaxes(options, next) { ... }
/**
 * Get a list of taxes
 * @param {String} options.businessId
 * @param {String} options.startAt (optional)
 * @param {Integer} options.startOffset (optional)
 * @param {String} options.endAt (optional)
 * @param {Integer} options.limit (optional)
 * @return {TaxList} taxes
 */

Sample Request

poynt.getTaxes({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  startOffset : 0,
  limit       : 1
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "links": [
    {
      "href": "/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/taxes?startAt=2017-07-28T17%3A31%3A38Z&endAt=2017-08-28T08%3A09%3A46Z&limit=1",
      "method": "GET",
      "rel": "next"
    }
  ],
  "taxes": [
    {
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-04-05T00:18:39Z",
      "id": "0f60100b-5332-44b3-9e40-8cb3106be1bc",
      "name": "CF Sales",
      "rate": 8.25,
      "type": "sales",
      "updatedAt": "2017-04-05T00:18:39Z"
    }
  ]
}

Definition

@classmethod
def get_taxes(cls, business_id, start_at=None, start_offset=None,
              end_at=None, limit=None):
"""
Get a list of taxes at a business.

Arguments:
business_id (str): the business ID

Keyword arguments:
start_at (int, optional): get taxes created after this time in seconds
start_offset (int, optional): the numeric offset to start the list (for pagination)
end_at (int, optional): get taxes created before this time in seconds
limit (int, optional): how many taxes to return (for pagination)
"""

Sample Request

doc, status_code = poynt.Tax.get_taxes(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    start_offset=0,
    limit=1
)

if status_code < 300:
    print(doc)

Sample Response

{u'taxes': [{u'name': u'CF Sales', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'rate': 8.25, u'updatedAt': u'2017-04-05T00:18:39Z', u'type': u'sales', u'id': u'0f60100b-5332-44b3-9e40-8cb3106be1bc', u'createdAt': u'2017-04-05T00:18:39Z'}], u'links': [{u'href': u'/businesses/18f071cc-5ed4-4b33-80c1-305056d42bfb/taxes?startAt=2017-07-28T17%3A31%3A38Z&endAt=2017-08-28T08%3A10%3A24Z&limit=1', u'method': u'GET', u'rel': u'next'}]}

Get List

Get all tax rate for this business.

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId path
string (required)

Response

Returns a TaxList.


Definition

POST /businesses/{businessId}/taxes

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createTax = function createTax(options, tax, next) { ... }
/**
 * Creates a tax on a business.
 * @param {String} options.businessId
 * @param {Tax} tax
 * @return {Tax} tax
 */

Sample Request

poynt.createTax({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, {
  businessId: '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  name: 'Sales tax',
  description: 'California sales tax',
  type: 'SALES',
  rate: 8.25
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T08:13:02Z",
  "description": "California sales tax",
  "id": "a0e9a94f-5821-4511-8966-7f8ca3c42167",
  "name": "Sales tax",
  "rate": 8.25,
  "type": "SALES",
  "updatedAt": "2017-08-28T08:13:02Z"
}

Definition

@classmethod
def create_tax(cls, business_id, tax):
"""
Creates a tax on a business.

Arguments:
business_id (str): the business ID
tax (dict): the full tax object
"""

Sample Request

doc, status_code = poynt.Tax.create_tax(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    {
        'businessId': '18f071cc-5ed4-4b33-80c1-305056d42bfb',
        'name': 'Sales tax',
        'description': 'California sales tax',
        'type': 'SALES',
        'rate': 8.25
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Sales tax', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'rate': 8.25, u'updatedAt': u'2017-08-28T08:12:19Z', u'type': u'SALES', u'id': u'de581e36-fd76-433d-b104-416978d8d01b', u'createdAt': u'2017-08-28T08:12:19Z', u'description': u'California sales tax'}

Create

Create a tax rate definition for a business.

Arguments

businessId path
string (required)
tax body
Tax (optional)

Response

Returns a Tax.


Definition

DELETE /businesses/{businessId}/taxes/{taxId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.deleteTax = function deleteTax(options, next) { ... }
/**
 * Deactivates a tax. Deactivated taxes will be removed from all catalog
 * references.
 * @param {String} options.businessId
 * @param {String} options.taxId
 * @return {Tax} tax
 */

Sample Request

poynt.deleteTax({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  taxId      : 'a0e9a94f-5821-4511-8966-7f8ca3c42167'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def delete_tax(cls, business_id, tax_id):
"""
Deletes a tax.

Arguments:
business_id (str): the business ID
tax_id (str): the tax ID
"""

Sample Request

doc, status_code = poynt.Tax.delete_tax(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'a0e9a94f-5821-4511-8966-7f8ca3c42167'
)

if status_code < 300:
    print(doc)

Sample Response

None

Delete tax

Delete a tax.

Arguments

businessId path
string (required)
taxId path
string (required)

Definition

GET /businesses/{businessId}/taxes/{taxId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getTax = function getTax(options, next) { ... }
/**
 * Get a single tax for a business.
 * @param {String} options.businessId
 * @param {String} options.taxId
 * @return {Tax} tax
 */

Sample Request

poynt.getTax({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  taxId      : 'de581e36-fd76-433d-b104-416978d8d01b'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T08:12:19Z",
  "description": "California sales tax",
  "id": "de581e36-fd76-433d-b104-416978d8d01b",
  "name": "Sales tax",
  "rate": 8.25,
  "type": "SALES",
  "updatedAt": "2017-08-28T08:12:19Z"
}

Definition

@classmethod
def get_tax(cls, business_id, tax_id):
"""
Get a single tax for a business.

Arguments:
business_id (str): the business ID
tax_id (str): the tax ID
"""

Sample Request

doc, status_code = poynt.Tax.get_tax(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'de581e36-fd76-433d-b104-416978d8d01b'
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Sales tax', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'rate': 8.25, u'updatedAt': u'2017-08-28T08:12:19Z', u'type': u'SALES', u'id': u'de581e36-fd76-433d-b104-416978d8d01b', u'createdAt': u'2017-08-28T08:12:19Z', u'description': u'California sales tax'}

Get

Get a tax rate detail.

Arguments

If-Modified-Since header
string (optional)
businessId path
string (required)
taxId path
string (required)

Response

Returns a Tax.


Definition

PATCH /businesses/{businessId}/taxes/{taxId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.updateTax = function updateTax(options, taxOrPatch, next) { ... }
/**
 * Updates a tax by ID. Can either specify the whole tax, or an array
 * of JSON Patch instructions.
 * @param {String} options.businessId - the business ID
 * @param {String} options.taxId - the tax ID
 * @param {Boolean} options.noRemove - don't remove any keys from old tax in
 *                                     the patch. safer this way. defaults to true
 * @param {Object} taxOrPatch - if is an array, will treat as JSON patch;
 *                              if object, will treat as tax
 * @return {Tax} tax
 */

Sample Request

poynt.updateTax({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  taxId      : 'de581e36-fd76-433d-b104-416978d8d01b'
}, {
  name : 'New sales tax',
  rate : 8.3
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "createdAt": "2017-08-28T08:12:19Z",
  "updatedAt": "2017-08-28T08:17:47Z",
  "rate": 8.3,
  "id": "de581e36-fd76-433d-b104-416978d8d01b",
  "name": "New sales tax",
  "description": "California sales tax",
  "type": "SALES",
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb"
}

Definition

@classmethod
def update_tax(cls, business_id, tax_id, tax=None, patch=None, no_remove=True):
"""
Updates a tax by ID. Can either specify the whole tax, or an array
of JSON Patch instructions.

Arguments:
business_id (str): the business ID
tax_id (str): the tax ID

Keyword arguments:
tax (dict): the full tax object
patch (list of dict): JSON Patch update instructions
no_remove (boolean, optional): don't remove any keys from old tax in the patch.
                               safer this way. defaults to True
"""

Sample Request

doc, status_code = poynt.Tax.update_tax(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'de581e36-fd76-433d-b104-416978d8d01b',
    tax={
        'name': 'New sales tax',
        'rate': 8.3
    }
)

if status_code < 300:
    print(doc)

Sample Response

{u'name': u'Sales tax', u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'rate': 8.25, u'updatedAt': u'2017-08-28T08:12:19Z', u'type': u'SALES', u'id': u'de581e36-fd76-433d-b104-416978d8d01b', u'createdAt': u'2017-08-28T08:12:19Z', u'description': u'California sales tax'}

Update

Update tax details.

Arguments

businessId path
string (required)
taxId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Tax.


Receipt Template

This class contains receipt templates resources. It can be used to perform various operations on a receipt template. For example we can store customer transaction receipt template from this resource. Currently we support only Handlebar templates https://github.com/jknack/handlebars.java. The template context will have following objects available: * transaction * business * customerSignatureUrl Once you are ready with the Handlebar template follow these final steps for better results: * JSON encode the template * Put inline CSS to support the final html receipt in all major Email clients.


Definition

POST /business/{businessId}/transactions/receipt-template

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Upsert receipt template

Update or insert a receipt template.

Arguments

businessId path
string (required)
Poynt-Request-Id header
string (required)
receiptTemplate body
ReceiptTemplate (optional)

Response

Returns a ReceiptTemplate.


Notifications

Cloud Messages can be sent from the cloud applications running on the Poynt Smart Terminal.

Webhooks allow developers to register their application to receive callback events from Poynt or replay missed events.

To register for an event type, the developer can create a hook specifying the business and event type they would like to receive callbacks on. This can be done programmatically or via our developer portal UI.

When an event matching the criterias defined in a hook happens, a delivery is made to the developer application endpoint. Webhook deliveries can be redelivered or lookup based on time range as needed.


Cloudmessages

A message sent from the cloud through the Poynt Cloud Messaging to applications running on the Poynt Smart Terminal.


Definition

POST /cloudMessages

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.sendCloudMessage = function sendCloudMessage(options, next) { ... }
/**
 * Send a message from the cloud to your application running at a Poynt terminal.
 * @param {String} options.businessId
 * @param {String} options.storeId
 * @param {String} options.recipientClassName
 * @param {String} options.recipientPackageName
 * @param {String} options.deviceId
 * @param {String} options.serialNumber
 * @param {String} options.data (optional) - defaults to "{}"
 * @param {String} options.ttl (optional) - defaults to 900 seconds or 15 min
 * @param {String} options.collapseKey (optional)
 */

Sample Request

poynt.sendCloudMessage({
  businessId           : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  storeId              : 'c394627f-4f68-47fb-90a5-684ea801a352',
  deviceId             : 'urn:tid:48c54303-6d51-39af-bdeb-4af53f621652',
  recipientClassName   : 'FooClass',
  recipientPackageName : 'co.poynt.testapp',
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def send_cloud_message(cls, business_id=None, store_id=None,
                       class_name=None, package_name=None, device_id=None,
                       serial_number=None, data='{}', collapse_key=None,
                       ttl=900):
"""
Send a message from the cloud to your application running at a Poynt terminal.

Keyword arguments:
business_id (str): the business ID
store_id (str): the store ID
class_name (str): the class name of the receiver in your app
package_name (str): the package name of your app
device_id (str): the device ID
serial_number (str): the serial number
data (str, optional): the data to send. defaults to {}
collapse_key (str, optional): dedupe messages on this key
ttl (int, optional): how long until the cloud message expires. defaults
                     to 900 seconds
"""

Sample Request

doc, status_code = poynt.CloudMessage.send_cloud_message(
    business_id='18f071cc-5ed4-4b33-80c1-305056d42bfb',
    store_id='c394627f-4f68-47fb-90a5-684ea801a352',
    device_id='urn:tid:48c54303-6d51-39af-bdeb-4af53f621652',
    class_name='foo',
    package_name='co.poynt.testapp',
)

if status_code < 300:
    print(doc)

Sample Response

None

Send cloud message

Send a message from the cloud to your application running at a Poynt terminal.

Arguments

message body
CloudMessage (optional)

Hooks

A hook represent an application’s registration to be notified should a particular resource event occurs.


Definition

POST /hooks

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.createHook = function createHook(options, next) { ... }
/**
 * Subscribes to a webhook.
 * @param {String} options.eventType
 * @param {String[]} options.eventTypes
 * @param {String} options.businessId
 * @param {String} options.deliveryUrl
 * @param {String} options.secret
 */

Sample Request

poynt.createHook({
  businessId  : '18f071cc-5ed4-4b33-80c1-305056d42bfb',
  eventTypes  : ['TRANSACTION_AUTHORIZED', 'TRANSACTION_CAPTURED', 'TRANSACTION_REFUNDED', 'TRANSACTION_UPDATED', 'TRANSACTION_VOIDED'],
  deliveryUrl : 'https://poynt.com/hooks',
  secret      : 'poynt123'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "active": true,
  "applicationId": "urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a",
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T08:25:46Z",
  "deliveryUrl": "https://poynt.com/hooks",
  "eventTypes": [
    "TRANSACTION_AUTHORIZED",
    "TRANSACTION_CAPTURED",
    "TRANSACTION_REFUNDED",
    "TRANSACTION_UPDATED",
    "TRANSACTION_VOIDED"
  ],
  "id": "4852ebb4-36bf-4060-9ed4-1c3150ddfab6",
  "secret": "********",
  "updatedAt": "2017-08-28T08:25:46Z"
}

Definition

@classmethod
def create_hook(cls, business_id, delivery_url, secret=None, event_type=None,
                event_types=None):
"""
Subscribes to a webhook.

Arguments:
business_id (str): the business ID to subscribe to a hook for. Use a merchant
                   business ID to subscribe to their e.g. transaction hooks;
                   use your own organization ID to subscribe to app billing, etc.
delivery_url (str): the URL to deliver webhooks to.

Keyword arguments:
secret (str, optional): used to sign the webhook event, so you can verify.
event_type (str, optional): a single event type to subscribe to webhooks for.
event_types (list of str, optional): a list of event types to subscribe to webhooks for.
"""

Sample Request

doc, status_code = poynt.Hook.create_hook(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb',
    'https://poynt.com/hooks',
    secret='poynt123',
    event_types=['TRANSACTION_AUTHORIZED', 'TRANSACTION_CAPTURED',
                 'TRANSACTION_REFUNDED', 'TRANSACTION_UPDATED', 'TRANSACTION_VOIDED']
)

if status_code < 300:
    print(doc)

Sample Response

{u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'deliveryUrl': u'https://poynt.com/hooks', u'secret': u'********', u'updatedAt': u'2017-08-28T08:28:55Z', u'active': True, u'eventTypes': [u'TRANSACTION_AUTHORIZED', u'TRANSACTION_CAPTURED', u'TRANSACTION_REFUNDED', u'TRANSACTION_UPDATED', u'TRANSACTION_VOIDED'], u'applicationId': u'urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a', u'id': u'0f9bc70f-1de4-4cb7-83a5-248fc358ad56', u'createdAt': u'2017-08-28T08:28:55Z'}

Create

Create a web hook. Client application MUST have already have been authorized by the business to access the resource of the events in this hook. The following webhooks event are available:

Arguments

hook body
Hook (optional)

Response

Returns a Hook.


Definition

GET /hooks

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getHooks = function getHooks(options, next) { ... }
/**
 * Gets a list of hooks currently subscribed to.
 * @param {String} options.businessId
 */

Sample Request

poynt.getHooks({
  businessId : '18f071cc-5ed4-4b33-80c1-305056d42bfb'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "hooks": [
    {
      "active": true,
      "applicationId": "urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a",
      "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
      "createdAt": "2017-08-28T08:25:46Z",
      "deliveryUrl": "https://poynt.com/hooks",
      "eventTypes": [
        "TRANSACTION_AUTHORIZED",
        "TRANSACTION_CAPTURED",
        "TRANSACTION_REFUNDED",
        "TRANSACTION_UPDATED",
        "TRANSACTION_VOIDED"
      ],
      "id": "4852ebb4-36bf-4060-9ed4-1c3150ddfab6",
      "secret": "********",
      "updatedAt": "2017-08-28T08:25:46Z"
    }
  ]
}

Definition

@classmethod
def get_hooks(cls, business_id):
"""
Gets a list of hooks currently subscribed to.

Arguments:
business_id (str): use a merchant business ID to see what webhooks your app
                   is subscribed to for that merchant. use your own organization
                   ID to see your app billing webhooks, etc.
"""

Sample Request

doc, status_code = poynt.Hook.get_hooks(
    '18f071cc-5ed4-4b33-80c1-305056d42bfb'
)

if status_code < 300:
    print(doc)

Sample Response

{u'hooks': [{u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'deliveryUrl': u'https://poynt.com/hooks', u'secret': u'********', u'updatedAt': u'2017-08-28T08:25:46Z', u'active': True, u'eventTypes': [u'TRANSACTION_AUTHORIZED', u'TRANSACTION_CAPTURED', u'TRANSACTION_REFUNDED', u'TRANSACTION_UPDATED', u'TRANSACTION_VOIDED'], u'applicationId': u'urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a', u'id': u'4852ebb4-36bf-4060-9ed4-1c3150ddfab6', u'createdAt': u'2017-08-28T08:25:46Z'}]}

Get List

Get all webhooks since time. Result is paginated

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId query
string (required)

Response

Returns a HookList.


Definition

PATCH /hooks/{hookId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Update a hook

Update a hook

Arguments

hookId path
string (required)
patch body
JsonPatch (optional)

Response

Returns a Hook.


Definition

DELETE /hooks/{hookId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.deleteHook = function deleteHook(options, next) { ... }
/**
 * Deletes a hook.
 * @param {String} options.hookId
 */

Sample Request

poynt.deleteHook({
  hookId : '0f9bc70f-1de4-4cb7-83a5-248fc358ad56'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{}

Definition

@classmethod
def delete_hook(cls, hook_id):
"""
Deletes a hook.

Arguments:
hook_id (str): hook ID
"""

Sample Request

doc, status_code = poynt.Hook.delete_hook(
    '0f9bc70f-1de4-4cb7-83a5-248fc358ad56'
)

if status_code < 300:
    print(doc)

Sample Response

None

Delete hook

Delete a hook.

Arguments

hookId path
string (required)

Definition

GET /hooks/{hookId}

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

module.exports.getHook = function getHook(options, next) { ... }
/**
 * Gets a hook by ID.
 * @param {String} options.hookId
 */

Sample Request

poynt.getHook({
  hookId : '0f9bc70f-1de4-4cb7-83a5-248fc358ad56'
}, function (err, doc) {
  if (err) {
    throw err;
  }
  console.log(JSON.stringify(doc));
});

Sample Response

{
  "active": true,
  "applicationId": "urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a",
  "businessId": "18f071cc-5ed4-4b33-80c1-305056d42bfb",
  "createdAt": "2017-08-28T08:28:55Z",
  "deliveryUrl": "https://poynt.com/hooks",
  "eventTypes": [
    "TRANSACTION_AUTHORIZED",
    "TRANSACTION_CAPTURED",
    "TRANSACTION_REFUNDED",
    "TRANSACTION_UPDATED",
    "TRANSACTION_VOIDED"
  ],
  "id": "0f9bc70f-1de4-4cb7-83a5-248fc358ad56",
  "secret": "********",
  "updatedAt": "2017-08-28T08:28:55Z"
}

Definition

@classmethod
def get_hook(cls, hook_id):
"""
Gets a hook by ID.

Arguments:
hook_id (str): hook ID
"""

Sample Request

doc, status_code = poynt.Hook.get_hook(
    '0f9bc70f-1de4-4cb7-83a5-248fc358ad56'
)

if status_code < 300:
    print(doc)

Sample Response

{u'businessId': u'18f071cc-5ed4-4b33-80c1-305056d42bfb', u'deliveryUrl': u'https://poynt.com/hooks', u'secret': u'********', u'updatedAt': u'2017-08-28T08:28:55Z', u'active': True, u'eventTypes': [u'TRANSACTION_AUTHORIZED', u'TRANSACTION_CAPTURED', u'TRANSACTION_REFUNDED', u'TRANSACTION_UPDATED', u'TRANSACTION_VOIDED'], u'applicationId': u'urn:aid:cb2c55f6-7dfe-482e-a6da-e27c683edf0a', u'id': u'0f9bc70f-1de4-4cb7-83a5-248fc358ad56', u'createdAt': u'2017-08-28T08:28:55Z'}

Get By Id

Get a hook by id.

Arguments

If-Modified-Since header
string (optional)
hookId path
string (required)

Response

Returns a Hook.


Delivery

When a event occurs which matches the registered Hooks of an application, a delivery is made to the registered delivery url. Delivery are attempted up to 10 times with exponential backoff should there be a failure reaching the delivery url.


Definition

GET /businesses/{businessId}/deliveries

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Get List

Get all webhook delivery since time. Result is paginated

Arguments

If-Modified-Since header
string (optional)
startAt query
string (optional)
startOffset query
integer (optional)
endAt query
string (optional)
limit query
integer (optional)
businessId path
string (required)

Response

Returns a DeliveryList.


Definition

POST /businesses/{businessId}/deliveries/redeliver

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Redeliver By Time

Redeliver all webhook within a time window.

Arguments

businessId path
string (required)
Poynt-Request-Id header
string (optional)
startTime query
string (required)
endTime query
string (required)

Definition

POST /businesses/{businessId}/deliveries/{deliveryId}/redeliver

Sample Request

TODO: Add request

Sample Response

TODO: Add response

Definition

This method is currently not possible using the Node.js SDK.

Definition

This method is currently not possible using the Python SDK.

Redeliver Event

Redeliver a webhook delivery.

Arguments

businessId path
string (required)
deliveryId path
string (required)

Response

Returns a Delivery.


AVSResult

Attributes

addressResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
postalCodeResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
stateResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
countryResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
phoneResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
cardHolderNameResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
cityResult
string, enum['MATCH', 'NO_MATCH', 'PARTIAL_MATCH', 'NOT_PROVIDED', 'ISSUER_NOT_CERTIFIED', 'NO_RESPONSE_FROM_CARD_ASSOCIATION', 'UNKNOWN_RESPONSE_FROM_CARD_ASSOCIATION', 'NOT_VERIFIED', 'BAD_FORMAT', 'ERROR', 'UNSUPPORTED_BY_ISSUER', 'UNAVAILABLE', 'ADDRESS_AND_ZIP_MATCH']
actualResult
string

ActiveTime

Attributes

startHour
integer
startAt
string
The time in ISO-8601 format. E.g. 2014-09-11T23:14:44Z.
endAt
string
The time in ISO-8601 format. E.g. 2014-09-11T23:14:44Z.
repeatType
string, enum['DAILY', 'WEEKLY', 'MONTHLY']
every
array [long]
endHour
integer

Address

Attributes

line1
string
line2
string
city
string
territory
string
postalCode
string
createdAt
string
The time (in ISO-8601 format) at which the address was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the address was updated. E.g. 2014-09-11T23:14:44Z.
countryCode
string
postalCodeExtension
string
territoryType
string, enum['STATE', 'PROVINCE', 'OTHER']
TerritoryType enum and territory go hand in hand. This enum specifies what kind of territory is in the territory field. E.g. in the US, this will typically be STATE.
status
string, enum['ADDED']
id
integer
type
string, enum['HOME', 'WORK', 'BUSINESS', 'TRANSACTION', 'OTHER']

AdjustedDiscount

This is the object to track discount modifications.

Attributes

amount
integer
The change in the amount of discount.
customName
string
The name of discount being modified.
adjustmentType
string, enum['ADDED', 'REMOVED', 'MODIFIED']
The type of adjustment. can be one of ADDED, REMOVED or MODIFIED
id
string
A integer Id of the discount.

AdjustedFee

This is the object to track fee modifications.

Attributes

amount
integer
The amount of fee change.
idStr
string
A string Id to identify the fee.
adjustmentType
string, enum['ADDED', 'REMOVED', 'MODIFIED']
The type of adjustment. can be one of ADDED, REMOVED or MODIFIED
name
string
The name of fee being modified.
id
integer

AdjustedOrder

This is the object to track order modifications.

Attributes

adjustedDiscounts
array [AdjustedDiscount]
Order level discount modifications.
adjustedFees
array [AdjustedFee]
Order level fee changes.
adjustedOrderItems
array [AdjustedOrderItem]
A list of items that were modified.

AdjustedOrderItem

This is the object to track Order item modifications.

Attributes

quantity
float
The quantity of items adjusted.
unitPrice
integer
The unit price per unit.
adjustmentType
string, enum['ADDED', 'REMOVED', 'MODIFIED']
The type of adjustment. can be one of ADDED, REMOVED or MODIFIED.
adjustedDiscounts
array [AdjustedDiscount]
The discount adjustment on the item.
adjustedOrderItemTaxes
array [AdjustedOrderItemTax]
The item tax adjustment on the order item.
adjustedVariants
array [AdjustedVariant]
Any change in the variants for the item can be tracked here.
adjustedFees
array [AdjustedFee]
The fee adjustment on the item.
name
string
The name of item being modified.
id
integer
A integer Id of the item.

AdjustedOrderItemTax

This is the object to track order item tax modifications.

Attributes

amount
integer
The change in the amount of tax.
amountPrecision
integer
The precision on the amount of tax.
adjustmentType
string, enum['ADDED', 'REMOVED', 'MODIFIED']
The type of adjustment. can be one of ADDED, REMOVED or MODIFIED
id
string
A integer Id of the item tax.

AdjustedVariant

This is the object to track any variant changes to item.

Attributes

amount
integer
The delta value of amount change.
adjustmentType
string, enum['ADDED', 'REMOVED', 'MODIFIED']
The type of adjustment. can be one of ADDED, REMOVED or MODIFIED
attribute
string
The name of attribute being modified.
value
string
The change in value of the attribute.

AdjustmentRecord

This object shows a summary of the adjustment.

Attributes

createdAt
string
This is a response field. The server time (in ISO-8601 format) at which this transaction was initially created. E.g. 2014-09-11T23:14:44Z.
processorResponse
ProcessorResponse
This object includes some important response elements received from the processor.
amounts
TransactionAmounts
Total amount after this adjustment.
exchangeRate
ExchangeRate
Exchange rate used for this adjustment.
amountChanges
TransactionAmounts
Total amount change in this adjustment.
reason
TransactionReason
Reason for this adjustment.
sequence
integer
This field indicates the sequence in which this AdjustmentRecord happened in the adjustment history.
signature
array [byte]

AdjustTransactionRequest

This is the object for adjusting transaction resources. It can be used to update a given transaction in the Poynt system with amounts, signature, receipt email/phone, emv data, etc..

Attributes

references
array [TransactionReference]
signature
array [byte]
emvData
EMVData
notes
string
receiptEmailAddress
string
receiptPhone
Phone
customerLanguage
string
amounts
TransactionAmounts
reason
TransactionReason
adjustmentUpdates
array [AdjustmentRecord]
context
ClientContext

ApplePayRegisterMerchantRequest

The request object for registering merchant for Apple Pay.

Attributes

merchantName
string
domainNames
array [string]
merchantUrl
string

ApplePayUnregisterMerchantRequest

The request object for unregistering merchant for Apple Pay.

Attributes

reason
string
domainNames
array [string]

AvailableDiscount

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
fixed
integer
percentage
float
when
ActiveTime
scope
string, enum['ITEM', 'ORDER']
code
string
id
string
type
string, enum['FIXED', 'PERCENTAGE']

BankAccount

This object represents BankAccount.

Attributes

accountNumber
string
accountType
string, enum['CHECKING', 'SAVINGS']
Enum: CHECKING, SAVINGS.
accountNumberLastFour
string
routingNumber
string
bankName
string
ownerName
string
The owner name of bank account.
currency
string
id
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
country
string

Business

This is the base object for the businesses resource. Businesses resource represents a merchant business.

Attributes

createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
mcc
string
[Required] The merchant category code of the business.
processor
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']
acquirer
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']
[Required] The acquirer that this business belongs to.
echeckProcessor
string, enum['MOCK', 'CHECK_COMMERCE']
eCheck(electronic payment funded by the buyer’s bank account) processor used by the business.
timezone
string
[Required] The timezone that the headquarters belong to.
logoUrl
string
The business’ main logo url.
mockProcessor
boolean
processorData
object
emailAddress
string
The main business email address.
subscribedBundles
array [BundledFeatures]
The list of bundles this business has subscribed to.
stores
array [Store]
The list of stores within this business.
closedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
phone
Phone
[Required] The main business phone.
externalMerchantId
string
This is the unique identifier assigned by the acquirer to the business. It is a business level MID.
legalName
string
[Required] The legal name of the business.
businessUrl
string
The url of the business’ website.
closingReason
string, enum['TERMINATED', 'CHURNED']
closingDetails
string
doingBusinessAs
string
[Required] The name the business likes to be known as.
industryType
string
The industry type that this business belongs to.
sic
string
[Required] The standard industry code of the business.
activeSince
string
This is a response only field. It is set internally and returned in response. The time (in ISO-8601 format) at which the first terminal at the business was activated. E.g. 2014-09-11T23:14:44Z.
supportedCardProducts
array [string]
sendWelcomeEmail
boolean
address
Address
[Required] The main business address.
type
string, enum['MERCHANT', 'TEST_MERCHANT', 'DEVELOPER', 'DISTRIBUTOR', 'ORGANIZATION']
[Required] The type of business.
id
string
The id of the business. This id could be generated by the client and passed in. If not passed in, it is generated internally during create business.
attributes
object
A name/value pair list that could be persisted and later retreived.
description
string
[Required] A short description of the business.
status
string, enum['ADDED', 'ACTIVATED', 'LOCKED', 'CLOSED']
It is set to ADDED as soon as the business is added into the system. Moved to ACTIVATED once the first terminal is activated. It may move to LOCKED if for whatever reason, operations need to be stopped. It is moved to CLOSED if the business is closed for good.

BusinessUser

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
userId
integer
email
string
firstName
string
lastName
string
cards
array [Card]
nickName
string
startDate
integer
endDate
integer
emailSignupCode
string
middleInitial
string
middleName
string
credentials
array [UserCredential]
employmentDetails
EmploymentDetails
status
string, enum['EMPLOYED', 'TERMINATED']

CancelRequest

Attributes

emvData
EMVData
cancelReason
string, enum['TIMEOUT', 'CARD_REMOVED', 'CHIP_DECLINE_AFTER_HOST_APPROVAL', 'PIN_PAD_NOT_AVAILABLE', 'MERCHANT_CANCELLED']
context
ClientContext

Card

Object to carry credit/debit card information.

Attributes

numberHashed
string
numberFirst6
string
This is a response field. The first6 numbers of the PAN.
cardBrand
CardBrand
Contains all card branding details
numberLast4
string
This is a response field. The last4 numbers of the PAN.
expirationYear
integer
The year from expiration.
expirationMonth
integer
The month from expiration.
track1data
string
In some use-cases (like airlines) Track1 is required. Track1 contains some extra information over Track2 (like cardholder’s name).
track2data
string
Required for swiped transactions. Track2 read from the card contains PAN, expiration, etc.
keySerialNumber
string
KeySerialNumber of the Poynt P2PE DUKPT key. If encrypted is true, only one of key and keySerialNumber can be populated (not both).
cardHolderFullName
string
Card holder’s full name usually picked from track1.
serviceCode
string
cardHolderFirstName
string
Card holder’s first name usually picked from track1.
cardHolderLastName
string
Card holder’s last name usually picked from track1.
expirationDate
integer
The date from expiration. Date is typically only present in EMV cards.
track3data
string
Track3 for future use. Carries track from custom funding sources.
cardAgreement
CardAgreement
numberMasked
string
This is a response field. PAN with everything except first6 and last4 masked.
encryptedExpirationDate
string
If encryption is true, a single encrypted expiration date (containing year, month and possibly date) is provided here.
cardId
string
The uuid of the card created
issuer
string
currency
string
Card’s native currency code, when available.
source
string, enum['DIRECT', 'APPLE_PAY']
sequenceNumber
string
Sequence number to distinguish between 2 cards with same PAN.
status
string, enum['ACTIVE', 'REMOVED']
Status of the card.
key
array [CardKeyData]
List of keys and their versions being used. If encrypted is true, only one of key and keySerialNumber can be populated (not both).
id
integer
The id of the card created.
type
string, enum['AMERICAN_EXPRESS', 'EBT', 'BANCOMAT', 'DISCOVER', 'MAESTRO', 'GOPAY', 'DINERS_CLUB', 'JCB', 'ALIPAY', 'MASTERCARD', 'DANKORT', 'OTHER', 'PAYPAL', 'INTERAC', 'UNIONPAY', 'VISA']
The network card belongs to: DISCOVER, VISA, MASTERCARD, AMEX, etc.
number
string
Required for keyed-in transactions. The card account number (PAN). Not required if Track1 or 2 are available.

CardAgreement

Object to keep track of card agreements for referenced transactions and recurring billing.

Attributes

businessId
string
Business UUID that this card agreement belongs to.
createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
cardId
string
Card UUID that this card agreement belongs to.
agreedOn
string
Timestamp for when this agreement was agreed.
declinedOn
string
Timestamp for when this agreement was declined.
version
integer
The version of agreement.
email
string
The customer email that we will send the agreemen to.
status
string
Whether the agreement is currently ACCEPTED or DECLINED.
id
string
UUID of the card agreement.

CardBrand

This object represents CardBrand.

Attributes

createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
brand
string
issuerBank
string
logoUrl
string
id
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
scheme
string
displayName
string

CardKeyData

Attributes

version
string
Version of the key.
id
string, enum['WCK', 'WAEK', 'WMACK']
The key identifier.

Catalog

This is a swagger model description.

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
The time (in ISO-8601 format) at which the Catalog was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Catalog was updated. E.g. 2014-09-11T23:14:44Z.
categories
array [Category]
taxes
array [Tax]
products
array [CatalogItem]
availableDiscounts
array [AvailableDiscount]
displayMetadata
array [CatalogDisplayMetadata]
appliedRestrictions
array [string]
restrictions
array [Restriction]
priceBookId
string
name
string
id
string

CatalogItem

An item inside a catalog. Can be a product or a category.

Attributes

taxes
array [Tax]
availableDiscounts
array [AvailableDiscount]
displayOrder
integer
color
string
id
string

CatalogItemWithProduct

An item inside a catalog. Can be a product or a category.

Attributes

taxes
array [Tax]
availableDiscounts
array [AvailableDiscount]
product
Product
displayOrder
integer
color
string

CatalogList

Attributes

links
array [Link]
catalogs
array [Catalog]

CatalogWithProduct

This is a swagger model description.

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
The time (in ISO-8601 format) at which the Catalog was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Catalog was updated. E.g. 2014-09-11T23:14:44Z.
categories
array [CategoryWithProduct]
taxes
array [Tax]
products
array [CatalogItemWithProduct]
availableDiscounts
array [AvailableDiscount]
displayMetadata
array [CatalogDisplayMetadata]
appliedRestrictions
array [string]
restrictions
array [Restriction]
name
string
id
string

Category

A category is a grouping of products with optional display info.

Attributes

shortCode
string
taxes
array [Tax]
products
array [CatalogItem]
availableDiscounts
array [AvailableDiscount]
parentCategoryId
string
displayOrder
integer
color
string
name
string
id
string

CategoryList

Attributes

links
array [Link]
categories
array [Category]

CategoryWithProduct

A category is a grouping of products with optional display info.

Attributes

shortCode
string
taxes
array [Tax]
products
array [CatalogItemWithProduct]
availableDiscounts
array [AvailableDiscount]
parentCategoryId
string
displayOrder
integer
color
string
name
string
id
string

ClientContext

Colors the operation with some important context about the client.

Attributes

businessId
string
This is optional as it can always be picked from the JWT token used for authentication.
storeId
string
This is optional as it can always be picked from the JWT token used for authentication.
mid
string
The acquirer assigned merchant ID (aka MID) for this store.
tid
string
The acquirer assigned terminal ID (aka TID) for the terminal.
mcc
string
The business already has an MCC (merchant category code) set during onboarding. That will be used by default. But we can override it per transaction using this field.
storeDeviceId
string
This is optional as it can always be picked from the JWT token used for authentication.
employeeUserId
integer
This is optional as it can always be picked from the JWT token used for authentication.
transmissionAtLocal
string
This is required if ClientContext is inside Transaction. The time at the terminal (in ISO-8601 format) at the time of the transaction in the terminal’s timezone. This comes specially handy in case of offline transactions where the transaction might have happened hours before this data is sent to the server. E.g. 2014-09-11T23:14:44Z.
businessType
string, enum['MERCHANT', 'TEST_MERCHANT', 'DEVELOPER', 'DISTRIBUTOR', 'ORGANIZATION']
The type of the client business.
sourceApp
string
The package name of the source application.
transactionInstruction
string, enum['NONE', 'EXTERNALLY_PROCESSED', 'ONLINE_AUTH_REQUIRED']
Any instructions about the transaction. EXTERNALLY_PROCESSED implies that this order was paid for outside of the Poynt system.
storeAddressCity
string
storeAddressTerritory
string
storeTimezone
string
acquirerId
string
This is a response only field. Some processors have multiple acquirers behind them. This field helps identify which acquirer it is. Alternately, this value should also be present in the EMV tags.
source
string, enum['INSTORE', 'WEB', 'MOBILE', 'CALLIN', 'CATALOG']
This is required if ClientContext is inside Order. The source where the transaction was initiated.

CloudMessage

Attributes

ttl
integer
businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
storeId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
deviceId
string
serialNum
string
recipient
ComponentName
sender
string
collapseKey
string
data
string
id
string

ComponentName

Attributes

className
string
packageName
string

CurrencyAmount

Attributes

amount
integer
currency
string

Customer

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
firstName
string
createdAt
string
The time (in ISO-8601 format) at which the Customer was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Customer was updated. E.g. 2014-09-11T23:14:44Z.
cards
array [Card]
emails
array [Entry]
This represents customer’s emails. It is modeled as a map, where the EmailType enum is the key and the Email object is the value.
phones
array [Entry]
This represents customer’s phones. It is modeled as a map, where the PhoneType enum is the key and the Phone object is the value.
addresses
array [Entry]
This represents customer’s addresses. It is modeled as a map, where the AddressType enum is the key and the Address object is the value.
insights
CustomerInsights
loyaltyCustomers
array [LoyaltyCustomer]
middleName
string
middleInitial
string
nickName
string
businessPreferences
CustomerBusinessPreferences
userIdentities
array [UserIdentity]
devices
array [Device]
lastName
string
id
integer
attributes
object

CustomerBusinessPreferences

Attributes

preferredCardId
integer

CustomerInsights

Attributes

poyntLoyalty
PoyntLoyalty
lifetimeSpend
array [CurrencyAmount]
scores
array [CustomerScore]
topItems
array [CustomerTopItem]
totalOrders
integer
since
string
The time (in ISO-8601 format) since when this customer has been on file. E.g. 2014-09-11T23:14:44Z.

CustomerList

Attributes

links
array [Link]
customers
array [Customer]
count
integer

CustomerScore

Attributes

score
double
type
string, enum['LOYALTY', 'VALUE', 'OVERALL']

CustomerTopItem

Attributes

countUnit
string, enum['EACH', 'HOURS', 'DAYS', 'SECONDS', 'CRATE_OF_12', 'SIX_PACH', 'GALLON', 'LITRE', 'INCH', 'FOOT', 'MILLIMETER', 'CENTIMETER', 'METER', 'SQUARE_METER', 'CUBIC_METER', 'GRAM', 'KILOGRAM', 'POUND', 'ANNUAL', 'DEGREE_CELCIUS', 'DEGREE_FARENHEIT']
productId
integer
lastPurchasedAt
integer
variationId
integer
firstPurchasedAt
integer
count
double
name
string

CustomFundingSource

Object to carry custom funding source information.

Attributes

accountId
string
The id/account number of the custom funding source.
provider
string
The main entity that owns this custom funding source.
description
string
The description of the custom funding source.
processor
string
The processor for this custom funding source. It might be the provider or it might be someone else.
name
string
The name of this particular funding source. Might be used for display purposes.
type
string, enum['GIFT_CARD', 'BITCOIN', 'CHEQUE', 'VOUCHER', 'REWARD', 'COUPON', 'GIFT_CERTIFICATE', 'QR_CODE', 'OTHER', 'ALIPAY', 'DANA', 'WALLET']
The type of custom funding source: GIFT_CARD, BITCOIN, etc.

DebitEBTReEntry

Only use this object for the special re-entry use case for Debit or EBT.

Attributes

origAuthSourceCode
string
origTransactionNumber
string
origResponseCode
string
origApprovalCode
string
origCreatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
origRetrievalRefNumber
string
origTransactionId
string
origTraceNumber
string
origNetworkId
string

Delivery

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
storeId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
deviceId
string
applicationId
string
createdAt
string
The time (in ISO-8601 format) at which the Delivery was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Delivery was updated. E.g. 2014-09-11T23:14:44Z.
resourceId
string
links
array [Link]
deliveryUrl
string
attempt
integer
hookId
string
merchantType
string
eventType
string
status
string, enum['SCHEDULED', 'RESCHEDULED', 'ERRORED_RETRYING', 'DELIVERED', 'ERRORED']
secret
string
resource
string
properties
object
Mapping of custom attributes attached in Event properties.
id
string

DeliveryList

Attributes

links
array [Link]
deliveries
array [Delivery]

Device

Attributes

deviceType
string, enum['MOBILE', 'UNKNOWN']
macAddresses
array [DeviceMacAddress]
id
integer

DeviceMacAddress

Attributes

networkInterface
string, enum['BLUETOOTH', 'WIFI']
macAddress
string
id
integer

Discount

Details about the discount.

Attributes

processorResponse
ProcessorResponse
amount
integer
[Required] Amount of discount.
customName
string
[Required] Name of the discount.
percentage
float
Percentage of discount.
provider
string
processor
string
id
string
If the discount was applied as a result of a pre-set discount (at the catalog or product level), pass the id of that discount here.

EBTDetails

The details of the Electronic Benefit Transfer.

Attributes

electronicVoucherApprovalCode
string
electronicVoucherSerialNumber
string
type
string, enum['CASH_BENEFIT', 'CASH_BENEFIT_CASH_WITHDRAWAL', 'FOOD_STAMP', 'FOOD_STAMP_ELECTRONIC_VOUCHER']

EMVData

All EMV specific data. During an EMV transaction, objects such as Card, TransactionAmounts, ClientContext, etc will be filled. But everything EMV specific ends up here.

Attributes

emvTags
object
Tags that are not modeled in explicit fields can be passed here. These will be passed untouched to the acquirer.

EmploymentDetails

Attributes

endAt
integer
startAt
integer
customRole
CustomRole
role
string, enum['OWNER', 'MANAGER', 'EMPLOYEE', 'CUSTOM']

ExchangeRate

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
rate
integer
ratePrecision
integer
tipAmount
integer
txnCurrency
string
cardCurrency
string
cardAmount
integer
requestedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
txnAmount
integer
markupPercentage
string
disclaimer
string
markupInfo1
string
markupInfo2
string
cardTipAmount
integer
provider
string
signature
string

Fee

Details about the fee.

Attributes

amount
integer
[Required] Fee amount.
idStr
string
percentage
float
name
string
[Required] Name of the fee.
id
integer

FundingSource

The funding source used for funding transactions.

Attributes

card
Card
If type is CREDIT_DEBIT, this is required. This carries details about the card.
cardToken
string
nonce
string
Only applies when nonce is passed as part of charge Api.
emvData
EMVData
If type is CREDIT_DEBIT and its an EMV transaction, this is required. This carries any EMV tags in addition to card data.
verificationData
VerificationData
If type is CREDIT_DEBIT, this will carry any data needed to verify the card.
entryDetails
FundingSourceEntryDetails
If type is CREDIT_DEBIT, this is required. This carries details about how the funding source data was collected on the terminal.
accountType
string, enum['EBT', 'CHECKING', 'SAVINGS']
The type of account this funding source taps into.
ebtDetails
EBTDetails
exchangeRate
ExchangeRate
bankAccount
BankAccount
If type is ECHECK, this is required. This details about the bank account.
interacMac
string
interacMacKeySerialNumber
string
customFundingSource
CustomFundingSource
If type is CUSTOM_FUNDING_SOURCE, this is required. This carries details about the custom funding source.
paymentToken
string
If type is CREDIT_DEBIT or ECHECK the payment token can be used instead of financial instrument raw data.
debitEBTReEntryDetails
DebitEBTReEntry
type
string, enum['CHEQUE', 'CUSTOM_FUNDING_SOURCE', 'CREDIT_DEBIT', 'CASH']
[Required] The type of funding source (CASH, CREDIT_DEBIT, CUSTOM_FUNDING_SOURCE, ECHECK).

FundingSourceEntryDetails

Attributes

customerPresenceStatus
string, enum['PRESENT', 'MOTO', 'ECOMMERCE', 'ARU', 'INVOICING', 'VIRTUAL_TERMINAL_PRESENT', 'VIRTUAL_TERMINAL_NOT_PRESENT']
entryMode
string, enum['KEYED', 'TRACK_DATA_FROM_MAGSTRIPE', 'CONTACTLESS_MAGSTRIPE', 'INTEGRATED_CIRCUIT_CARD', 'CONTACTLESS_INTEGRATED_CIRCUIT_CARD']

Hook

The object representing the webhook.

Attributes

businessId
string
The business whose events to subscribe to.
applicationId
string
ApplicationId e.g. urn:aid:c5aaffaf-ee8c-41bc-82fa-88882222ddde.
createdAt
string
The time (in ISO-8601 format) at which the Hook was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Hook was updated. E.g. 2014-09-11T23:14:44Z.
deliveryUrl
string
The Url at which to deliver the webhook event.
eventTypes
array [string]
List of events to subscribe to.
secret
string
Used for signing the webhook event.
id
string

HookList

Attributes

links
array [Link]
hooks
array [Hook]

Inventory

Attributes

storeId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
The time (in ISO-8601 format) at which the Inventory was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Inventory was updated. E.g. 2014-09-11T23:14:44Z.
stockCount
float
The actual physical count of the product the business has.
availableCount
float
The subset of the stockCount which is available for sale i.e. If an item is already sold, but not shipped, it is not available.
reOrderLevel
float
When a re-order is triggered, the stockCount should be brought back up to this value.
reOrderPoint
float
When the stockCount reach this value, inventory should be reordered.

InventorySummary

Attributes

storeId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
sku
string
productId
string
stockCount
float
availableCount
float
reOrderLevel
float
reOrderPoint
float
productShortCode
string
productName
string

InventorySummaryList

Attributes

items
array [InventorySummary]
links
array [Link]

JsonNode

Attributes

pojo
boolean
integralNumber
boolean
floatingPointNumber
boolean
short
boolean
int
boolean
long
boolean
double
boolean
bigDecimal
boolean
bigInteger
boolean
textual
boolean
boolean
boolean
containerNode
boolean
valueNode
boolean
missingNode
boolean
nodeType
string, enum['ARRAY', 'BINARY', 'BOOLEAN', 'MISSING', 'NULL', 'NUMBER', 'OBJECT', 'POJO', 'STRING']
float
boolean
object
boolean
number
boolean
binary
boolean
array
boolean
null
boolean

JsonPatch

Attributes


Attributes

rel
string
href
string
method
string

LoyaltyCustomer

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
firstName
string
createdAt
string
The time (in ISO-8601 format) at which the Customer was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the Customer was updated. E.g. 2014-09-11T23:14:44Z.
identifiers
array [Entry]
providerVerification
ProviderVerification
lastName
string
provider
string
id
string

Order

This is the base object for the orders resource. Orders resource represents a purchase order for items or services. This object captures all items, amounts and transactions related to an order. One important point to note upfront is that all the order-level amount fields could be positive or negative. That is because unlike an item which is always either purchased or returned, an order could be a mixed bag of purchased or returned items. So the amounts could be positive or negative.

Attributes

items
array [OrderItem]
A list of items (or services) being purchased.
statuses
OrderStatuses
Represents various order related statuses (including the order’s own status). This is optional input. If not provided while creating an order, the order will be in CREATED state.
customerUserId
integer
This field can be provided by the caller. If provided by the caller, Poynt ensures that it is a valid customer. If not provided by the caller, Poynt tries to determine the customer itself. Poynt assigns a userId to every customer using a card (credit or debit) for a payment. The customer’s userId will be returned in this field. If an order contains multiple transactions, each using a different card, Poynt will leave this field as blank.
createdAt
string
This is a response only field. The time (in ISO-8601 format) at which the order was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
This is a response only field. The time (in ISO-8601 format) at which the order was updated. E.g. 2014-09-11T23:14:44Z.
stayType
string, enum['GENERAL_CONTAINER', 'REGULAR_STAY', 'QUICK_STAY', 'NON_LODGING_SALE', 'NON_LODGING_NRR']
orderNumber
string
Stores often use a human readable order number to hand out to customers. Such numbers could be passed here.
amounts
OrderAmounts
[Required] A summary of all amounts represented in the items, discounts and transactions objects.
customer
Customer
Customer linked to the order. If not passed in will link to the customer on transaction
links
array [Link]
This is a response only field. It will include HATEOS links to any related orders.
notes
string
Any special notes from the customer or merchant about the order could be recorded here.
transactions
array [Transaction]
A list of transactions being performed to pay for this order.
orderHistories
array [OrderHistory]
Order checkpoints to track state transitions.
orderShipments
array [OrderShipment]
A list of shipments that track fulfillment or returns of items
discounts
array [Discount]
Order level discounts. An order level discount will be negative if it is being given to the customer and positive if it is being returned. Note that discounts can also be applied at a per item level. Those are present inside the OrderItem object.
fees
array [Fee]
Order level fees.
parentId
string
When creating a return order, the original order’s ID can be specified here.
context
ClientContext
[Required] Contains context about the order. Source must be populated. All other fields are optional.
id
string
The id of the order created. If provided in the request, it will be used as the order ID. If not provided, id will be generated internally.
attributes
object
A name/value pair list that could be persisted and later retrieved.

OrderAmounts

Summary of all amounts related to the order.

Attributes

taxTotal
integer
[Required] Sum of all item level taxes. Positive amount for purchases, negative amount for returns.
subTotal
integer
[Required] Sum of all item amounts (excluding item level discounts and taxes). Positive amount for purchases and negative amount for returns.
discountTotal
integer
[Required] Sum of all order and item level discounts. Negative amount for purchases, positive amount for returns.
feeTotal
integer
shippingTotal
integer
Sum of all shipping amounts. Positive amount for fulfillment, negative amount for returns.
netTotal
integer
This is a response field. Sum of subTotal, discountTotal, taxTotal and shippingTotal. Note that its a simple summation as those amounts already have the correct sign.
authorizedTotals
TransactionAmounts
This is a response field. Sum of all transactions still in authorized state.
capturedTotals
TransactionAmounts
This is a response field. Sum of all transactions that have been completed.
refundedTotals
TransactionAmounts
This is a response field. Sum of all transactions that have been refunded.
savedTotals
TransactionAmounts
This is a response field. Sum of all transactions that are still in saved state (not processed).
voidedTotals
TransactionAmounts
currency
string
[Required] Currency of the order.

OrderHistory

This is the object to track any order transitions and modifications

Attributes

event
string, enum['ACCEPTED', 'EDITED', 'AWAITING_PICKUP', 'SHIPPED', 'DELIVERED', 'COMPLETED', 'CANCELLED']
The history event based on the order transition. (new state will be the event)
adjustedOrder
AdjustedOrder
The modifications performed on the order, includes items, shipments, fees and discounts. Stored as a text blob
timestamp
string
The time (in ISO-8601 format) of the event occurrence
id
integer
Every history gets an ID unique within the order. If not passed from outside, the server assigns Id’s starting from 1

OrderItem

Details about the item being purchased. Here are a couple of point that might not be immediately obvious: (a) all discounts and taxes apply to the entire group of items, not just a single unit of item, (b) none of the amount fields inside OrderItem carry +/- sign because the sign is implied in the item status. E.g. discount would be -ive is item’s status is ORDERED or FULFILLED and +ive if item’s status is RETURNED.

Attributes

createdAt
string
The time (in ISO-8601 format) at which the order item was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the order item was updated. E.g. 2014-09-11T23:14:44Z.
serviceStartAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
serviceEndAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
quantity
float
[Required] Quantity purchased. Note this could be in decimals, e.g. 2.3 Kgs.
sku
string
Sku of the item.
tax
integer
Total tax amount applied on this group of items (not just 1 unit). If not specified, but the taxes array is present the server will automatically sum up the amounts in taxes array and populate this. If not specified and taxes array is empty, this will default to 0.
taxes
array [OrderItemTax]
A break-down/details of the tax amount. Note that the taxes here in this array are for the entire group of items put together (not just 1 unit).
unitPrice
integer
[Required] Price for each unit.
discount
integer
Total discount amount applied on this group of items (not just 1 unit). If not specified, but the discounts array is present the server will automatically sum up the amounts in discounts array and populate this. If not specified and discounts array is empty, this will default to 0.
fee
integer
discounts
array [Discount]
A break-down/details of the discount amount. Note that the discounts here in this array are for the entire group of items put together (not just 1 unit).
fees
array [Fee]
productId
string
Not being used - will be removed.
selectedVariants
array [Variant]
unitOfMeasure
string, enum['EACH', 'HOURS', 'DAYS', 'SECONDS', 'CRATE_OF_12', 'SIX_PACH', 'GALLON', 'LITRE', 'INCH', 'FOOT', 'MILLIMETER', 'CENTIMETER', 'METER', 'SQUARE_METER', 'CUBIC_METER', 'GRAM', 'KILOGRAM', 'POUND', 'ANNUAL', 'DEGREE_CELCIUS', 'DEGREE_FARENHEIT']
[Required] Unit of measure for the quantity.
details
string
Item details.
categoryId
string
clientNotes
string
Any special instructions related to this order item.
fulfillmentInstruction
string, enum['NONE', 'PICKUP_INSTORE', 'SHIP_TO']
Instructions on how this set of items will be fulfilled. Only applicable on items that are in ORDERED state. If the fulfillmentInstruction is SHIP_TO, you can note down the address in the clientNotes field as we don’t model delivery address yet.
status
string, enum['ORDERED', 'FULFILLED', 'RETURNED']
[Required] Status of the item.
name
string
[Required] Name of the item.
id
integer
Every item gets an ID unique within the order. If not passed from outside, the server simple assigns IDs in ascending order starting from 1.

OrderItemTax

Attributes

amount
integer
amountPrecision
integer
taxRatePercentage
double
taxRateFixedAmount
integer
id
string
type
string

OrderList

Attributes

links
array [Link]
orders
array [Order]
count
integer

OrderShipment

Shipment information related to the order, this model will be used for (1)tracking item fulfillment (2) item returns

Attributes

items
array [OrderShipmentItem]
createdAt
string
The time (in ISO-8601 format) at which the order item was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the order item was updated. E.g. 2014-09-11T23:14:44Z.
amount
integer
Shipment amount that is payable for the shipment (including taxes)
notes
string
Any special notes from the customer or merchant about the shipment could be recorded here.
carrier
string
Name of the Carrier handling the shipment
trackingNumber
string
Tracking number for the shipment
deliveryMode
string, enum['CURBSIDE', 'DELIVERY', 'DRIVE_THRU', 'FOR_HERE', 'PICKUP', 'SHIP', 'TO_GO']
[Required] The mode in which the items are being fulfilled, can be one of FOR_HERE, TO_GO, PICKUP, DRIVE_THRU, DELIVERY, CURBSIDE or SHIP
shipmentType
string, enum['FULFILLMENT', 'RETURN']
The kind of shipment, can be FULFILLMENT or RETURN
trackingUrl
string
Tracking url to track the shipment
deliveredAt
string
The time (in ISO-8601 format) at which the order item is delivered E.g. 2014-09-11T23:14:44Z.
fulfillAt
string
The time (in ISO-8601 format) at which the order item needs to be fulfilled. E.g. 2014-09-11T23:14:44Z.
shippedAt
string
The time (in ISO-8601 format) at which the shipment was made. E.g. 2014-09-11T23:14:44Z.
estimatedDelivery
string
The time (in ISO-8601 format) at which the order item is estimated to be delivered. E.g. 2014-09-11T23:14:44Z.
provider
string
Provider of the shipment
status
string, enum['NONE', 'AWAITING_PICKUP', 'IN_TRANSIT', 'DELIVERED', 'CANCELLED']
Status of shipment, can be one of NONE, AWAITING_PICKUP, IN_TRANSIT, DELIVERED
address
Address
Recipient address for the shipment
id
integer
Every shipment gets an ID unique within the order. If not passed from outside, the server simple assigns IDs in ascending order starting from 1.

OrderShipmentItem

Details about the item being purchased. Here are a couple of point that might not be immediately obvious: (a) all discounts and taxes apply to the entire group of items, not just a single unit of item, (b) none of the amount fields inside OrderItem carry +/- sign because the sign is implied in the item status. E.g. discount would be -ive is item’s status is ORDERED or FULFILLED and +ive if item’s status is RETURNED.

Attributes

createdAt
string
The time (in ISO-8601 format) at which the order item was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the order item was updated. E.g. 2014-09-11T23:14:44Z.
quantity
float
[Required] Quantity purchased. Note this could be in decimals, e.g. 2.3 Kgs.
name
string
[Required] Name of the item.
id
integer
Every item gets an ID unique within the order. If not passed from outside, the server simple assigns IDs in ascending order starting from 1.

OrderStatuses

Order status and item fulfillment status.

Attributes

transactionStatusSummary
string, enum['NONE', 'EXTERNALLY_PROCESSED', 'PENDING', 'COMPLETED', 'REFUNDED', 'CANCELED']
This is a response only field. Show a summary view of all the transactions’ statuses put together. NONE implies no transaction was ever processed for this order (note: cash is counted as processed). EXTERNALLY_PROCESSED implies that the the creator of the order instructed that the transactions was processed outside of Poynt. COMPLETED implies that something has been processed, and net funds received >= order’s net total. CANCELED implies that something has been processed, but everything is voided at this point. REFUNDED implies that something has been processed, but everything is refunded at this point. PENDING implies that something has been processed, but net funds received < order’s net total.
fulfillmentStatus
string, enum['NONE', 'PARTIAL', 'FULFILLED']
This is a response only field. Show a summary view of all the items’ fulfillment statuses put together. If none of the items have been fulfilled, this status will be NONE. If all items have been fulfilled, this status will be FULFILLED. If some but not all items have been fulfilled, this will be PARTIAL.
status
string, enum['OPENED', 'CANCELLED', 'COMPLETED']
This is an input/output field. An order status is used for tracking which orders are being actively monitored vs which ones are archived. An order marked as COMPLETED or CANCELED is closed an hence is not being actively monitored by the merchant. A merchant focused on OPENED orders.

Phone

Attributes

ituCountryCode
string
areaCode
string
localPhoneNumber
string
extensionNumber
string
createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
status
string, enum['ADDED', 'CONFIRMED']
id
integer
type
string, enum['HOME', 'WORK', 'BUSINESS', 'MOBILE', 'FAX', 'PAGER', 'RECEIPT', 'OTHER']

PoyntLoyalty

Attributes

externalId
string
loyalty
array [PoyntLoyaltyCampaign]
reward
array [PoyntLoyaltyReward]
loyaltyId
integer

PoyntLoyaltyCampaign

Attributes

nextTier
string
businessLoyaltyId
integer
campaignDescription
string
campaignName
string
loyaltyType
string
pointsRequired
integer
loyaltyUnit
string
lastIncrement
integer
points
integer
totalPoints
integer
rewardDescription
string
totalSpend
integer
totalVisits
integer
tier
string

PoyntLoyaltyReward

Attributes

businessLoyaltyId
integer
rewardDescription
string
preText
string
postText
string
rewardId
integer
expireAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
status
string
value
integer
type
string

ProcessorResponse

Processor response fields.

Attributes

cardToken
string
acquirer
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']
batchId
string
The ID of the settlement batch that this transaction is assigned to.
approvalCode
string
The approval code that came back from the acquirer (usually its 6 alpha-numeric characters).
emvTags
object
A name/value pair to list down all tags returned by the processor including the ones normalized in some of the other fields in ProcessorResponse. Both name and value are Strings.
cvActualResult
string
cvResult
string, enum['MATCH', 'NO_MATCH', 'NOT_PROCESSED', 'NO_CODE_PRESENT', 'SHOULD_HAVE_BEEN_PRESENT', 'ISSUER_NOT_CERTIFIED', 'INVALID', 'NO_RESPONSE', 'NOT_APPLICABLE']
The card verification results.
avsResult
AVSResult
The address verification results.
approvedAmount
integer
The amount that the authorization was approved for. This could be different from the transactionAmount requested.
echeckProcessor
string, enum['MOCK', 'CHECK_COMMERCE']
eCheck(electronic payment funded by the buyer’s bank account) processor used by the business.
interacMac
string
statusMessage
string
Will be whatever message came back from the acquirer.
retrievalRefNum
string
scaResult
string, enum['ENTER_PIN', 'INSERT_CARD', 'CDCVM']
Represents a SCA status if it was triggered. Strong Customer Authentication (SCA) is a European regulatory requirement to reduce fraud and make online payments more secure.
adapterId
string
adapterVariant
string
remainingBalance
integer
The amount that is left on the prepaid card after an authorization.
batchAutoClosedByHost
string
providerVerification
ProviderVerification
Object that carries provider verification related fields.
debitResponseCode
string
pinSessionKey
string
processedAt
string
Date / time of transaction received by the processor host.
statusCode
string
Will be 1 if status is Successful. If status is Failure, it will be whatever statusCode came from the acquirer.
transactionId
string
The transactionID that came back from the acquirer.
status
string, enum['Successful', 'Failure']
Possible values are Successful or Failure.
processor
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']

Product

Attributes

inventory
array [Inventory]
businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
brand
string
releaseDate
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
shortCode
string
price
CurrencyAmount
sku
string
selectableVariants
array [Variant]
imageUrl
array [string]
taxes
array [Tax]
bundledProducts
array [ProductRelation]
unitOfMeasure
string, enum['EACH', 'HOURS', 'DAYS', 'SECONDS', 'CRATE_OF_12', 'SIX_PACH', 'GALLON', 'LITRE', 'INCH', 'FOOT', 'MILLIMETER', 'CENTIMETER', 'METER', 'SQUARE_METER', 'CUBIC_METER', 'GRAM', 'KILOGRAM', 'POUND', 'ANNUAL', 'DEGREE_CELCIUS', 'DEGREE_FARENHEIT']
relatedProducts
array [ProductRelation]
addonProducts
array [ProductRelation]
possibleVariations
array [Variation]
availableDiscounts
array [AvailableDiscount]
ean
string
upc
string
isbn
string
plu
string
asin
string
specification
string
manufacturer
string
publisher
string
studio
string
designer
string
artist
string
productTemplateId
string
mpn
string
styleNumber
string
modelNumber
string
msrp
CurrencyAmount
avgUnitCost
CurrencyAmount
author
string
restrictionAttributes
array [RestrictionAttribute]
templateOverrides
array [string]
appliedRestrictions
array [string]
description
string
tags
string
status
string, enum['ACTIVE', 'RETIRED']
name
string
id
string
type
string, enum['SIMPLE', 'BUNDLE']
variants
array [Variant]

ProductList

Attributes

links
array [Link]
products
array [Product]

ProductRelation

Attributes

price
CurrencyAmount
relatedProductId
string
relatedProductSku
array [string]
count
integer
type
string, enum['BUNDLE', 'RELATED', 'ADDON']

ProductSummary

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
shortCode
string
price
CurrencyAmount
name
string
id
string

ProductSummaryList

Attributes

links
array [Link]
products
array [ProductSummary]

ProductVariation

Attributes

attribute
string
value
string

ProviderVerification

Provider verification fields.

Attributes

publicKeyHash
string
A hash of the public key so Poynt knows it has the right public key.
signature
string
Base64 encoded signature of the transactions.

QueryStatus

Attributes

stateChangeReason
string
Information generated upon state change.
resourceUrl
string
Resource link containing query result.
startedAt
string
Query execution starting date time.
completedAt
string
Query execution completion date time.
state
string
Query execution state: PENDING, COMPLETED, FAILED.

ReceiptTemplate

Attributes

template
string
id
string

SelectableVariation

Attributes

cardinality
string
attribute
string
values
array [SelectableValue]

Store

This is the base object for the businesses resource. Businesses resource represents a merchant business.

Attributes

processor
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']
The processor for this merchant. If this field is left blank it is assumed that the processor is the acquirer itself or CreditCall that happens to be our primary gateway.
acquirer
string, enum['CHASE_PAYMENTECH', 'REDE', 'EVO', 'FIRST_DATA', 'GLOBAL_PAYMENTS', 'HEARTLAND_PAYMENT_SYSTEM', 'ELAVON', 'MERCURY', 'MONERIS', 'PAYPAL', 'ELAVON_MX', 'STRIPE', 'TSYS', 'VANTIV', 'WORLDPAY', 'EPX', 'WEPAY', 'MASHREQ', 'AXIS', 'KARTUKU', 'NEXI', 'DANA', 'MYNT', 'POYNT', 'NUVEI', 'BRIDGEPAY', 'CONVERGE', 'MOCK', 'NA_BANCARD', 'CREDITCALL', 'ELAVON_EU', 'FUSEBOX', 'SEAMLESS_PAYMENTS', 'EVERTEC', 'GHL', 'RS2', 'JCN', 'PRISMA', 'VANTIV_EXPRESS', 'EZETAP', 'LETGO']
The acquirer for this merchant.
echeckProcessor
string, enum['MOCK', 'CHECK_COMMERCE']
eCheck(electronic payment funded by the buyer’s bank account) processor used by the business.
timezone
string
[Required] The timezone of the store.
mockProcessor
boolean
processorData
object
catalogId
string
The default product catalog that devices at the store should use.
externalStoreId
string
[Required] MID (merchantId) assigned to the store by the acquirer.
emailAddress
string
subscribedBundles
array [BundledFeatures]
The list of bundles this store has subscribed to.
governmentIds
array [GovernmentId]
storeDevices
array [StoreDevice]
See storeTerminalIds.
processorAdapterId
string
phone
Phone
[Required] The store’s phone. This may or may not be different from business phone.
gatewayStoreId
string
ID assigned to the store by the gateway (some gateways assign their own IDs). This field will typically not be available when the business is initially created in the Poynt system. Once that information is passed to the gateway, they will provide their ID.
longitude
float
Longitude of the terminal.
latitude
float
Latitude of the terminal.
fixedLocation
boolean
storeTerminalIds
array [StoreTerminalId]
A list of terminal IDs that are allocated at this store.
supportedCardProducts
array [CardProduct]
address
Address
[Required] The store’s address. This may or may not be different from business address.
currency
string
The primary transaction currency for this merchant.
id
string
The id of the store. This id is generated internally during create business.
attributes
object
A name/value pair list that could be persisted and later retreived.
displayName
string
[Required] The store name (used in various displays). It is recommended to pick a different name for each store in the business.
status
string, enum['ACTIVE', 'DISABLED', 'REMOVED']
The status of the store.

StoreDevice

This object represents devices in store. The most common store device represented in the Poynt system is a terminal. In the Poynt system a business can have 0 or more stores and each store can have 0 or more store devices. Note that a terminal when initially created will only have an externalTerminalId (aka TID assigned by the acquirer). It is only after the Poynt Smart Terminal arrives at the store and is activated that the deviceId is associated with the externalTerminalId to complete the terminal profile.

Attributes

createdAt
string
The time (in ISO-8601 format) at which the store device was created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
The time (in ISO-8601 format) at which the store device was updated. E.g. 2014-09-11T23:14:44Z.
storeId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
deviceId
string
Required during activation. A Poynt identifier for the terminal device. This is not available at the time of business onboarding as at that point a physical device has not been picked. It is assigned during terminal activation.
publicKey
string
PublicKey to verify all future JWT tokens coming from the terminal.
businessAgreements
array [Entry]
Business agreement type to business agreement object map.
kekDetails
array [DeviceKekData]
publicKeyVerification
PublicKeyVerificationData
processorData
object
catalogId
string
The store level product catalog can be overriden at the terminal level using this field.
externalTerminalId
string
[Required] The TID (terminal ID) assigned to this terminal by the acquirer.
lastSeenAt
string
The time (in ISO-8601 format) at which the storeDevice last had any activity. E.g. 2014-09-11T23:14:44Z.
serialNumber
string
Required during activation. A manufacturer identifier for the terminal device. This is not available at the time of business onboarding as at that point a physical device has not been picked. It is assigned during terminal activation.
type
string, enum['TERMINAL', 'WIFI_SENSOR']
[Required] Type of device.
status
string, enum['CREATED', 'ACTIVATED', 'DEACTIVATED', 'REMOVED']
Status of device.
name
string
Name of the terminal assigned by the business user. It is recommended to use a different name for each terminal.

Tax

Attributes

businessId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
createdAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
updatedAt
string
ISO 8601 format YYYY-MM-DDThh:mm:ssZ
rate
double
amount
integer
description
string
name
string
id
string
type
string

TaxList

Attributes

links
array [Link]
taxes
array [Tax]

ThreeDSecureData

3D secure data.

Attributes

eci
string
The Electronic Commerce Indicator security level associated with the token.
cryptogram
string
Base-64 cryptographic identifier used by card schemes to validate the token verification result.

TokenResponse

Attributes

refreshToken
string
accessToken
string
tokenType
string, enum['BEARER']
expiresIn
integer
scope
string

Transaction

This is the base object for the transactions resource. Transactions resource represents a financial transaction. It can be used to save the transaction in the Poynt system as well as initiate interaction with the acquirer to move funds.

Attributes

customerUserId
integer
A Poynt generated customer id that is returned in the response. This id is only assigned only to a customer performing a card transaction.
fundingSource
FundingSource
[Required] The funding source used for funding this transaction.
createdAt
string
This is a response field. The server time (in ISO-8601 format) at which this transaction was initially created. E.g. 2014-09-11T23:14:44Z.
updatedAt
string
This is a response field. The server time (in ISO-8601 format) at which this transaction was last updated. E.g. 2014-09-11T23:14:44Z.
approvalCode
string
An approval code received over the phone (in case of terminal going offline) can be passed here as part of a SALE transaction. This process in the industry is often referred to as forced post or forced sale.
processorResponse
ProcessorResponse
This is a response field. Some important response elements received from the processor.
adjustmentHistory
array [AdjustmentRecord]
If the transaction has been adjusted (aka updated), this list will show the details of the updates.
processorOptions
object
A name/value pair list that could be persisted and later retreived - primarily to store additional payment related data that get passed through to the processor.
references
array [TransactionReference]
References to orders/invoices that this transaction is for.
stayType
string, enum['GENERAL_CONTAINER', 'REGULAR_STAY', 'QUICK_STAY', 'NON_LODGING_SALE', 'NON_LODGING_NRR']
receiptEmailAddress
string
Email address collected from the customer.
amounts
TransactionAmounts
[Required] All amounts requested for this transaction.
systemTraceAuditNumber
string
This is a unique number per transaction session generated by the terminal.
links
array [Link]
This is a response field. Hateos link pointing to all immediate parent and child transactions. E.g. a CAPTURE transaction that has been REFUNDED would have 2 links: one pointing to its parent AUTHORIZE transaction and the other to its child REFUND transaction.
chargebackStatus
string, enum['CREATED', 'DISPUTED', 'MERCHANT_WON', 'MERCHANT_LOST']
poyntLoyalty
PoyntLoyalty
notes
string
Any special notes from the customer or merchant about the transaction could be recorded here.
shippingAddress
Address
A shipping address associated with the transaction.
transactionNumber
string
A transaction number generated by the client and passed to the server. This could be anything; the server will just store it.
customerLanguage
string
The customer’s language preference for the transaction.
receiptPhone
Phone
Phone collected from the customer to SMS receipt.
reason
TransactionReason
action
string, enum['AUTHORIZE', 'CAPTURE', 'VOID', 'OFFLINE_AUTHORIZE', 'REFUND', 'SALE', 'VERIFY']
[Required] If funding source is CASH, only SALE and REFUND are the available options. If funding source is CREDIT_DEBIT, AUTHORIZE, SALE or REFUND are the possible request options. Note that even for VOID, the action is set to REFUND. OFFLINE_AUTHORIZE can only be used in a Record Transaction API to record an authorization that already happened offline.
parentId
string
In the request, if action = refund, parentId could carry the id of the transaction being refunded. Note that parentId could be empty for non-referenced refund. In the response, this will contain the parent transaction’s Id (e.g. capture is the parent of refund and authorization is the parent of capture.
status
string, enum['CREATED', 'SAVED', 'AUTHORIZED', 'PARTIALLY_CAPTURED', 'CAPTURED', 'DECLINED', 'PARTIALLY_CAPTURED_AND_PARTIALLY_REFUNDED', 'PARTIALLY_REFUNDED', 'REFUNDED', 'VOIDED', 'STEP_UP']
If funding source is CASH, only CAPTURED and REFUNDED are the possible options. The SAVE feature is not applicable to CASH.
context
ClientContext
[Required] Contains context about the transaction. TransmissionAtLocal must be provided. All other fields are optional.
id
string
The id of the transaction created. If provided in the request, it will be used as the transaction ID. If not provided, id will be generated internally.
signature
array [byte]
Signature collected from the customer.

TransactionAmounts

All amount related fields.

Attributes

tipAmount
integer
The portion of transactionAmount that went towards tip. Defaults to 0 if not provided.
orderAmount
integer
[Required] The portion of transactionAmount that went towards the item/service being purchased.
cashbackAmount
integer
The portion of transactionAmount that will be returned as cashback (mainly applicable for cash or debit-card tenders). Defaults to 0 if not provided.
transactionAmount
integer
[Required] The total amount to be charged on the tender. This equals orderAmount + tipAmount + cashbackAmount + SUM(transactionFees).
transactionFees
array [TransactionFee]
currency
string
[Required] Currency following the ISO-4217 format (http://en.wikipedia.org/wiki/ISO_4217).

TransactionFee

Contains the transaction fee type and the corresponding amount

Attributes

amount
integer
type
string

TransactionList

Attributes

links
array [Link]
transactions
array [Transaction]
count
integer

TransactionReason

Reason for transaction - currently only applicable for lodging.

Attributes

programFor
array [string]
Some programs require this additional programFor list to be populated.
program
string, enum['NO_SHOW', 'PURCHASE', 'CARD_DEPOSIT', 'DELAYED_CHARGE', 'EXPRESS_SERVICE', 'ASSURED_RESERVATION']
The reason for the transaction - currently only applicable for lodging.

TransactionReceipt

Attributes

txnId
string
UUID version 1, 2, 3, or 4. All server generated values are version 4.
data
string

TransactionReference

Reference to a document (e.g. order or invoice) that this transaction is for.

Attributes

customType
string
If type is set to CUSTOM, this must be populated. This is used to provide the name of the document being referenced.
id
string
The ID of the document.
type
str