mirror of
https://github.com/LukeHagar/discoursejs.git
synced 2025-12-06 12:27:48 +00:00
1.4 KiB
1.4 KiB
Site
(site)
Available Operations
- getSite - Get site info
getSite
Can be used to fetch all categories and subcategories
Example Usage
import { SDK } from "@lukehagar/discoursejs";
async function run() {
const sdk = new SDK();
const res = await sdk.site.getSite();
if (res.statusCode == 200) {
// handle response
}
}
run();
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
config |
AxiosRequestConfig | ➖ | Available config options for making requests. |
Response
Promise<operations.GetSiteResponse>
Errors
| Error Object | Status Code | Content Type |
|---|---|---|
| errors.SDKError | 4xx-5xx | / |