wire-api-0.1.0
Safe HaskellSafe-Inferred
LanguageGHC2021

Wire.API.Routes.Public.Gundeck

Documentation

type PushAPI = Named "register-push-token" (Summary "Register a native push token" :> (ZUser :> (ZConn :> ("push" :> ("tokens" :> (ReqBody '[JSON] PushToken :> MultiVerb 'POST '[JSON] AddTokenResponses (Either AddTokenError AddTokenSuccess))))))) :<|> (Named "delete-push-token" (Summary "Unregister a native push token" :> (ZUser :> ("push" :> ("tokens" :> (Capture' '[Description "The push token to delete"] "pid" Token :> MultiVerb 'DELETE '[JSON] DeleteTokenResponses (Maybe ())))))) :<|> Named "get-push-tokens" (Summary "List the user's registered push tokens" :> (ZUser :> ("push" :> ("tokens" :> Get '[JSON] PushTokenList))))) Source #

type NotificationAPI = Named "get-notification-by-id" (Summary "Fetch a notification by ID" :> (ZUser :> ("notifications" :> (Capture' '[Description "Notification ID"] "id" NotificationId :> (QueryParam' [Optional, Strict, Description "Only return notifications targeted at the given client"] "client" ClientId :> MultiVerb 'GET '[JSON] '[ErrorResponse 'NotificationNotFound, Respond 200 "Notification found" QueuedNotification] (Maybe QueuedNotification)))))) :<|> (Named "get-last-notification" (Summary "Fetch the last notification" :> (ZUser :> ("notifications" :> ("last" :> (QueryParam' [Optional, Strict, Description "Only return notifications targeted at the given client"] "client" ClientId :> MultiVerb 'GET '[JSON] '[ErrorResponse 'NotificationNotFound, Respond 200 "Notification found" QueuedNotification] (Maybe QueuedNotification)))))) :<|> (Named "get-notifications@v2" (Summary "Fetch notifications" :> (Until 'V3 :> (ZUser :> ("notifications" :> (QueryParam' [Optional, Strict, Description "Only return notifications more recent than this"] "since" RawNotificationId :> (QueryParam' [Optional, Strict, Description "Only return notifications targeted at the given client"] "client" ClientId :> (QueryParam' [Optional, Strict, Description "Maximum number of notifications to return"] "size" (Range 100 10000 Int32) :> MultiVerb 'GET '[JSON] '[Respond 404 "Notification list" QueuedNotificationList, Respond 200 "Notification list" QueuedNotificationList] GetNotificationsResponse))))))) :<|> Named "get-notifications" (Summary "Fetch notifications" :> (From 'V3 :> (ZUser :> ("notifications" :> (QueryParam' [Optional, Strict, Description "Only return notifications more recent than this"] "since" NotificationId :> (QueryParam' [Optional, Strict, Description "Only return notifications targeted at the given client"] "client" ClientId :> (QueryParam' [Optional, Strict, Description "Maximum number of notifications to return"] "size" (Range 100 10000 Int32) :> MultiVerb 'GET '[JSON] '[ErrorResponse 'NotificationNotFound, Respond 200 "Notification list" QueuedNotificationList] (Maybe QueuedNotificationList)))))))))) Source #