vodalternatives
2019-05-22 07:35:09
I use to push notification each time now this is super cool. Thanks for the information.
2019-05-22 07:35:09
2019-07-19 14:59:43
const DiscordWebhookURL := 'url';
Procedure SendDiscordWebhook(JSON: string);
var
HTTPClient: Integer;
begin
HTTPClient := InitializeHTTPClient(False);
PostHTTPPage(HTTPClient, DiscordWebhookURL, '{"content" : "['+ FormatDateTime('tt', Time) + ']\n' + JSON + '"}'); //Just added current time
FreeHTTPClient(HTTPClient);
end;
SendDiscordWebhook(+'Not mining'); //Notice the '+' in front
2019-07-21 03:15:46
program new;
const
DiscordWebhookURL = 'http://discordapp.com/api/webhooks/602319574863708171/gVoLTLYGghVdhz_XX-6sabstnvOtRdGyOhkhUhpUW0yG0O9TH_74SFgmxTlA99qnyaj8';
DiscordWebhookJSON = '{"content" : "Test"}';
Procedure SendDiscordWebhook(WebhookURL, JSON: string);
var
HTTPClient: Integer;
begin
HTTPClient := InitializeHTTPClient(False);
writeln(HTTPClient);
PostHTTPPage(HTTPClient, WebhookURL, JSON);
writeln(GetHTTPPage(HTTPClient, DiscordWebhookURL));
FreeHTTPClient(HTTPClient);
end;
Procedure Terminator();
begin
SendDiscordWebhook(DiscordWebhookURL, DiscordWebhookJSON);
end;
begin
AddOnTerminate('Terminator'); //whenever the script terminates [safely], the Terminator() procedure will be called
SendDiscordWebhook(DiscordWebhookURL, DiscordWebhookJSON);
//rest of the script
end.
2019-07-21 10:31:08
From: Dan the man
Hey guys.
I have tried doing the above examples without any luck.
Anyone mind telling me what I am doing wrong?
Not getting any data coming through on the channel at all.
2019-07-21 11:20:49
From: Citrus
That's weird. I copy/pasted your code and just replaced the url with my own and it worked perfectly. Tried with your url and it failed. Maybe try to generate a new webhook url?
2019-07-21 23:51:41
From: Citrus
That's weird. I copy/pasted your code and just replaced the url with my own and it worked perfectly. Tried with your url and it failed. Maybe try to generate a new webhook url?
2019-07-31 18:17:55
From: Dan the man
EDIT: If you are having the same issue as me, the problem was Simba 1.2. There is a bug that prevents it from sending the hook. Use Simba 1.3 or 1.1.
2019-07-31 22:13:13
2022-07-15 16:07:11