| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Calamity.HTTP.Webhook
Description
Webhook endpoints
Documentation
data WebhookRequest a where Source #
Constructors
| CreateWebhook :: HasID Channel c => c -> CreateWebhookData -> WebhookRequest Webhook | |
| GetChannelWebhooks :: HasID Channel c => c -> WebhookRequest [Webhook] | |
| GetGuildWebhooks :: HasID Guild c => c -> WebhookRequest [Webhook] | |
| GetWebhook :: HasID Webhook w => w -> WebhookRequest Webhook | |
| GetWebhookToken :: HasID Webhook w => w -> Text -> WebhookRequest Webhook | |
| ModifyWebhook :: HasID Webhook w => w -> ModifyWebhookData -> WebhookRequest Webhook | |
| ModifyWebhookToken :: HasID Webhook w => w -> Text -> ModifyWebhookData -> WebhookRequest Webhook | |
| DeleteWebhook :: HasID Webhook w => w -> WebhookRequest () | |
| DeleteWebhookToken :: HasID Webhook w => w -> Text -> WebhookRequest () | |
| ExecuteWebhook :: HasID Webhook w => w -> Text -> ExecuteWebhookOptions -> WebhookRequest () |
Instances
| Request (WebhookRequest a) a Source # | |
Defined in Calamity.HTTP.Webhook Methods toRoute :: WebhookRequest a -> Route Source # url :: WebhookRequest a -> String Source # toAction :: WebhookRequest a -> Options -> String -> IO (Response ByteString) Source # invokeRequest :: forall (reffs :: [(Type -> Type) -> Type -> Type]). (BotC reffs, FromJSON a) => WebhookRequest a -> Sem reffs (Either RestError a) Source # | |
data CreateWebhookData Source #
Constructors
| CreateWebhookData | |
Instances
data ModifyWebhookData Source #
Constructors
| ModifyWebhookData | |
Instances
data ExecuteWebhookOptions Source #
Constructors
| ExecuteWebhookOptions | |