Web hooks server issue for EU

we have inserted only the private key in the PEM file but we receive the same error from the server.
The same request on US servers with the US key is successful.
Please give us an answer as soon as possible that we are missing only this for completing the integration.

@sinappsys, Our node.js SDK was not configured to hit services-eu endpoint. I’ve made the changes. Please use https://github.com/poynt/poynt-node/tree/dennis and look at the README (changes have not been merged to master branch yet).

@dennis with your changes we receive the same error

@sinappsys can you post your Node.js code?

@dennis we have solved with this further changes:
from
https://billing.poynt.net/apps/urn:aid:b25e3e3a-dec2-41a1-baaa-2e91bf440f0a/subscriptions/fc7f0a65-d286-4d4c-b9de-a6a7874c2e3a

to
https://billing-eu.poynt.net/apps/urn:aid:b25e3e3a-dec2-41a1-baaa-2e91bf440f0a/subscriptions/fc7f0a65-d286-4d4c-b9de-a6a7874c2e3a

Now for test subscriptions we need a solution to reset activated subscriptions our test merchant are: “Salute Cafe 790”

in addition we find a problem in the restoration of canceled subscriptions on the smartpos

@sinappsys what do you mean by reset activated subscriptions?

technicians need to test the subscriptions made with the test merchant.
So I need to be able to cancel subscriptions made so I can resubscribe the same plan

@dennis no news for my problem?

@sinappsys you can cancel in Poynt Store app (Account tab):
https://poynt.zendesk.com/hc/en-us/articles/115012584367-Apps-Cancel-or-Unsubscribe

@dennis
we have no problem doing the unsubscribe but when we go then to restore the subscription to test the functionality of purchase we receive the error as per the attached screenshot.
Our need is to be able to test the purchasing process several times on the server side. Is there a simpler procedure to do this with the test merchant?
thank you

@sinappsys I can’t tell why this error happening. Can you attach the logcat from the terminal?

@dennis
at this link logcat file

https://1drv.ms/t/s!Ai1isrSZls7OgfhUzDc74fC4rKV_Zw

You are passing plan id (3771da36-ab3d-4422-80be-f9f0c439caec) instead of subscription id. That’s why it’s failing.The API you are using is expecting a subscription id.

@denis
with subscription id we receive error too.
at this link new logcat

https://1drv.ms/t/s!Ai1isrSZls7OgfhVYLpQQBwxGRi5Zw

Here’s the error from the log:
09-20 02:11:08.738 1520 5242 D OkHttp : {"code":"INVALID_REQUEST","httpStatus":400,"message":"Bad request","developerMessage":"Unable to restore permanently removed subscription","requestId":"c50d32ca-7174-45f0-867f-6cee441ee0a7"}

This error is thrown when a subscription status is no longer active. You can only restore subscriptions that are ACTIVE until the end of the current billing cycle.

Subscriptions created in dev portal have cancel policy set to immediate which means that when subscription is canceled it’s status will change immediately. We are making a change on dev portal which should go out next week to allow developers to specify if the cancelation policy will be immediate or end of billing cycle. If it’s the latter, you will be able to restore the subscription as long as it did not run out.

@dennis

at server side with node.js with this call:

var poynt = require(‘poynt’)({
region: ‘eu’,
applicationId: ‘urn:aid:b25e3e3a-dec2-41a1-baaa-2e91bf440f0a’,
filename: __dirname + ‘/testprizeme.pem’
})
poynt.createHook({
businessId: ‘8eb8c2c9-0087-4cb4-aafd-ccbeff9c8e72’,
eventTypes: [‘APPLICATION_SUBSCRIPTION_START’, ‘APPLICATION_SUBSCRIPTION_END’, ‘APPLICATION_SUBSCRIPTION_PAYMENT_SUCCESS’, ‘APPLICATION_SUBSCRIPTION_PAYMENT_FAIL’, ‘APPLICATION_SUBSCRIPTION_PHASE_CHANGE’, ‘APPLICATION_SUBSCRIPTION_REFUND_SUCCESS’],
deliveryUrl: ‘http://mywebsite’,
secret: ‘poynt123’
}, function (err, doc) {
if (err) {
throw err;
}
console.log(JSON.stringify(doc));
});

we receive follow error:

developerMessage = "The principal does not have read access to the resource: /applications"The principal does not have read access to the resource: /applications
Error: Access not authorized for the requested resource.
at Object.error (C:\Users\agnap\source\repos\NodejsConsoleApp1\NodejsConsoleApp1\node_modules\poynt\lib\helpers.js:39:11)
at Request._callback (C:\Users\agnap\source\repos\NodejsConsoleApp1\NodejsConsoleApp1\node_modules\poynt\lib\helpers.js:249:25)
at Request.self.callback (C:\Users\agnap\source\repos\NodejsConsoleApp1\NodejsConsoleApp1\node_modules\request\request.js:185:22)
at emitTwo (events.js:126:13)
at Request.emit (events.js:214:7)
at Request. (C:\Users\agnap\source\repos\NodejsConsoleApp1\NodejsConsoleApp1\node_modules\request\request.js:1157:10)
at emitOne (events.js:116:13)
at Request.emit (events.js:211:7)
at IncomingMessage. (C:\Users\agnap\source\repos\NodejsConsoleApp1\NodejsConsoleApp1\node_modules\request\request.js:1079:12)
at Object.onceWrapper (events.js:313:30)

any solution for this?

thanks

@dennis
any news for our issuei?

thanks

@sinappsys, @satya1 is investigating this and will provide an update once this is resolved.

any update for our problem?

@dennis @satya1 no news for our issue?