Anybody having Idea on AMIBROKER issuing SMS on Signals Generation....!!!!!

pkgmtnl

Well-Known Member
#1
Dear Friends,
Does any1 have any Idea on any Vendor providing Plugin or Gateway or otherwise, which can generate SMS in Indian Subcontinent?

I came across a website tradesender(dot)com but thats not for Indian Sub continent.

Any1 having any info Please guide/ share.

thnx.
 

mastermind007

Well-Known Member
#3
Dear Friends,
Does any1 have any Idea on any Vendor providing Plugin or Gateway or otherwise, which can generate SMS in Indian Subcontinent?

I came across a website tradesender(dot)com but thats not for Indian Sub continent.

Any1 having any info Please guide/ share.

thnx.
Dig around in the websites that offer free sms in India; From programming point of view, sending SMS is logically similar to sending email (with very strict restriction on size).

Since Amibroker can send emails, Amibroker can send SMS too...
 

ajeetsingh

Well-Known Member
#4
If you have access to Net on phone then go for "PushBullet"
Its free and very fast.
I have tested it and signals flashes almost immediately on phone(Iphone/Android)+DeskTop(Chrome)
If you need assistance on how to configure then here's the process:

1)Download Pushbullet Android/IOS App according to your smartphone device where you to receive push notification from Amibroker Software. If you wanna recieve alerts in your Desktop or Browser or to receive alerts from someone else Pushbullet channel you can download the Browser extention from the link here

2)Sign in with Pushbullet using your Google Login.

3)Once Signed in click over your profile pic and goto account settings. Now copy the Access Token which is unique code to communicate with your device and keep it safe.

4)Now make sure that your Trading System supports Buy/Sell Variables minimum to pass Buy/Sell Alerts. If you need to send Short/Cover/any other variables then you need to build your own custom code according to your requirements. In this example we focused only on alerting with simple Buy/Sell Variable.

5)Copy the AFL code and save it as pushbullet.afl code in your //Amibroker//Formulas//system folder

Code:
_SECTION_BEGIN("PushBullet");
	
EnableScript("VBScript"); 
 
 <% 
 
Public Sub pushbullet(Message_Text)
Dim Message 
 
'Your Message 
Message =  Message_Text
 
Dim objXmlHttpMain , URL
 
strJSONToSend = "{""type"": ""note"", ""title"": ""Alert"", ""body"":""" &Message_Text&"""}"
 
URL="https://api.pushbullet.com/v2/pushes" 
Set objXmlHttpMain = CreateObject("Msxml2.ServerXMLHTTP") 
on error resume next 
objXmlHttpMain.open "POST",URL, False 
objXmlHttpMain.setRequestHeader "Authorization", "Bearer xxxxxxxxxxxxxxxxxxx"
objXmlHttpMain.setRequestHeader "Content-Type", "application/json"
 
 
objXmlHttpMain.send strJSONToSend
 
set objJSONDoc = nothing 
set objResult = nothing
 
'Store response 
'msgbox(objXmlHttpMain.responseText)
'response.Write (objXmlHttpMain.responseText) 
alert("Hi")
End Sub 
 
 %> 
 
pb = GetScriptObject(); 
 
 
 
if (LastValue(ValueWhen(Ref(Buy,-1),BarIndex())==BarIndex()) AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
	pb.PushBullet("Buy Alert in " +Name() +  " :  BuyPrice Value is "   + BuyPrice +  " Time " + TimeNum());
	StaticVarSet(Name()+ GetChartID() + "buyAlertBar", LastValue(TimeNum()));
}
 
if (LastValue(TimeNum()) == StaticVarGet(Name()+GetChartID()+"buyAlertBar"))
	
	StaticVarSet(Name()+GetChartID()+"buyAlert",1); //alert was triggered, no more alerts on this bar
else
	StaticVarSet(Name()+GetChartID()+"buyAlert",0); // new bar formed, and alerts can be trigered.
 
if (LastValue(ValueWhen(Ref(Sell,-1),BarIndex())==BarIndex()) AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
	pb.PushBullet("Sell Alert in " +Name() +  " :  SellPrice Value is "   + SellPrice +  " Time " + TimeNum());
	StaticVarSet(Name()+ GetChartID() + "sellAlertBar", LastValue(TimeNum()));
}
 
if (LastValue(TimeNum()) == StaticVarGet(Name()+GetChartID()+"sellAlertBar"))
	
	StaticVarSet(Name()+GetChartID()+"sellAlert",1); //alert was triggered, no more alerts on this bar
else
	StaticVarSet(Name()+GetChartID()+"sellAlert",0); // new bar formed, and alerts can be trigered.
 
_SECTION_END();
6)Now Replace xxxxxxxxxxxxxx in line 25 with your Secure Access token

7)Now Drag and Drop the pushbullet.afl code to your Trading System Charts which contains Buy/Sell Variables. Note you have to do a drag and drop to your existing trading system annd not to insert the afl code

8)Bingo you are done now get alerts to your mobile/desktop/laptop devices(one or multiple devices) and stay connected with your trading system even you are out of your trading system

-All credits to original poster
I have just copy pasted from Net and using it.
 

pkgmtnl

Well-Known Member
#6
Sir,
I am facing issues on following steps, please guide:

" 2)Sign in with Pushbullet using your Google Login.

3)Once Signed in click over your profile pic and goto account settings. Now copy the Access Token which is unique code to communicate with your device and keep it safe.
"""
I am able to login into PushBullet with Gmail Login, but how to get the access code?

