Skip to content

Commit 858728c

Browse files
authored
basic HTTP authentication
1 parent 5187138 commit 858728c

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

docs/Reference.mdx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,11 @@ Starting in API v8, we've improved error formatting in form error responses. The
101101

102102
## Authentication
103103

104-
Authenticating with the Discord API can be done in one of two ways:
104+
Authenticating with the Discord API can be done in one of three ways:
105105

106106
1. Using a bot token found on the **Bot** page within your app's settings. For more information on bots see [bots vs user accounts](#DOCS_TOPICS_OAUTH2/bot-vs-user-accounts).
107107
2. Using an OAuth2 bearer token gained through the [OAuth2 API](#DOCS_TOPICS_OAUTH2/oauth2).
108+
3. Using basic authentication with a client ID and client client found on the **OAuth2** page within your app's settings in the format `client_id:client_secret` as a Base64 encoded string. Only applicable for the [OAuth2 API](#DOCS_TOPICS_OAUTH2/shared-resources-oauth2-urls) token URLs.
108109

109110
For all authentication types, authentication is performed with the `Authorization` HTTP header in the format `Authorization: TOKEN_TYPE TOKEN`.
110111

@@ -120,6 +121,12 @@ Authorization: Bot MTk4NjIyNDgzNDcxOTI1MjQ4.Cl2FMQ.ZnCjm1XVW7vRze4b7Cq4se7kKWs
120121
Authorization: Bearer CZhtkLDpNYXgPH9Ml6shqh2OwykChw
121122
```
122123

124+
###### Example Basic Token Authorization Header
125+
126+
```
127+
Authorization: Basic MTk4NjIyNDgzNDcxOTI1MjQ4OlEzS052N0NSRW5DYS1nS0xMajFEOGV1ZFl1SmZ1Nm96
128+
```
129+
123130
## Encryption
124131

125132
All HTTP-layer services and protocols (e.g. HTTP, WebSocket) within the Discord API are using TLS 1.2.

0 commit comments

Comments
 (0)