website: latest migration to new structure (#11522)
* first pass
* dependency shenanigans
* move blueprints
* few broken links
* change config the throw errors
* internal file edits
* fighting links
* remove sidebarDev
* fix subdomain
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
* fix relative URL
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
* fix mismatched package versions
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
* fix api reference build
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
* test tweak
* links hell
* more links hell
* links hell2
* yep last of the links
* last broken link fixed
* re-add cves
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
* add devdocs redirects
* add dir
* tweak netlify.toml
* move latest 2 CVES into dir
* fix links to moved cves
* typoed title fix
* fix link
* remove banner
* remove committed api docs
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* integrations: remove version dropdown
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* Update Makefile
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* change doc links in web as well
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* fix some more docs paths
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* fix more docs paths
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* ci: require ci-web.build for merging
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
* Revert "ci: require ci-web.build for merging"
This reverts commit b99a4842a9
.
* remove sluf for Application
* put slug back in
* minor fix to trigger deploy
---------
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
Co-authored-by: Tana M Berry <tana@goauthentik.com>
Co-authored-by: Jens Langhammer <jens@goauthentik.io>
Co-authored-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
This commit is contained in:
47
website/docs/developer-docs/api/websocket.md
Normal file
47
website/docs/developer-docs/api/websocket.md
Normal file
@ -0,0 +1,47 @@
|
||||
---
|
||||
title: Websocket API
|
||||
---
|
||||
|
||||
authentik has two different WebSocket endpoints, one is used for web-based clients to get real-time updates, and the other is used for outposts to report their healthiness.
|
||||
|
||||
### Web `/ws/client/`
|
||||
|
||||
:::info
|
||||
Authentication is done using the session, so make sure to send the `Cookie` header.
|
||||
:::
|
||||
|
||||
All messages have a common field called `message_type` to discern the type of message.
|
||||
|
||||
#### `message` type:
|
||||
|
||||
This type is used when the backend has a notice to show to the user. A full payload looks like:
|
||||
|
||||
```json
|
||||
{
|
||||
"message_type": "message",
|
||||
"level": "error" | "warning" | "success" | "info",
|
||||
"tags": "",
|
||||
"message": "a message",
|
||||
}
|
||||
```
|
||||
|
||||
### Outpost `/ws/outpost/<outpost-uuid>/`
|
||||
|
||||
:::info
|
||||
Authentication is done via the `Authorization` header, same as the regular API. You must send a valid token with a `Bearer ` prefix.
|
||||
:::
|
||||
|
||||
All messages have two fields, `instruction` and `args`. Instruction is any number from this list:
|
||||
|
||||
- `0`: ACK, simply acknowledges the previous message
|
||||
- `1`: HELLO, used for monitoring and regularly sent by outposts
|
||||
- `2`: TRIGGER_UPDATE, sent by authentik to trigger a reload of the configuration
|
||||
|
||||
Arguments for these messages vary, all though these common args are always sent:
|
||||
|
||||
- `args['uuid']`: A unique UUID generated on startup of an outpost, used to uniquely identify it.
|
||||
|
||||
These fields are only sent for HELLO instructions:
|
||||
|
||||
- `args['version']`: Version of the outpost
|
||||
- `args['buildHash']`: Build hash of the outpost, when available
|
Reference in New Issue
Block a user