1

I want to get user call report from sinch, for that i need to generate application signed request.

https://www.sinch.com/docs/voice/rest/#UserCallReport

I can not find demo to generate application signed request for android in documentation.

I am getting this error message when fire request in postman

Request: GET https://reportingapi.sinch.com/v1/users/username/jigar1/calls/

Params -> Authorization : Application 554042e3-965c-4e88-a7b8-3f2b52c278f3:t0fsMPGjaNiAEjT+29FyHnHuzaKDAOT3rShXWQp3IcA=
          X-Timestamp : 2016-06-21T06:37:43Z

Response :

{
  "errorCode": 40102,
  "message": "Invalid Signature.",
  "reference": "A:554042e3-965c-4e88-a7b8-3f2b52c278f3_JEC6uQxEUkSkNmSkvvNwXA"
}
Divyang Panchal
  • 1,889
  • 1
  • 19
  • 27

3 Answers3

0

You can find the pseudo code here https://www.sinch.com/using-rest/#applicationsignedrequest

Or you can use basic auth

cjensen
  • 2,703
  • 1
  • 16
  • 15
0

I have used some reports from Sinch. To authenticate my requests I'm using the demo in the Sinch Github account, you can check the repo here. This will work fine for you.

With the request https://reportingapi.sinch.com/v1/users/username/1234571/calls/ I got the response

{
"start": "2017-10-31T00:00:00",
"duration": 0,
"success": 0,
"failed": 0
}
-1

I tried to do the same and posted the code at:

User Call Report API gives incorrect results

Which is based on:

https://www.sinch.com/tutorials/sign-requests-java

I have a different problem with that code, but at least it does not give any "Invalid Signature" message.

Community
  • 1
  • 1
Dan
  • 19
  • 3