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

403 FORBIDDEN #8

Open
rgbnhtrfcxs opened this issue Jan 7, 2020 · 5 comments
Open

403 FORBIDDEN #8

rgbnhtrfcxs opened this issue Jan 7, 2020 · 5 comments

Comments

@rgbnhtrfcxs
Copy link

Im getting the 403 message, Im not sure what to do.

@hatzkel
Copy link

hatzkel commented Jan 7, 2020

If you are on Bitmex make sure the API key is order instead of "order cancel" which means cancel only.

@robswc
Copy link
Owner

robswc commented Jan 12, 2020

hey, were you able to find the solution to this? what address did you get the error on?

@esturilio
Copy link

esturilio commented Jan 15, 2020

Potential issues here:

A) PIN CODE
Maybe you have just copied/pasted the example alert message template?

This may be due to the verification hash generated from the PIN code in
https://github.com/Robswc/tradingview-webhooks-bot/blob/079f50343fe77bbd03cb8f62fc04e332d3a08395/tradingview-webhooks-bot/auth.py#L14

Suggestion:

  1. enter your own PIN to generate your own hash in auth.py
  2. move generate_alert_message.py to main folder
  3. execute generate_alert_message.py to generate the template alert message
  4. paste the generated template message on TV (this one contains your hashed key)

B) HOOKING

Another thing is: using the generated template will make TV send the POST as JSON. If you're not hooking via ngrok, line 30 won't work. You have to:

  1. add the following on the import section of webhook-bot.py:
    import json

  2. change
    https://github.com/Robswc/tradingview-webhooks-bot/blob/079f50343fe77bbd03cb8f62fc04e332d3a08395/tradingview-webhooks-bot/webhook-bot.py#L30

to:
data = json.loads(request.data,encoding='utf-8')

@alperoguz
Copy link

alperoguz commented Dec 2, 2020

Hello @esturilio
I don't use ngrok and when the alert received from Tradingview, webhooks continuously giving http 405.

I entered an unique key to PIN, not from Bitmex secret etc. And ran generate_alert_message.py, got the line like below. I copied this line into TV alert message box. Is this correct?

{"type": "market", "side": "buy", "amount": "500", "symbol": "XBTUSD", "price": "None", "key": "90fca5b............"}

Also, I am not sure that understand your B) part. I only replaced 30th line with below, but problem persist.

data = json.loads(request.data,encoding='utf-8')

thanks

@minimalist15
Copy link

i have the same problem as i dont get an output with they to use

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

No branches or pull requests

6 participants