Skip to content

Commit

Permalink
fix: configure sms in console (#1942)
Browse files Browse the repository at this point in the history
  • Loading branch information
vinckr authored Nov 12, 2024
1 parent 8d4506c commit 61e0d41
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 19 deletions.
22 changes: 13 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -414,20 +414,19 @@ import VideoEmbed from '@site/src/components/VideoEmbed'

## Ory Console

### Navigating to Ory Console Pages
### Navigate to Ory Console Pages

When referring to specific pages within Ory Console in the documentation, you
can use the `/current/` route to navigate users to their currently active Ory
Network project. For example, to access the Custom UI settings for the currently
active Ory Network project in the Console, you can link to:
You can use the `/current/` route to navigate users to their active Ory Network
project. For example, to access the Custom UI settings for the active Ory
Network project in the Console, you can link to:
https://console.ory.sh/projects/current/ui

When referencing a specific page of the Ory Console, use the
When referencing a page of the Ory Console, use the
`<ConsoleLink route="project..." />` component in MDX files.

The component automatically resolves the navigation section and page title for
the given route, and renders a standard markup for both, as well as the link
with the `/current/` shortcut mentioned above:
The component resolves the navigation section and page title for the given
route, and renders a standard markup for both, as well as the link with the
`/current/` shortcut mentioned above:

```tsx
<ConsoleLink route="project.activity.events" />
Expand Down Expand Up @@ -457,6 +456,11 @@ file in the following way:

Use `<ConsoleLink route="project.activity.events" />` to reference it.

To add a new route, you need to add an entry in
[`console-routes.ts`](https://github.com/ory/docs/blob/master/src/components/ConsoleLink/console-routes.ts)
as well as
[`console-nav-data.ts`](https://github.com/ory/docs/blob/master/src/components/ConsoleLink/console-nav-data.ts).

## Testing

To test the documentation locally:
Expand Down
2 changes: 1 addition & 1 deletion docs/kratos/emails-sms/01_sending-emails-smtp.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ You can send emails from your own SMTP server. Follow these steps to configure O

1. Go to <ConsoleLink route="project.emailConfiguration" />
2. Toggle the **Advanced Settings** switch
3. Provide the configuration for your SMTP server
3. Add the configuration for your SMTP server

```mdx-code-block
</TabItem>
Expand Down
10 changes: 9 additions & 1 deletion docs/kratos/emails-sms/10_sending-sms.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,18 @@ via HTTP API, such as Twilio, Plivo, AWS SNS, or your own microservice.

## Configuration

SMS delivery can only be configured through the [Ory CLI](../../guides/cli/01_installation.mdx). Follow these steps:
SMS delivery can be configured through Ory Console or the [Ory CLI](../../guides/cli/01_installation.mdx). Follow these steps to
configure SMS:

```mdx-code-block
<Tabs groupId="console-or-cli">
<TabItem value="console" label="Ory Console" default>
1. Go to <ConsoleLink route="project.smsConfiguration" />
1. Add the configuration for your SMS provider
</TabItem>
<TabItem value="cli" label="Ory CLI">
```

Expand Down
20 changes: 12 additions & 8 deletions src/components/ConsoleLink/console-nav-data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,6 @@ export const brandingPaths: Path[] = [
title: "UI URLs",
href: routes.project.ui.route,
},
{
title: "Email configuration",
href: routes.project.emailConfiguration.route,
},
{
title: "Email templates",
href: routes.project.emailTemplates.route,
},
]

export const authenticationPaths: Path[] = [
Expand Down Expand Up @@ -108,6 +100,18 @@ export const authenticationPaths: Path[] = [
title: "Email verification",
href: routes.project.verification.route,
},
{
title: "Email configuration",
href: routes.project.emailConfiguration.route,
},
{
title: "Email templates",
href: routes.project.emailTemplates.route,
},
{
title: "SMS configuration",
href: routes.project.smsConfiguration.route,
},
{
title: "Sessions",
href: routes.project.authentication.sessionSettings.route,
Expand Down
4 changes: 4 additions & 0 deletions src/components/ConsoleLink/console-routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ export const routes = {
route: "/projects/[project]/email-templates",
href: (project: string) => `/projects/${project}/email-templates`,
},
smsConfiguration: {
route: "/projects/[project]/sms-configuration",
href: (project: string) => `/projects/${project}/sms-configuration`,
},
sessionSettings: {
route: "/projects/[project]/session-settings",
href: (project: string) => `/projects/${project}/session-settings`,
Expand Down

0 comments on commit 61e0d41

Please sign in to comment.