Skip to content

Add option for Roblox API dump source#190

Open
EliTheGingerCat wants to merge 2 commits intoevaera:masterfrom
EliTheGingerCat:feature-configure-api-dump
Open

Add option for Roblox API dump source#190
EliTheGingerCat wants to merge 2 commits intoevaera:masterfrom
EliTheGingerCat:feature-configure-api-dump

Conversation

@EliTheGingerCat
Copy link
Copy Markdown
Contributor

Adds a moonwave.toml setting called apiDumpUrl which can be used to specify from where to grab the Roblox API dump.

If the setting is missing, the plugin defaults to the URL used currently: https://raw.githubusercontent.com/CloneTrooper1019/Roblox-Client-Watch/roblox/API-Dump.json

Testing

Here is a Lune script I used to test that this feature works:

local net = require("@lune/net")
local serde = require("@lune/serde")
local stdio = require("@lune/stdio")

local ARRAY = "$array"

local function JSON_encode(value: {}): string
	local s = serde.encode("json", value)

	s = string.gsub(s, '"' .. ARRAY .. '"', "[]")

	return s
end

local handle = net.serve(8080, function()
	return JSON_encode({
		Classes = ARRAY,
		Enums = ARRAY
	})
end)

stdio.prompt("text", "Press enter to shutdown.")
handle.stop()

Then I added in moonwave.toml:

apiDumpUrl = "http://localhost:8080/"

Closes #136

@EliTheGingerCat
Copy link
Copy Markdown
Contributor Author

I think it is a bit messy how apiDumpUrl is passed around but it works 🤷

@YetAnotherClown YetAnotherClown added the enhancement New feature or request label Jul 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Config Api-Dump.json

2 participants