Jump to content

output discord message on mta server


JeViCo

Recommended Posts

  • Moderators

You probably will need modules for the communication between your bot to discord. There must be a lot of security stuff in it, so you do not want without that. https://discord.js.org/#/

From your bot to MTA, a socket is not required. Nodejs has a build in module https, which you can use.

https://www.twilio.com/blog/2017/08/http-requests-in-node-js.html

 

And on the MTA side:

There you can create your HTML file which you can use to receive requests.

https://wiki.multitheftauto.com/wiki/Resource_Web_Access

 

table form: This is a table containing all the form data submitted to the page using HTTP POST combined with any variables passed in the querystring with HTTP GET.

The variable form should be available in your HTML file which can contain the message data from a post request.

 

It can be complicated stuff if you haven't worked without sockets before. But that doesn't mean that you should give up.

 

 

 

 

 

 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...