How can i get products list from external database

I would like to retreive product list from external database using IPoyntProductService.
Any idea how can i do that?

IPoyntProductService only works with products stored in Poynt cloud. You would need to write your service to work with an external database.

ok. So can i copy or import my products and categories to Poynt cloud programmatically using php for example ? cause i would like to use other Poynt services like payment and print receipt.


We have a file upload option on, but depending on the complexity of your catalog it may or may not work for you. You need to look at the upload template. Otherwise you can use our cloud APIs to create the catalog. Here’s an example how you can create a product:

		POST /businesses/{businessId}/products HTTP/1.1
		Content-Type: application/json
		Authorization: Bearer {access token}
		Poynt-Request-Id: {requestId}
		api-version: 1.2
		Cache-Control: no-cache
		  "name":"Cheetos Crunch 757",
		  "description":"A flaming bag of Cheetos",
		  "specification":"Total Fat: 16%DV, Sodium:10%DV,, Carb: 4%DV",
		  "msrp":{"amount":142, "currency":"USD"},
		  "tags":"junk food",
		  "price":{"amount":142, "currency":"USD"},

Please refer to our API reference to see which fields are required or optional.

OK. Should I create a cloud app?

Yes, create a cloud application in the Poynt HQ developer portal. Select both read and write permissions for the Products resource. You can also grant permissions to your app on behalf of any of your test merchants through the cloud-app management UI (so you can start making API calls against your test merchant app immediately, without having to go through the OAuth flow).

i created a cloud app now i’m reading the documentation

i use this php code below :

$url = "".$bus."/products";

$data = array('Content-type' => 'application/json', 'authorization' => $token, 

'poynt-request-id' => 'poyntRequstID',

' api-version' => '1.2');

$options = array(

    'http' => array(
    'header'  => "Content-type: application/x-www-form-urlencoded\r\n",
    'method'  => 'POST',
    'content' =>  http_build_query($data)

$context  = stream_context_create($options);

 $result = file_get_contents($url, false, $context);

 if ($result === FALSE) { /* Handle error */ }


but always i got 401 error.
And how can i get poyntRequstID?
Any idea or example?

Hi there,

From our API Reference:
POYNT-REQUEST-ID - a unique request id to enforce idempotency where ever appropriate (usually for POST requests)

2 possible reasons for status code 401:
401 - Unauthorized, due to invalid access token or authorization needed.

You have to make sure your test merchant has authorized the app id using step #8 on and you also need to make sure you are passing a valid access token in your request.