Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Signature for this request is not valid #230

Closed
mehrdadphp opened this issue Apr 10, 2019 · 11 comments
Closed

Signature for this request is not valid #230

mehrdadphp opened this issue Apr 10, 2019 · 11 comments

Comments

@mehrdadphp
Copy link

mehrdadphp commented Apr 10, 2019

hi

i am call withdraw method

try {
   $api->withdraw($asset, $address, $amount);
} catch (\Exception $e) {
     vardump($e);
}

return for request :

signedRequest error: {"msg":"Signature for this request is not valid.","success":false}

Can anyone help me?

tank you

@Marc008
Copy link

Marc008 commented Apr 11, 2019

Hello @mehrdadphp ,

I saw that response from Binance when my API key/secret pair was no longer valid.

Best.

@mehrdadphp
Copy link
Author

tanks @Marc008 for answer

It's strange to me that the rest of the methods work well, like ‍‍‍‍deposit , withdrawaHistory and ...

just for withdraw problem .
with key/secret use nodejs and test withdraw Worked well

@tedy5
Copy link

tedy5 commented Apr 29, 2019

Same here. Everything else works except withdrawal.

@aliromero
Copy link

not work withdrawal :
{"msg":"Signature for this request is not valid.","success":false}

@Libre12
Copy link

Libre12 commented Jul 1, 2019

Same here, and yes my API details are valid and correct (I just created and it's working for other functions).

There's something wrong with the withdraw function only.

Did anyone figure it out yet?

Does it have anything to do with the ca.pem file?

Any clues appreciated.

Thanks

@alfredogarc
Copy link

I have the same problem

@NicolaszHD
Copy link

i have this problem when i make
$binance->withdraw("XLM", $address, $pre, $memoid);

{"msg":"Signature for this request is not valid.","success":false}
one can help me??

@rxcod9
Copy link
Contributor

rxcod9 commented Aug 28, 2019

Checkout this PR
#248
Solved

@pfergi42
Copy link

This problem just started occurring for us. GetBalance, MarketBuy and MarketSell all work fine.

Only Withdraw is giving us:
signedRequest error: {"msg":"Signature for this request is not valid.","success":false}

Anyone know why this would start happening all of a sudden?

@2pd
Copy link

2pd commented Jul 14, 2020

https://github.com/jaggedsoft/php-binance-api/blob/master/php-binance-api.php#L590
The default name API Withdraw with space caused this problem.

# this should work
$response = $api->withdraw($asset, $address, $amount, null, 'my_address');

Reason:

In this name parameter, space has to be encoded into %20, but now i think it's encoded into +, which cause signature invalid.

@pfergi42
Copy link

Reason:

In this name parameter, space has to be encoded into %20, but now i think it's encoded into +, which cause signature invalid.

Thank you @2pd! This solved the problem. I'd suggest just replacing the space in the default "API Withdraw" with an underscore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests