Update from code changes: document API key IP allowlists#6421
Open
mintlify[bot] wants to merge 5 commits into
Open
Update from code changes: document API key IP allowlists#6421mintlify[bot] wants to merge 5 commits into
mintlify[bot] wants to merge 5 commits into
Conversation
Contributor
Author
|
Preview deployment for your docs. Learn more about Mintlify Previews.
|
Contributor
Author
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
Contributor
Author
|
Update from code changes updated this PR. Added read/write scope restrictions for admin API keys Source PRs
|
Contributor
Author
|
Update from code changes updated this PR. Added optional expiration date for admin and assistant API keys Source PRs
|
Contributor
Author
|
Update from code changes updated this PR. Added nothing; dashboard UI change required no new documentation Source PRs
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documents new per-key controls for the Mintlify REST API: an optional IP/CIDR allowlist for admin and assistant API keys, optional
read/writescopes for admin API keys, and an optional expiration date for both key types. All three are set at key creation on the dashboard API keys page, are fixed for the lifetime of the key, and leave existing keys unrestricted when omitted. Requests that don't satisfy a key's allowlist or scope are rejected with a403, and requests using an expired key are rejected.Changes
api/introduction.mdx: New "Restrict keys by IP address" subsection covering scope, entry formats (IPv4, IPv6, CIDR), disallowed catch-alls, and when to use it. New "Restrict admin keys by scope" subsection covering theread/writevalues, the method-to-scope mapping (GET/HEAD →read, others →write), thewritesatisfiesreadrule, and the400on invalid values. New "Set an expiration date" subsection covering the ISO 8601 requirement, the400on past or invalid timestamps, and theexpiresAtfield returned when listing keys.es/api/introduction.mdx,fr/api/introduction.mdx,zh/api/introduction.mdx: Mirror all three subsections in Spanish, French, and Chinese with localized headings and anchor IDsrestrict-keys-by-ip-address,restrict-admin-keys-by-scope, andset-an-expiration-date.Update history
api/introduction.mdxand mirrored the section toes/andzh/. Triggered by https://github.com/mintlify/server/pull/6469.fr/api/introduction.mdx) and wrapped the new heading in<div id="restrict-keys-by-ip-address">across es/fr/zh so anchor links resolve on translated pages.read/writescopes for admin API keys — including the HTTP-method-to-scope mapping and thewrite-satisfies-readrule — inapi/introduction.mdxand mirrored the section intoes/,fr/, andzh/. Triggered by https://github.com/mintlify/server/pull/6476.400on past/invalid timestamps, and theexpiresAtfield returned when listing keys — inapi/introduction.mdxand mirrored the section intoes/,fr/, andzh/. Triggered by https://github.com/mintlify/server/pull/6481.Note
Low Risk
Documentation-only changes to MDX intro pages with no runtime or API behavior changes in this repo.
Overview
The REST API Authentication section in
api/introduction.mdxnow documents three optional per-key controls configured at creation on the dashboard API keys page: IP/CIDR allowlists (admin and assistant keys; mismatches return403), admin-onlyread/writescopes mapped from HTTP method (GET/HEAD→read, others →write, withwriteimplyingread), and expiration via a future ISO 8601 timestamp (expiresAtwhen listing keys).Each control is immutable for the life of the key (rotate by delete-and-recreate), and keys without these settings behave as before. The same content is mirrored in
es/,fr/, andzh/api/introduction.mdx, with localized headings and stable anchor IDs on the translated pages for deep linking.Reviewed by Cursor Bugbot for commit 45cfefc. Bugbot is set up for automated code reviews on this repo. Configure here.