C#
using Auth0.ManagementApi;
using System.Threading.Tasks;
using Auth0.ManagementApi.Guardian.Factors;
public partial class Examples
{
public async Task Example() {
var client = new ManagementClient(
token: "<token>"
);
await client.Guardian.Factors.PushNotification.SetProviderAsync(
new SetGuardianFactorsProviderPushNotificationRequestContent {
Provider = GuardianFactorsProviderPushNotificationProviderDataEnum.Guardian
}
);
}
}
package example
import (
context "context"
management "github.com/auth0/go-auth0/management/management"
client "github.com/auth0/go-auth0/management/management/client"
factors "github.com/auth0/go-auth0/management/management/guardian/factors"
option "github.com/auth0/go-auth0/management/management/option"
)
func do() {
client := client.NewClient(
option.WithToken(
"<token>",
),
)
request := &factors.SetGuardianFactorsProviderPushNotificationRequestContent{
Provider: management.GuardianFactorsProviderPushNotificationProviderDataEnumGuardian,
}
client.Guardian.Factors.PushNotification.SetProvider(
context.TODO(),
request,
)
}
package com.example.usage;
import com.auth0.client.mgmt.ManagementApi;
import com.auth0.client.mgmt.resources.guardian.factors.pushnotification.requests.SetGuardianFactorsProviderPushNotificationRequestContent;
import com.auth0.client.mgmt.types.GuardianFactorsProviderPushNotificationProviderDataEnum;
public class Example {
public static void main(String[] args) {
ManagementApi client = ManagementApi
.builder()
.token("<token>")
.build();
client.guardian().factors().pushNotification().setProvider(
SetGuardianFactorsProviderPushNotificationRequestContent
.builder()
.provider(GuardianFactorsProviderPushNotificationProviderDataEnum.GUARDIAN)
.build()
);
}
}<?php
namespace Example;
use Auth0\SDK\API\Management\Management;
use Auth0\SDK\API\Management\Guardian\Factors\PushNotification\Requests\SetGuardianFactorsProviderPushNotificationRequestContent;
use Auth0\SDK\API\Management\Types\GuardianFactorsProviderPushNotificationProviderDataEnum;
$client = new Management(
token: '<token>',
);
$client->guardian->factors->pushNotification->setProvider(
new SetGuardianFactorsProviderPushNotificationRequestContent([
'provider' => GuardianFactorsProviderPushNotificationProviderDataEnum::Guardian->value,
]),
);
from auth0.management import ManagementClient
client = ManagementClient(
token="<token>",
)
client.guardian.factors.push_notification.set_provider(
provider="guardian",
)
require "auth0"
client = Auth0::Management.new(token: "<token>")
client.guardian.factors.push_notification.set_provider(provider: "guardian")
import { ManagementClient } from "auth0";
async function main() {
const client = new ManagementClient({
token: "<token>",
});
await client.guardian.factors.pushNotification.setProvider({
provider: "guardian",
});
}
main();
import { ManagementClient } from "auth0";
async function main() {
const client = new ManagementClient({
token: "<token>",
});
await client.guardian.factors.pushNotification.setProvider({
provider: "guardian",
});
}
main();
curl --request PUT \
--url https://{tenantDomain}/api/v2/guardian/factors/push-notification/selected-provider \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'{}Update Push Notification configuration
Modify the push notification provider configured for your tenant. For more information, review Configure Push Notifications for MFA.
PUT
https://{tenantDomain}/api/v2
/
guardian
/
factors
/
push-notification
/
selected-provider
C#
using Auth0.ManagementApi;
using System.Threading.Tasks;
using Auth0.ManagementApi.Guardian.Factors;
public partial class Examples
{
public async Task Example() {
var client = new ManagementClient(
token: "<token>"
);
await client.Guardian.Factors.PushNotification.SetProviderAsync(
new SetGuardianFactorsProviderPushNotificationRequestContent {
Provider = GuardianFactorsProviderPushNotificationProviderDataEnum.Guardian
}
);
}
}
package example
import (
context "context"
management "github.com/auth0/go-auth0/management/management"
client "github.com/auth0/go-auth0/management/management/client"
factors "github.com/auth0/go-auth0/management/management/guardian/factors"
option "github.com/auth0/go-auth0/management/management/option"
)
func do() {
client := client.NewClient(
option.WithToken(
"<token>",
),
)
request := &factors.SetGuardianFactorsProviderPushNotificationRequestContent{
Provider: management.GuardianFactorsProviderPushNotificationProviderDataEnumGuardian,
}
client.Guardian.Factors.PushNotification.SetProvider(
context.TODO(),
request,
)
}
package com.example.usage;
import com.auth0.client.mgmt.ManagementApi;
import com.auth0.client.mgmt.resources.guardian.factors.pushnotification.requests.SetGuardianFactorsProviderPushNotificationRequestContent;
import com.auth0.client.mgmt.types.GuardianFactorsProviderPushNotificationProviderDataEnum;
public class Example {
public static void main(String[] args) {
ManagementApi client = ManagementApi
.builder()
.token("<token>")
.build();
client.guardian().factors().pushNotification().setProvider(
SetGuardianFactorsProviderPushNotificationRequestContent
.builder()
.provider(GuardianFactorsProviderPushNotificationProviderDataEnum.GUARDIAN)
.build()
);
}
}<?php
namespace Example;
use Auth0\SDK\API\Management\Management;
use Auth0\SDK\API\Management\Guardian\Factors\PushNotification\Requests\SetGuardianFactorsProviderPushNotificationRequestContent;
use Auth0\SDK\API\Management\Types\GuardianFactorsProviderPushNotificationProviderDataEnum;
$client = new Management(
token: '<token>',
);
$client->guardian->factors->pushNotification->setProvider(
new SetGuardianFactorsProviderPushNotificationRequestContent([
'provider' => GuardianFactorsProviderPushNotificationProviderDataEnum::Guardian->value,
]),
);
from auth0.management import ManagementClient
client = ManagementClient(
token="<token>",
)
client.guardian.factors.push_notification.set_provider(
provider="guardian",
)
require "auth0"
client = Auth0::Management.new(token: "<token>")
client.guardian.factors.push_notification.set_provider(provider: "guardian")
import { ManagementClient } from "auth0";
async function main() {
const client = new ManagementClient({
token: "<token>",
});
await client.guardian.factors.pushNotification.setProvider({
provider: "guardian",
});
}
main();
import { ManagementClient } from "auth0";
async function main() {
const client = new ManagementClient({
token: "<token>",
});
await client.guardian.factors.pushNotification.setProvider({
provider: "guardian",
});
}
main();
curl --request PUT \
--url https://{tenantDomain}/api/v2/guardian/factors/push-notification/selected-provider \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'{}承認
bearerAuthoAuth2ClientCredentials
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
ボディ
application/jsonapplication/x-www-form-urlencoded
利用可能なオプション:
guardian, sns, direct レスポンス
Returns selected push notification provider configuration
利用可能なオプション:
guardian, sns, direct ⌘I