Web Sockets for servers

I’m actually really intrigued by this idea. I really like the idea of being able to stream data from the server, because it will enable developers to make more dynamic external services. For instance, you’d be able to make a dynamic matchmaking system across servers, or a cross-server chat.
The idea of a dynamic global economy has also struck my mind, but it wouldn’t be very easy to do RESTfully.

Support :thumbsup:

2 Likes

I’m not sure how it’d work API- and security-wise, but I like the idea.

3 Likes

This idea was rejected for security reasons, sorry everyone!

2 Likes

Is there another method we could possibly get that would allow our own servers to send messages to the roblox servers? That is really what is needed right now. Hence why I posted this.

Perhaps can you give an example of the security issues? Just wondering.

16 Likes

@Mr_Purrsalot Hey, you wanted me to ping

4 Likes

Thanks for sharing the original article with me.

17 Likes

Bump because I wonder if there was/can/will be a reconsideration for websocket support.
As of right now there is a hacky way to do websockets but its extremely limited and connection can be easily lost, and with this thread being created almost ten years ago roblox has come a long way since then, is there really no secure way of making websocket support? I see that in 2021 at least one roblox staff was peering at this thread but I feel like it has been forgotten.

Also websocket support would be insanely beneficial for games since third party servers can process things much much faster than lua can, such as calculations involving nested loops.

2 Likes

You could use MessagingService OpenCloud API to send data from an external server to a roblox server and any roblox server to external server can be done through normal post requests using HttpService

Using a get/post request for receiving messages would require polling, and that creates unnecessary traffic. Websockets would be ideal. There is a reason services like discord use websockets to push events. I want more realtime/frequent applications for it.

2 Likes

You don’t need to use get/post to receive messages on the roblox server, you would just connect to the Topic using MessagingService

that doesn’t apply to what I would use it for.

Hey, I’m wondering if using HttpService + the Open Cloud messaging API can address your use cases?

MessagingService APIs (and it’s Open Cloud counterparts) are experience-wide with experience-wide rate limits. I think what most of here want is the ability to create a real-time & 2-way connection between a (external) server and a roblox server.

5 Likes

technically it’s a problem, if basic http requests have a low ratelimit, there’s a reason for it

I disagree. This is an enormous security risk foir my game and will compromise its security.

Then properly secure your game

5 Likes

exactly. there is a reason major companies including ones of game development use such programs. it can’t really hurt to use, just needs a good implementation

2 Likes

How will this compromise your game? You don’t have to use websockets.

4 Likes

Greetings! I’ve been researching methods of real-time communication between ROBLOX servers and external web servers, and wanted to throw my two cents in here.

Currently, while the method of the Open Cloud Messaging API is very nice from a development standpoint, the application I’m developing will require our end users to attempt to issue API keys to the platform, for every game the system is active in. Being able to connect to a Web Socket server from any game and transferring data that way, would make things extraordinarily easier on myself and the application’s end users. I’m personally not sure of any extra security risks this poses other than what HTTP / the MessagingService API already presents, but if possible I’d like to hear other opinions on this.

Is your only issue with the Messaging API the difficulty to issue API keys? Wouldn’t it be more feasible then to suggest a more simplified API issuing flow?

Using the Messaging API is effectively free money: you don’t have to pay infrastructure or handle scaling (thousands of connections will get heavy). Use it to your advantage!