Skip to content

Commit

Permalink
code review
Browse files Browse the repository at this point in the history
  • Loading branch information
alexisintech committed Dec 2, 2024
1 parent 345a1db commit 6b6d213
Show file tree
Hide file tree
Showing 4 changed files with 181 additions and 103 deletions.
11 changes: 11 additions & 0 deletions docs/custom-flows/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,17 @@ A _custom flow_ refers to a user flow created entirely from scratch using the Cl
> [!TIP]
> The information in this guide will help you get a general understanding of custom flow concepts. To skip to code examples, choose the guide that best fits your needs from the navigation on the left.
<Details title="Read more about Publishable Keys">
When configuring your Clerk app, you'll need to provide a [Publishable Key](/docs/deployments/clerk-environment-variables#clerk-publishable-and-secret-keys). This key follows a specific format: it consists of your FAPI instance URL encoded in base64, prefixed with an environment identifier (e.g. `pk_test_` for development environments, `pk_live_` for production environments), and suffixed with a `$` delimiter for future extensibility. The base64-encoded URL enables your application to locate and communicate with your dedicated FAPI instance. You can verify this structure by decoding the key yourself:

```js
const publishableKey = 'pk_test_ZXhhbXBsZS5hY2NvdW50cy5kZXYk'
const keyWithoutPrefix = publishableKey.replace('pk_test_', '')

atob(keyWithoutPrefix) // => example.accounts.dev$
```
</Details>

## How authentication flows work in Clerk

Before building custom authentication flows, read the following sections to get a general understanding of how authentication flows work in Clerk.
Expand Down
Loading

0 comments on commit 6b6d213

Please sign in to comment.