Please guide on it.

Thanks
 

pkgmtnl

Well-Known Member
#8
If you have access to Net on phone then go for "PushBullet"
Its free and very fast.
I have tested it and signals flashes almost immediately on phone(Iphone/Android)+DeskTop(Chrome)
If you need assistance on how to configure then here's the process:

1)Download Pushbullet Android/IOS App according to your smartphone device where you to receive push notification from Amibroker Software. If you wanna recieve alerts in your Desktop or Browser or to receive alerts from someone else Pushbullet channel you can download the Browser extention from the link here

2)Sign in with Pushbullet using your Google Login.

3)Once Signed in click over your profile pic and goto account settings. Now copy the Access Token which is unique code to communicate with your device and keep it safe.

4)Now make sure that your Trading System supports Buy/Sell Variables minimum to pass Buy/Sell Alerts. If you need to send Short/Cover/any other variables then you need to build your own custom code according to your requirements. In this example we focused only on alerting with simple Buy/Sell Variable.

5)Copy the AFL code and save it as pushbullet.afl code in your //Amibroker//Formulas//system folder

Code:
_SECTION_BEGIN("PushBullet");
	
EnableScript("VBScript"); 
 
 <% 
 
Public Sub pushbullet(Message_Text)
Dim Message 
 
'Your Message 
Message =  Message_Text
 
Dim objXmlHttpMain , URL
 
strJSONToSend = "{""type"": ""note"", ""title"": ""Alert"", ""body"":""" &Message_Text&"""}"
 
URL="https://api.pushbullet.com/v2/pushes" 
Set objXmlHttpMain = CreateObject("Msxml2.ServerXMLHTTP") 
on error resume next 
objXmlHttpMain.open "POST",URL, False 
objXmlHttpMain.setRequestHeader "Authorization", "Bearer xxxxxxxxxxxxxxxxxxx"
objXmlHttpMain.setRequestHeader "Content-Type", "application/json"
 
 
objXmlHttpMain.send strJSONToSend
 
set objJSONDoc = nothing 
set objResult = nothing
 
'Store response 
'msgbox(objXmlHttpMain.responseText)
'response.Write (objXmlHttpMain.responseText) 
alert("Hi")
End Sub 
 
 %> 
 
pb = GetScriptObject(); 
 
 
 
if (LastValue(ValueWhen(Ref(Buy,-1),BarIndex())==BarIndex()) AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
	pb.PushBullet("Buy Alert in " +Name() +  " :  BuyPrice Value is "   + BuyPrice +  " Time " + TimeNum());
	StaticVarSet(Name()+ GetChartID() + "buyAlertBar", LastValue(TimeNum()));
}
 
if (LastValue(TimeNum()) == StaticVarGet(Name()+GetChartID()+"buyAlertBar"))
	
	StaticVarSet(Name()+GetChartID()+"buyAlert",1); //alert was triggered, no more alerts on this bar
else
	StaticVarSet(Name()+GetChartID()+"buyAlert",0); // new bar formed, and alerts can be trigered.
 
if (LastValue(ValueWhen(Ref(Sell,-1),BarIndex())==BarIndex()) AND StaticVarGet(Name()+GetChartID()+"buyAlert")==0 )
{
	pb.PushBullet("Sell Alert in " +Name() +  " :  SellPrice Value is "   + SellPrice +  " Time " + TimeNum());
	StaticVarSet(Name()+ GetChartID() + "sellAlertBar", LastValue(TimeNum()));
}
 
if (LastValue(TimeNum()) == StaticVarGet(Name()+GetChartID()+"sellAlertBar"))
	
	StaticVarSet(Name()+GetChartID()+"sellAlert",1); //alert was triggered, no more alerts on this bar
else
	StaticVarSet(Name()+GetChartID()+"sellAlert",0); // new bar formed, and alerts can be trigered.
 
_SECTION_END();
6)Now Replace xxxxxxxxxxxxxx in line 25 with your Secure Access token

7)Now Drag and Drop the pushbullet.afl code to your Trading System Charts which contains Buy/Sell Variables. Note you have to do a drag and drop to your existing trading system annd not to insert the afl code

8)Bingo you are done now get alerts to your mobile/desktop/laptop devices(one or multiple devices) and stay connected with your trading system even you are out of your trading system

-All credits to original poster
I have just copy pasted from Net and using it.
Please advise, how to add SHORT & COVER syntax?
 

pkgmtnl

Well-Known Member
#9
One difficulty is being faced in SELL signals only , that Same Message is coming up unlimited.
This problem is with SELL only, in case of BUY is ok & comes once only.

Any advise.
 

Attachments

ajeetsingh

Well-Known Member
#10
Code:
if (LastValue(TimeNum()) == StaticVarGet(Name()+GetChartID()+"sellAlertBar"))	
	StaticVarSet(Name()+GetChartID()+"sellAlert",1); //alert was triggered, no more alerts on this bar
else
	StaticVarSet(Name()+GetChartID()+"sellAlert",0); // new bar formed, and alerts can be trigered.
This code is already present in the end, which stops multiple signals.........
 

Similar threads