Skip to content

Commit

Permalink
Merge pull request #817 from supertokens/curl-fixes
Browse files Browse the repository at this point in the history
fix: single/multi-app selectors and json fixes
  • Loading branch information
rishabhpoddar authored Jul 19, 2024
2 parents 39a7d9a + 1462ef0 commit 815e7e1
Show file tree
Hide file tree
Showing 16 changed files with 31 additions and 32 deletions.
13 changes: 6 additions & 7 deletions v2/mfa/backend-setup.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -208,14 +208,14 @@ Coming soon. In the meantime, checkout the [legacy method](./legacy-method/how-i

<TabItem value="curl">

<CoreInjector defaultValue="http://localhost:3567" showAppId={false}>
<CoreInjector defaultValue="http://localhost:3567" showAppId={true} showTenantId={false}>

<CoreVersionSubTabs>

<TabItem value="core-9.1">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant/v2' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant/v2' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand All @@ -229,7 +229,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>
<TabItem value="core-9.0">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand All @@ -245,7 +245,6 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>
</CoreVersionSubTabs>



</CoreInjector>

</TabItem>
Expand Down Expand Up @@ -606,14 +605,14 @@ Coming soon. In the meantime, checkout the [legacy method](./legacy-method/how-i

<TabItem value="curl">

<CoreInjector defaultValue="http://localhost:3567" showAppId={false}>
<CoreInjector defaultValue="http://localhost:3567" showAppId={true} showTenantId={false}>

<CoreVersionSubTabs>

<TabItem value="core-9.1">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant/v2' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant/v2' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand All @@ -628,7 +627,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>
<TabItem value="core-9.0">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand Down
4 changes: 2 additions & 2 deletions v2/mfa/email-sms-otp/otp-for-all-users.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -562,10 +562,10 @@ Coming soon. In the meantime, checkout the [legacy method](../legacy-method/how-

<TabItem value="curl">

<CoreInjector defaultValue="http://localhost:3567" showAppId={false}>
<CoreInjector defaultValue="http://localhost:3567" showAppId={true} showTenantId={false}>

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant/v2' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant/v2' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand Down
4 changes: 2 additions & 2 deletions v2/mfa/totp/totp-for-all-users.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -858,10 +858,10 @@ Coming soon.

<TabItem value="curl">

<CoreInjector defaultValue="http://localhost:3567" showAppId={false}>
<CoreInjector defaultValue="http://localhost:3567" showAppId={true} showTenantId={false}>

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant/v2' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant/v2' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand Down
6 changes: 3 additions & 3 deletions v2/multitenancy/new-tenant.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -139,14 +139,14 @@ else:

<TabItem value="curl">

<CoreInjector defaultValue="http://localhost:3567" showAppId={false}>
<CoreInjector defaultValue="http://localhost:3567" showAppId={true} showTenantId={false}>

<CoreVersionSubTabs>

<TabItem value="core-9.1">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant/v2' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant/v2' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand All @@ -173,7 +173,7 @@ The built-in Factor IDs that can be used for `firstFactors` are:
<TabItem value="core-9.0">

```bash
curl --location --request PUT '^{coreInjector_uri_without_quotes}/appid-<APP_ID>/recipe/multitenancy/tenant' \
curl --location --request PUT '^{coreInjector_uri_without_quotes}/recipe/multitenancy/tenant' \
--header 'api-key: ^{coreInjector_api_key_without_quotes}' \
--header 'Content-Type: application/json' \
--data-raw '{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"authorizationEndpoint": "https://example.com/oauth/authorize",
"authorizationEndpointQueryParams": {
Expand All @@ -247,7 +247,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
},
"tokenEndpoint": "https://example.com/oauth/token",
"tokenEndpointBodyParams": {
"someKey1": "value1",
"someKey1": "value1"
},
"userInfoEndpoint": "https://example.com/oauth/userinfo",
"userInfoMap": {
Expand Down Expand Up @@ -459,7 +459,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"oidcDiscoveryEndpoint": "https://example.com",
"authorizationEndpointQueryParams": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
2 changes: 1 addition & 1 deletion v2/thirdparty/custom-ui/multitenant-login.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
2 changes: 1 addition & 1 deletion v2/thirdparty/pre-built-ui/multitenant-login.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"authorizationEndpoint": "https://example.com/oauth/authorize",
"authorizationEndpointQueryParams": {
Expand All @@ -247,7 +247,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
},
"tokenEndpoint": "https://example.com/oauth/token",
"tokenEndpointBodyParams": {
"someKey1": "value1",
"someKey1": "value1"
},
"userInfoEndpoint": "https://example.com/oauth/userinfo",
"userInfoMap": {
Expand Down Expand Up @@ -459,7 +459,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"oidcDiscoveryEndpoint": "https://example.com",
"authorizationEndpointQueryParams": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
2 changes: 1 addition & 1 deletion v2/thirdpartyemailpassword/custom-ui/multitenant-login.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"authorizationEndpoint": "https://example.com/oauth/authorize",
"authorizationEndpointQueryParams": {
Expand All @@ -247,7 +247,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
},
"tokenEndpoint": "https://example.com/oauth/token",
"tokenEndpointBodyParams": {
"someKey1": "value1",
"someKey1": "value1"
},
"userInfoEndpoint": "https://example.com/oauth/userinfo",
"userInfoMap": {
Expand Down Expand Up @@ -459,7 +459,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [{
"clientId": "...",
"clientSecret": "...",
"scope": ["email", "profile"],
"scope": ["email", "profile"]
}],
"oidcDiscoveryEndpoint": "https://example.com",
"authorizationEndpointQueryParams": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
2 changes: 1 addition & 1 deletion v2/thirdpartypasswordless/custom-ui/multitenant-login.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ curl --location --request PUT '^{coreInjector_uri_without_quotes}/<TENANT_ID>/re
"clients": [
{
"clientId": "...",
"clientSecret": "...",
"clientSecret": "..."
}
],
"oidcDiscoveryEndpoint": "https://login.microsoftonline.com/<directoryId>/v2.0"
Expand Down

0 comments on commit 815e7e1

Please sign in to comment.