Announcing Messaging Service API for Open Cloud

I posted my code above, all I did was just changing the POSTing and double check if everything was correct, thats all

2 Likes

Do you mind showing the full code, so i can get some context (please censor api key btw)

2 Likes

For the 500 response, I think your body portion may not be defined properly, could you define it in JSON format and try again?

{"message":"<your actual message encoded in string>"}

We improved our end to return a 400 response code in these cases.

3 Likes

Looks like the docs page still isn’t on the index/overview page for Open Cloud.

2 Likes

This addition is incredible! Will the ability to promote & demote group members, posting shouts to a group, and reading group data such as the group wall be added alongside Open Cloud? This would mean endless possibilities for larger communities where manual promotions would be a hassle!

Currently, we have to use Cookies and an X-Crsf-Tokens to do such requests unless if there’s already support for it that I’m not aware of. I’m sure that many developers who do not use external libraries, like Noblox, for their projects would greatly appreciate the group management addition to Open Cloud!

2 Likes

Yep, this docs will be updated within a few days.

1 Like

The end goal is to have all available Roblox APIs onboard onto Open Cloud!

5 Likes

yes thanks that was the solution to my problem! I didn’t know it was the body formatting wrong as i thought it should’ve returned a 400 error.

2 Likes

Using a get/post request for receiving messages would require polling, and that creates unnecessary traffic. Websockets or some other way for roblox to send messages instead of us polling for messages would be ideal. There is a reason services like discord use websockets to push events.

2 Likes

Any ETA on when this will be made available for models and packages?
Presently we have to use a bot account cookie to manage our rojo package uploads.

2 Likes

Unfortunately we don’t have ETAs but we have been thinking about these specific entities to add to our suite of APIs. As we formulate more concrete plans, we’ll definitely let the community know.

3 Likes

This is incredible, it’s another API that I can take advantage of for an upcoming project. I wonder when group management will be next, as with that, I won’t need cookie authentication anymore

1 Like

I’m a bit unfamiliar with messaging service. Should I expect this to work for a place running inside Studio, or only on real game servers?

For now, it only sends to live game servers. Messaging to Studio will be supported later.

1 Like

I keep on getting “Request body not in correct format.” 400
what am i doing wrong??

header = {
'x-api-key':apikey,
'Content-Type':'application/json'}
url = 'https://apis.roblox.com/messaging-service/v1/universes/{}/topics/{}'.format(universeid,topic)
tosend =   {
    "message":'hi'
}
response = requests.post(url,data=tosend,headers=header)
print('>>sent! ', response.text,response.status_code)
1 Like

Is there any way to run sent messages through the chat filter?

1 Like

I would try json=tosend instead of data=tosend

1 Like

You can try using TextService on the receipt handler in SubscribeAsync

1 Like

I am still very much looking forward to trying Open Cloud one day. All this functionality sounds great.

Our game (aka universe) doesn’t appear in search when trying to set Place Permissions for an API key. This affects any API System including DataStore, Messaging Service and Place Publishing.

Does anyone know why?

We have other games (like Dev/Beta environments) that will show up in search. It’s only our main public game that doesn’t appear.

You may think it’s to do with the use of Emoji, but I have even tried removing the emoji to no avail.

Like a few people upthread, I’m also only getting 400 Bad Request when trying to set the message field to a json object. It works as expected when message is a string, number, or bool.

It isn’t clear if this is intended but it isn’t mentioned in the documentation.

Example curl commands:

curl -v \
	--location --request POST 'https://apis.roblox.com/messaging-service/v1/universes/3729025203/topics/{topic}' \
--header 'x-api-key: hunter2' \
--header 'Content-Type: application/json' \
--data-raw '{"message":"This gets a 200"}'
curl -v \
	--location --request POST 'https://apis.roblox.com/messaging-service/v1/universes/3729025203/topics/{topic}' \
--header 'x-api-key: hunter2' \
--header 'Content-Type: application/json' \
--data-raw '{"message":{"a":"This gets a 400"}}'
2 Likes