Skip to content

Commit b0fd882

Browse files
Merge pull request #7616 from segmentio/DOC-1104
OAuth docs improvements [DOC-1104]
2 parents 21e9b7d + 7c34076 commit b0fd882

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

src/connections/oauth.md

+9-6
Original file line numberDiff line numberDiff line change
@@ -96,14 +96,17 @@ To obtain the access token:
9696
}
9797
```
9898
99+
Unless otherwise specified, all fields are mandatory.
100+
99101
Field | Description
100102
------------ | -------------
101-
KID | The key ID of the public key in the OAuth application.
102-
ISS | The identifier of the JWT issuer.
103-
SUB | The OAuth application ID.
104-
IAT | The epoch time in seconds when the token was issued.
105-
EXP | The expiry time in seconds. This is expected to be valid only for a short duration under a minute.
106-
JTI | The unique identifer for the token.
103+
KID | The key ID of the public key in the OAuth application. You can find this value in the Segment app by navigating to the Access Management tab and selecting the OAuth app you created. On the Overview tab for your OAuth app, you'll find your Key ID.
104+
ISS | _(Optional)_ The identifier of the JWT issuer. This value is `https://oauth2.segment.io` if you're located in the US, or `https://oauth2.eu1.segmentapis.com` if you're located in the EU.
105+
SUB | The OAuth application ID. You can find this value in the Segment app by navigating to the Access Management tab and selecting the OAuth app you created. On the Overview tab for your OAuth app, you'll find your application ID under **App ID**.
106+
AUD | The intended recipient of the token. This value is `https://oauth2.segment.io` if you're located in the US, or `https://oauth2.eu1.segmentapis.com` if you're located in the EU.
107+
IAT | The epoch time in seconds when the token was issued. This is typically set using `Math.floor(Date.now() / 1000)`.
108+
EXP | The expiry time of a token, measured in seconds. Tokens are expected to be valid for less than sixty seconds. You can set the expiry of a token using `Math.floor(Date.now() / 1000) + 60`.
109+
JTI | A case-sensitive string that acts as a [unique identifier for the token](https://www.rfc-editor.org/rfc/rfc7519#section-4.1.7){:target="_blank”}. Segment recommends setting this value with a UUID format to avoid duplicate values between tokens.
107110
108111
2. Send a form-url-encoded `POST` request to the regional authorization server's `\token` route with the following parameters:
109112

0 commit comments

Comments
 (0)