bunq / doc

The bunq API documentation
https://doc.bunq.com
MIT License
30 stars 19 forks source link

Signing response return error without explanation #125

Closed emreond closed 4 years ago

emreond commented 4 years ago

Hello,

I'm trying to call /v1/session-server url. I can successfully call before endpoints. In this url, It returns me;

{ "Error" : [ { "error_description_translated" : "For this operation a request signature is required. Check the urls for more information.", "error_description" : "For this operation a request signature is required. Check the urls for more information.", "error_additional_parameter" : [ { "url_together_post" : "https:\/\/together.bunq.com\/d\/15399" } ] } ] } error. I tried to call it with IGNORE_ONLY_FOR_TESTING but It returns me the same error. I'm using javascript function which is also in postman to sign it with private key. My data to sign is in as below;

Post /v1/session-server\nX-Bunq-Region: en_US\nX-Bunq-Language: en_US\nX-Bunq-Geolocation: 0 0 0 0 000\nX-Bunq-Client-Request-Id: mp3vuWWoH2vVF368BGOs\nX-Bunq-Client-Authentication: ef3e3252270456bedf53ed775761f642ecfce89a75fb881ee2890085548dacee\nUser-Agent: postman\nCache-Control: no-cache\n\n{secret:sandbox_5b987d687645854c8d2414aa1fdd6be5780d304bf8c36c7809b35e92}"

What am I doing wrong? Thank you.

lexym commented 4 years ago

@emreond IGNORE_ONLY_FOR_TESTING doesn't work anymore, after we simplified signing. Request body signatures are only required for some calls, and opening a session is one of them: https://beta.doc.bunq.com/basics/authentication/signing