v0.1.1: add configure() method, wally dependency, project config

This commit is contained in:
2026-02-16 17:58:06 -05:00
parent def085b839
commit e4fa158e8e
3 changed files with 42 additions and 9 deletions
+26 -1
View File
@@ -17,5 +17,30 @@ wally install
## Setup
1. Add your Filoxen API key as a secret named `FILOXEN_API_KEY` in the [Creator Dashboard](https://create.roblox.com) under Secrets.
1. Add your Filoxen API key as a secret in the [Creator Dashboard](https://create.roblox.com) under Secrets (defaults to `FILOXEN_API_KEY`).
2. Make sure `HttpService` is enabled for your game.
## Usage
```luau
local Filoxen = require(path.to.Filoxen)
-- Must be called once before any other function
Filoxen.configure({
baseUrl = "https://your-filoxen-instance.com",
apiKeySecretName = "FILOXEN_API_KEY", -- optional, this is the default
})
-- Fetch 10 random hats
local assets = Filoxen.random(
{ Enum.AssetType.Hat }, -- assetTypeIds
nil, -- maxAssetId
nil, -- minAssetId
10, -- batch
true -- onsale
)
-- Search for assets by name
local results = Filoxen.search("blue hat", Enum.AssetType.Hat.Value)
```