What about for things such as currency api, that need to know the user?
Well, One of the two ways to create an API Key is to create it under a specific account, so I’m assuming that anyone using the API Key created under that specific account (and if the IP that’s being used is whitelisted) can interact with APIs that need to know the user.
What was wrong with just using .ROBLOSECURITY cookie? (and, a little off-topic, but why isn’t it called .ROBLOXSECURITY instead?)
Edit: Is it because RobloSecurity expires?
Unreliable for many reasons. One of the major ones being this.
You can also whitelist only certain IP Addresses that are able to use the API Key. This is useful because if someone were to get a hold of your API Key, they wouldn’t be able to use it if they aren’t on the correct IP Address.
You don’t have that advantage when using cookies.
No clue on that one.
Isn’t that the same exact functionality? If someone tries the .RobloSecurity on a different IP than initially logged in with, it doesn’t let them? (Well besides that you can’t use it again.)
My guess is that maybe cookies have (or had) a character limit.
Oh so does this allow for things to happen externally when something is published with messaging service?
Well, when someone tries to login from a different IP Address with the cookie, it invalidates itself, making it useless.
With API Keys, that won’t happen. The API Keys will only work on the specified IP Addresses.
Hello everyone! I saw some of you find the tutorial/API docs hard to read so due to this I have made a tutorial based in node.js if anyone want to check it out. I have broken down the API in bits so it should be easy to understand.
Really beautiful and detailed tutorial!
+kudos to you for taking your time with this, your tutorial will for sure help many people
Sorry for bumping this thread, but had some issues regarding MessagingService. The SubscribeAsync function doesn’t respond at all. I tried debugging but nothing works. Can anybody tell how should I actually arrange my code (in roblox studio)?
I am not getting stuff to work, I get proper response and everything, but roblox does not seem to listen to requests at all.
Code in roblox:
messagingService:SubscribeAsync("among", function(msg)
print('test')
print(msg.Data)
end)
How i send requests:
const fetch = require("node-fetch")
async function s() {
const res = await fetch(url, {
method: "POST",
headers: headers,
body: {message: 'test'}
})
console.log(res)
}
s()
the URL looks like this: https://apis.roblox.com/messaging-service/v1/universes/4139112970/topics/among
(got it to work)
I am receiving code 500 (Internal Server Error) when trying to publish a message now. Is there a ongoing issue at the moment?
I am trying to use publish/save/publishTopic open cloud services provided by roblox. It use to work a few days ago, but recently it started to give me 500 internal errors… Not sure why, nothing has changed and was wondering if it was a roblox issue?
[Symbol(kOutHeaders)]: [Object: null prototype] {
accept: [ 'Accept', 'application/json, text/plain, */*' ],
'content-type': [ 'Content-Type', 'application/json' ],
'x-api-key': [
'x-api-key',
'my-actual-api-key-not-to-be-shared'
],
'user-agent': [ 'User-Agent', 'axios/0.26.1' ],
'content-length': [ 'Content-Length', 27 ],
host: [ 'Host', 'apis.roblox.com' ]
},
[Symbol(kUniqueHeaders)]: null
},
data: { Error: 'Internal', Message: 'Failed to publish message.' }
},
isAxiosError: true,
toJSON: [Function: toJSON]
}
The same happens with a curl command…
I am also having issues with it now, it was working before and now i am receiving the same error as you, i didn’t change anything for that to happen and i believe it was a Roblox change, it would be nice to hear what was changed.
Your api key regenerated I believe.
Seems like message topic is working now, but for save and publish i am still getting 500 status response.
data: {
type: 'https://tools.ietf.org/html/rfc7231#section-6.6.1',
title: 'An error occurred while processing your request.',
status: 500,
traceId: '00-e29fd8c94fcd0113c1bc9b7a39bd64b6-e19f9e3af3b53814-00'
}
Any update regarding this issue? Seems I am still getting a 500 response
The issue is still persisting. Seems to work fine with an rbxlx file but not an rbxm. (using different commands for each)
$ curl --verbose --location --request POST 'https://apis.roblox.com/universes/v1/4092756726/places/11814862877/versions?versionType=Published' \
> --header 'x-api-key: not-to-share' \
> --header 'Content-Type: application/octet-stream' \
> --data-binary @./testrbx.rbxl
Note: Unnecessary use of -X or --request, POST is already inferred.
* Trying 128.116.126.4:443...
* Connected to apis.roblox.com (128.116.126.4) port 443 (#0)
* ALPN: offers h2
* ALPN: offers http/1.1
* CAfile: C:/Program Files/Git/mingw64/ssl/certs/ca-bundle.crt
* CApath: none
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.3 (IN), TLS handshake, Encrypted Extensions (8):
* TLSv1.3 (IN), TLS handshake, Certificate (11):
* TLSv1.3 (IN), TLS handshake, CERT verify (15):
* TLSv1.3 (IN), TLS handshake, Finished (20):
* TLSv1.3 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.3 (OUT), TLS handshake, Finished (20):
* SSL connection using TLSv1.3 / TLS_AES_128_GCM_SHA256
* ALPN: server accepted h2
* Server certificate:
* subject: CN=*.roblox.com
* start date: Jul 18 21:54:17 2022 GMT
* expire date: Aug 13 22:53:34 2023 GMT
* subjectAltName: host "apis.roblox.com" matched cert's "*.roblox.com"
* issuer: C=US; ST=Arizona; L=Scottsdale; O=GoDaddy.com, Inc.; OU=http://certs.godaddy.com/repository/; CN=Go Daddy Secure Certificate Authority - G2
* SSL certificate verify ok.
* Using HTTP2, server supports multiplexing
* Copying HTTP/2 data in stream buffer to connection buffer after upgrade: len=0
* h2h3 [:method: POST]
* h2h3 [:path: /universes/v1/4092756726/places/11814862877/versions?versionType=Published]
* h2h3 [:scheme: https]
* h2h3 [:authority: apis.roblox.com]
* h2h3 [user-agent: curl/7.85.0]
* h2h3 [accept: */*]
* h2h3 [x-api-key: not-to-share]
* h2h3 [content-type: application/octet-stream]
* h2h3 [content-length: 0]
* Using Stream ID: 1 (easy handle 0x29d4e2202d0)
> POST /universes/v1/4092756726/places/11814862877/versions?versionType=Published HTTP/2
> Host: apis.roblox.com
> user-agent: curl/7.85.0
> accept: */*
> x-api-key: dont-share
> content-type: application/octet-stream
> content-length: 0
>
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
* old SSL session ID is stale, removing
< HTTP/2 500
< content-length: 200
< content-type: application/json; charset=utf-8
< date: Tue, 20 Dec 2022 20:51:27 GMT
< server: envoy
< strict-transport-security: max-age=3600
< x-envoy-upstream-service-time: 12
< report-to: {"group":"network-errors","max_age":604800,"endpoints":[{"url":"https://ncs.roblox.com/upload"}]}
< nel: {"report_to":"network-errors","max_age":604800,"success_fraction":0.001,"failure_fraction":1}
<
{"type":"https://tools.ietf.org/html/rfc7231#section-6.6.1","title":"An error occurred while processing your request.","status":500,"traceId":"00-083e609655c805bf633f48e8cacb1278-ae529ea59117521d-00"}* Connection #0 to host apis.roblox.com left intact
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.