mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-04 21:04:37 +08:00
Hexclave rename PR5: docs-mintlify brand prose + doc file renames (Step 18/F)
Reworded Stack Auth -> Hexclave in restricted-users.mdx; renamed stack-app.mdx (guides + sdk/objects) and use-stack-app.mdx -> hexclave-app / use-hexclave-app; updated docs.json slugs + cross-links and added redirects from old slugs. Kept migration.mdx + 'formerly known as Stack Auth' historical notes. docs build validation + typecheck + lint green.
This commit is contained in:
parent
63e5582f0c
commit
2f4f5ba9da
@ -86,14 +86,14 @@ curl https://api.hexclave.com/api/v1/ \
|
||||
|
||||
Never use server access type or secret server keys in client-side code, browser requests, or any publicly accessible location. Always keep server keys secure on your backend.
|
||||
|
||||
For more information, see the concept documentation on [StackApp](/guides/going-further/stack-app#client-vs-server).
|
||||
For more information, see the concept documentation on [StackApp](/guides/going-further/hexclave-app#client-vs-server).
|
||||
|
||||
</Accordion>
|
||||
|
||||
<Accordion title="What is this 'admin' access type that I see?">
|
||||
If you'd like to build your own version of the Stack dashboard (or update project configuration programmatically), you can use the `admin` access type. These endpoints are very dangerous and you should only use them if you know what you're doing.
|
||||
|
||||
For more information, see the concept documentation on [StackApp](/guides/going-further/stack-app#client-vs-server).
|
||||
For more information, see the concept documentation on [StackApp](/guides/going-further/hexclave-app#client-vs-server).
|
||||
|
||||
</Accordion>
|
||||
|
||||
|
||||
@ -75,7 +75,7 @@
|
||||
{
|
||||
"group": "Going Further",
|
||||
"pages": [
|
||||
"guides/going-further/stack-app",
|
||||
"guides/going-further/hexclave-app",
|
||||
"guides/going-further/backend-integration",
|
||||
"guides/going-further/cli",
|
||||
"guides/going-further/user-metadata"
|
||||
@ -169,7 +169,7 @@
|
||||
"sdk/overview",
|
||||
{
|
||||
"group": "Objects",
|
||||
"pages": ["sdk/objects/stack-app"]
|
||||
"pages": ["sdk/objects/hexclave-app"]
|
||||
},
|
||||
{
|
||||
"group": "Types",
|
||||
@ -190,7 +190,7 @@
|
||||
},
|
||||
{
|
||||
"group": "Hooks",
|
||||
"pages": ["sdk/hooks/use-stack-app", "sdk/hooks/use-user"]
|
||||
"pages": ["sdk/hooks/use-hexclave-app", "sdk/hooks/use-user"]
|
||||
}
|
||||
]
|
||||
},
|
||||
@ -247,6 +247,18 @@
|
||||
"customScripts": ["/apps-sidebar-filter.js", "/code-language-labels.js"]
|
||||
},
|
||||
"redirects": [
|
||||
{
|
||||
"source": "/guides/going-further/stack-app",
|
||||
"destination": "/guides/going-further/hexclave-app"
|
||||
},
|
||||
{
|
||||
"source": "/sdk/objects/stack-app",
|
||||
"destination": "/sdk/objects/hexclave-app"
|
||||
},
|
||||
{
|
||||
"source": "/sdk/hooks/use-stack-app",
|
||||
"destination": "/sdk/hooks/use-hexclave-app"
|
||||
},
|
||||
{
|
||||
"source": "/rest-api/overview",
|
||||
"destination": "/api/overview"
|
||||
@ -289,7 +301,7 @@
|
||||
},
|
||||
{
|
||||
"source": "/others/js-client",
|
||||
"destination": "/guides/going-further/stack-app"
|
||||
"destination": "/guides/going-further/hexclave-app"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@ -6,7 +6,7 @@ sidebarTitle: "Restricted Users"
|
||||
|
||||
Restricted users are signed-in users whose account exists, but has not been granted normal application access yet. Stack marks these users with `user.isRestricted === true` and provides a `user.restrictedReason` explaining why.
|
||||
|
||||
By default, Stack Auth treats restricted users like unauthenticated users in most SDK calls. This prevents accounts that still need verification, review, or conversion from accidentally getting access to protected product flows.
|
||||
By default, Hexclave treats restricted users like unauthenticated users in most SDK calls. This prevents accounts that still need verification, review, or conversion from accidentally getting access to protected product flows.
|
||||
|
||||
## When users are restricted
|
||||
|
||||
@ -97,9 +97,9 @@ For API routes or backend actions, keep using the default behavior unless the en
|
||||
|
||||
## Restricted users in JWTs
|
||||
|
||||
Restricted users receive tokens with `is_restricted` and `restricted_reason` claims. If your backend verifies Stack Auth JWTs directly, make sure you reject restricted users unless the endpoint intentionally supports them.
|
||||
Restricted users receive tokens with `is_restricted` and `restricted_reason` claims. If your backend verifies Hexclave JWTs directly, make sure you reject restricted users unless the endpoint intentionally supports them.
|
||||
|
||||
When fetching Stack Auth's JWKS, restricted-user signing keys are excluded by default. Include them only for services that intentionally accept restricted users:
|
||||
When fetching Hexclave's JWKS, restricted-user signing keys are excluded by default. Include them only for services that intentionally accept restricted users:
|
||||
|
||||
```txt jwks-url.txt
|
||||
/.well-known/jwks.json?include_restricted=true
|
||||
|
||||
@ -14,7 +14,7 @@ Follow these steps when you're ready to push your application to production:
|
||||
|
||||
<Steps>
|
||||
<Step title="Add Your Domain">
|
||||
Navigate to the `Domain & Handlers` tab in the Stack dashboard. If you haven't configured your handler, you can leave it as the default. (Learn more about handlers [here](/sdk/objects/stack-app)).
|
||||
Navigate to the `Domain & Handlers` tab in the Stack dashboard. If you haven't configured your handler, you can leave it as the default. (Learn more about handlers [here](/sdk/objects/hexclave-app)).
|
||||
</Step>
|
||||
<Step title="Disable Localhost Callbacks">
|
||||
For enhanced security, disable the `Allow all localhost callbacks for development` option.
|
||||
|
||||
@ -173,7 +173,7 @@ For more details, see the [User Metadata](/guides/going-further/user-metadata) d
|
||||
|
||||
## Signing out
|
||||
|
||||
You can sign out the user by calling `user.signOut()`. They will be redirected to the URL [configured as `afterSignOut` in the Hexclave App](/sdk/objects/stack-app).
|
||||
You can sign out the user by calling `user.signOut()`. They will be redirected to the URL [configured as `afterSignOut` in the Hexclave App](/sdk/objects/hexclave-app).
|
||||
|
||||
<CodeGroup dropdown>
|
||||
```ts my-app.ts
|
||||
|
||||
@ -8,7 +8,7 @@ By now, you may have seen the `useHexclaveApp()` hook and the `hexclaveServerApp
|
||||
|
||||
Nearly all of Stack's functionality is on your `StackApp` object. Think of this object as the "connection" from your code to Stack's servers. Each app is always associated with one specific project ID (by default the one found in your environment variables).
|
||||
|
||||
There is also a page on [StackApp](/sdk/objects/stack-app) in the SDK reference, which lists all available functions.
|
||||
There is also a page on [StackApp](/sdk/objects/hexclave-app) in the SDK reference, which lists all available functions.
|
||||
|
||||
## `getXyz`/`listXyz` vs. `useXyz`
|
||||
|
||||
@ -5,8 +5,8 @@ description: "How to store custom user metadata in Hexclave"
|
||||
|
||||
Hexclave allows storing additional user information through three types of metadata fields:
|
||||
|
||||
1. **clientMetadata**: Readable and writable from a [client](/guides/going-further/stack-app#client-vs-server).
|
||||
2. **serverMetadata**: Readable and writable only from a [server](/guides/going-further/stack-app#client-vs-server).
|
||||
1. **clientMetadata**: Readable and writable from a [client](/guides/going-further/hexclave-app#client-vs-server).
|
||||
2. **serverMetadata**: Readable and writable only from a [server](/guides/going-further/hexclave-app#client-vs-server).
|
||||
3. **clientReadOnlyMetadata**: Readable from a client, writable only from a server.
|
||||
|
||||
## Client metadata
|
||||
|
||||
@ -302,7 +302,7 @@ Before going live, tighten **callback domains**, replace shared **OAuth** keys w
|
||||
| Topic | Guide |
|
||||
|--------|--------|
|
||||
| Install and configure | [Setup](/guides/getting-started/setup) |
|
||||
| `StackApp` object | [Stack App](/guides/going-further/stack-app) |
|
||||
| `StackApp` object | [Stack App](/guides/going-further/hexclave-app) |
|
||||
| Current user and page protection | [User fundamentals](/guides/getting-started/user-fundamentals) |
|
||||
| Teams, membership, and RBAC (deeper path) | [Build a team-based app](/guides/other/tutorials/build-a-team-based-app) |
|
||||
| Teams reference | [Teams](/guides/apps/teams/overview) |
|
||||
|
||||
@ -106,7 +106,7 @@ Read the full discussion in [User fundamentals — Protecting a page](/guides/ge
|
||||
## 2. Secrets, keys, and environments
|
||||
|
||||
<Warning>
|
||||
**`STACK_SECRET_SERVER_KEY`** (or `ssk_...`) must **only** exist in server-side environments (SSR, route handlers, server actions, your backend). Never prefix it with `NEXT_PUBLIC_`, never import it from code that runs in the browser, and never log it. See [Stack App](/guides/going-further/stack-app) and the [REST API overview](/api/overview).
|
||||
**`STACK_SECRET_SERVER_KEY`** (or `ssk_...`) must **only** exist in server-side environments (SSR, route handlers, server actions, your backend). Never prefix it with `NEXT_PUBLIC_`, never import it from code that runs in the browser, and never log it. See [Stack App](/guides/going-further/hexclave-app) and the [REST API overview](/api/overview).
|
||||
</Warning>
|
||||
|
||||
Practical split:
|
||||
@ -156,7 +156,7 @@ If you consume Stack webhooks, **verify every payload** (for example with Svix a
|
||||
| First integration | [Build a SaaS with Hexclave](/guides/other/tutorials/build-a-saas-with-hexclave) |
|
||||
| Page protection details | [User fundamentals](/guides/getting-started/user-fundamentals) |
|
||||
| Domains, OAuth, email, prod mode | [Launch checklist](/guides/apps/launch-checklist/overview) |
|
||||
| `HexclaveServerApp` and keys | [Stack App](/guides/going-further/stack-app) |
|
||||
| `HexclaveServerApp` and keys | [Stack App](/guides/going-further/hexclave-app) |
|
||||
| Webhook verification | [Webhooks](/guides/apps/webhooks/overview) |
|
||||
| REST from your backend | [API overview](/api/overview) |
|
||||
|
||||
|
||||
@ -146,12 +146,12 @@ export const copyGeneratedSetupPrompt = async (event) => {
|
||||
{/* Going Further */}
|
||||
<div className="relative mb-10">
|
||||
<div className="absolute -left-[2.55rem] top-0.5 h-4 w-4 rounded-full border-2 border-[#6b5df7] bg-[#6b5df7]" />
|
||||
<SectionLink href="/guides/going-further/stack-app">Going Further</SectionLink>
|
||||
<SectionLink href="/guides/going-further/hexclave-app">Going Further</SectionLink>
|
||||
<p className="mt-1 text-sm text-slate-500 dark:text-slate-400">
|
||||
Configure Stack App deeply, integrate your backend, and use lower-level interfaces where needed.
|
||||
</p>
|
||||
<div className="mt-3 flex flex-wrap gap-2">
|
||||
<ChipLink href="/guides/going-further/stack-app">Stack App</ChipLink>
|
||||
<ChipLink href="/guides/going-further/hexclave-app">Stack App</ChipLink>
|
||||
<ChipLink href="/guides/going-further/backend-integration">Backend Integration</ChipLink>
|
||||
<ChipLink href="/guides/going-further/local-development">Local Development</ChipLink>
|
||||
</div>
|
||||
@ -166,7 +166,7 @@ export const copyGeneratedSetupPrompt = async (event) => {
|
||||
</p>
|
||||
<div className="mt-3 flex flex-wrap gap-2">
|
||||
<ChipLink href="/sdk/hooks/use-user">useUser</ChipLink>
|
||||
<ChipLink href="/sdk/objects/stack-app">StackApp</ChipLink>
|
||||
<ChipLink href="/sdk/objects/hexclave-app">StackApp</ChipLink>
|
||||
<ChipLink href="/sdk/types/user">User Type</ChipLink>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -34,7 +34,7 @@ The full docs sidebar — generated from the live navigation. Fetch any of these
|
||||
- [User Fundamentals](https://docs.hexclave.com/guides/getting-started/user-fundamentals)
|
||||
- [AI Integration](https://docs.hexclave.com/guides/getting-started/ai-integration)
|
||||
- **Going Further**
|
||||
- [Stack App](https://docs.hexclave.com/guides/going-further/stack-app)
|
||||
- [Stack App](https://docs.hexclave.com/guides/going-further/hexclave-app)
|
||||
- [Backend Integration](https://docs.hexclave.com/guides/going-further/backend-integration)
|
||||
- [CLI](https://docs.hexclave.com/guides/going-further/cli)
|
||||
- [User Metadata](https://docs.hexclave.com/guides/going-further/user-metadata)
|
||||
|
||||
@ -6,7 +6,7 @@ icon: "react"
|
||||
mode: "wide"
|
||||
---
|
||||
|
||||
The `useHexclaveApp` hook returns a `HexclaveClientApp` object from the one that you provided in the setup flow. If you want to learn more about the `HexclaveClientApp` object, check out the [StackApp](/sdk/objects/stack-app) documentation.
|
||||
The `useHexclaveApp` hook returns a `HexclaveClientApp` object from the one that you provided in the setup flow. If you want to learn more about the `HexclaveClientApp` object, check out the [StackApp](/sdk/objects/hexclave-app) documentation.
|
||||
|
||||
## Usage
|
||||
|
||||
@ -22,4 +22,4 @@ function MyComponent() {
|
||||
## Related
|
||||
|
||||
- [Setup guide](/guides/getting-started/setup)
|
||||
- [StackApp object reference](/sdk/objects/stack-app)
|
||||
- [StackApp object reference](/sdk/objects/hexclave-app)
|
||||
@ -8,7 +8,7 @@ mode: "wide"
|
||||
|
||||
This standalone React hook is an alias for `useHexclaveApp().useUser()`. It only exists for convenience; it does not have any additional functionality.
|
||||
|
||||
For more information, please refer to the [documentation for `hexclaveClientApp.useUser()`](/sdk/objects/stack-app#stackclientappuseuseroptions).
|
||||
For more information, please refer to the [documentation for `hexclaveClientApp.useUser()`](/sdk/objects/hexclave-app#stackclientappuseuseroptions).
|
||||
|
||||
## Usage
|
||||
|
||||
@ -28,5 +28,5 @@ function MyComponent() {
|
||||
|
||||
## Related
|
||||
|
||||
- [StackApp object reference](/sdk/objects/stack-app)
|
||||
- [StackApp object reference](/sdk/objects/hexclave-app)
|
||||
- [User type reference](/sdk/types/user)
|
||||
|
||||
@ -14,7 +14,7 @@ import {
|
||||
MethodReturns,
|
||||
} from "/snippets/sdk-type-components.jsx";
|
||||
|
||||
This is a detailed reference for the `StackApp` object. If you're looking for a more high-level overview, please read the [respective page in the Concepts section](/guides/going-further/stack-app).
|
||||
This is a detailed reference for the `StackApp` object. If you're looking for a more high-level overview, please read the [respective page in the Concepts section](/guides/going-further/hexclave-app).
|
||||
|
||||
## Overview
|
||||
|
||||
@ -27,7 +27,7 @@ This is a detailed reference for the `StackApp` object. If you're looking for a
|
||||
|
||||
A `StackApp` with client-level permissions. It contains most of the useful methods and hooks for your client-side code.
|
||||
|
||||
Most commonly you get an instance of `HexclaveClientApp` by calling [`useHexclaveApp()`](/sdk/hooks/use-stack-app) in a Client Component.
|
||||
Most commonly you get an instance of `HexclaveClientApp` by calling [`useHexclaveApp()`](/sdk/hooks/use-hexclave-app) in a Client Component.
|
||||
|
||||
## Table of Contents
|
||||
|
||||
@ -496,7 +496,7 @@ If you're building a client-only app and don't have a `SECRET_SERVER_KEY`, you c
|
||||
|
||||
# HexclaveServerApp
|
||||
|
||||
Like `HexclaveClientApp`, but with [server permissions](/guides/going-further/stack-app#client-vs-server). Has full read and write access to all users.
|
||||
Like `HexclaveClientApp`, but with [server permissions](/guides/going-further/hexclave-app#client-vs-server). Has full read and write access to all users.
|
||||
|
||||
<Warning>
|
||||
Since this functionality should only be available in environments you trust
|
||||
@ -14,8 +14,8 @@ For setup instructions and how to use the SDK, see [Setup & Installation](/guide
|
||||
|
||||
| Type | Description |
|
||||
|------|-------------|
|
||||
| [HexclaveClientApp](/sdk/objects/stack-app#stackclientapp) | Client-level permissions for frontend code |
|
||||
| [HexclaveServerApp](/sdk/objects/stack-app#stackserverapp) | Server-level permissions with full access |
|
||||
| [HexclaveClientApp](/sdk/objects/hexclave-app#stackclientapp) | Client-level permissions for frontend code |
|
||||
| [HexclaveServerApp](/sdk/objects/hexclave-app#stackserverapp) | Server-level permissions with full access |
|
||||
| [Project](/sdk/types/project#project) | Project configuration and settings |
|
||||
|
||||
## Users & User Data
|
||||
@ -59,7 +59,7 @@ For setup instructions and how to use the SDK, see [Setup & Installation](/guide
|
||||
|
||||
| Hook | Description |
|
||||
|------|-------------|
|
||||
| [useHexclaveApp](/sdk/hooks/use-stack-app) | React hook to access the HexclaveClientApp instance |
|
||||
| [useHexclaveApp](/sdk/hooks/use-hexclave-app) | React hook to access the HexclaveClientApp instance |
|
||||
| [useUser](/sdk/hooks/use-user) | React hook to access the current user |
|
||||
|
||||
## API Keys
|
||||
|
||||
@ -26,7 +26,7 @@ export const ProjectSection = (props) => (
|
||||
|
||||
The `Project` object contains the information and configuration of a project, such as the name, description, and enabled authentication methods.
|
||||
|
||||
Each [Stack app](/guides/going-further/stack-app) corresponds to a project. You can obtain its `Project` object by calling [`hexclaveApp.getProject()`](/sdk/objects/stack-app#stackclientappgetproject) or [`hexclaveApp.useProject()`](/sdk/objects/stack-app#stackclientappuseproject).
|
||||
Each [Stack app](/guides/going-further/hexclave-app) corresponds to a project. You can obtain its `Project` object by calling [`hexclaveApp.getProject()`](/sdk/objects/hexclave-app#stackclientappgetproject) or [`hexclaveApp.useProject()`](/sdk/objects/hexclave-app#stackclientappuseproject).
|
||||
|
||||
## Table of Contents
|
||||
|
||||
|
||||
@ -752,7 +752,7 @@ You can get `Team` objects with the `user.useTeams()` or `user.listTeams()` func
|
||||
|
||||
# `ServerTeam`
|
||||
|
||||
Like [`Team`](#team), but with [server permissions](/guides/going-further/stack-app#client-vs-server). Has full read and write access to everything.
|
||||
Like [`Team`](#team), but with [server permissions](/guides/going-further/hexclave-app#client-vs-server). Has full read and write access to everything.
|
||||
|
||||
Calling `serverUser.getTeam(...)` and `serverUser.listTeams()` will return `ServerTeam` objects if the user is a [`ServerUser`](/sdk/types/user#serveruser). Alternatively, you can call `hexclaveServerApp.getTeam('team_id_123')` or `hexclaveServerApp.listTeams()` to query all teams of the project.
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user