Reputation: 41
I want to use Pine script to build a strategy in Tradingview web site, and use outside data. Can Pine script call back outside API?
Upvotes: 4
Views: 6145
Reputation: 161
Simple No! You cant make Api call directly, you can use alert which triggers webhook that you catch and forward to the Api you wanted. But remember webhook is only available in paid version.
Upvotes: 2
Reputation: 739
Maybe you could elaborate on what you mean on "call back outside Api"? Of course you can use Pine Script to create an alertcondition
putting POST data in JSON format in the message
argument and sending it to a webhook URL.
Upvotes: 4