glyph/clients/api
This contains the client for communicating with Discord’s REST API.
Types
pub type APIClient {
APIClient(
token_type: rest.TokenType,
token: String,
client_url: String,
client_version: String,
)
}
Constructors
-
APIClient( token_type: rest.TokenType, token: String, client_url: String, client_version: String, )
Functions
pub fn create_message(
c: APIClient,
channel_id: String,
message: MessagePayload,
) -> Result(Nil, APIError)
pub fn get_application(
c: APIClient,
) -> Result(Application, APIError)
pub fn get_gateway_bot(
c: APIClient,
) -> Result(GetGatewayBot, APIError)