Introduction

The DaalBot API is a RESTful API that allows you to interact with the DaalBot Discord bot. Some of the routes are public and do not require authentication, while others require you to authenticate with the discord oauth tokens (Learn more in the Authentication section).

The API is hosted at api.daalbot.xyz and routes follow the /[METHOD]/[CATEGORY]/[ITEM]/ format for unauthorized routes and /dashboard/[CATEGORY]/[ITEM]/ for authorized routes.


Authentication

The DaalBot API relies on the Discord OAuth2 system for authentication. However, you can't use any discord oauth token to authenticate with the API. You need to use the token that was generated when you authorized the DaalBot application.

DaalBot can share the token with your service by redirecting the user to https://daalbot.xyz/Dashboard/User/get-token with the query parameter return set to the URL you want the user to be redirected to after the token is shared (You can also set a name parameter to replace the URL in the page although the url will be visible still to prevent fake urls). If the user accepts, they will be redirected to your URL with the query parameter accesscode set to the access code. However if the user denies, they will be redirected to your URL and the code parameter will be set to denied.

You can then use the access code in the Authorization header to authenticate with the API.


Routes

The following are the routes that are available in the DaalBot API.


Release: | You can click on the route to view the source code on GitHub or click the background to view the parameters and other info.

Replies with "pong" if the API is working

Parameters

Name Description
none No parameters required