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.SetFcmv1ProviderAsync(
new SetGuardianFactorsProviderPushNotificationFcmv1RequestContent()
);
}
}package com.example.usage;
import com.auth0.client.mgmt.ManagementApi;
import com.auth0.client.mgmt.resources.guardian.factors.pushnotification.requests.SetGuardianFactorsProviderPushNotificationFcmv1RequestContent;
public class Example {
public static void main(String[] args) {
ManagementApi client = ManagementApi
.builder()
.token("<token>")
.build();
client.guardian().factors().pushNotification().setFcmv1Provider(
SetGuardianFactorsProviderPushNotificationFcmv1RequestContent
.builder()
.build()
);
}
}<?php
namespace Example;
use Auth0\SDK\API\Management\Management;
use Auth0\SDK\API\Management\Guardian\Factors\PushNotification\Requests\SetGuardianFactorsProviderPushNotificationFcmv1RequestContent;
$client = new Management(
token: '<token>',
);
$client->guardian->factors->pushNotification->setFcmv1Provider(
new SetGuardianFactorsProviderPushNotificationFcmv1RequestContent([]),
);from auth0.management import ManagementClient
client = ManagementClient(
token="<token>",
)
client.guardian.factors.push_notification.set_fcmv_1_provider()require "auth0"
client = Auth0::Management.new(token: "<token>")
client.guardian.factors.push_notification.set_fcmv_1_providercurl --request PUT \
--url https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"server_credentials": "<string>"
}
'const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({server_credentials: '<string>'})
};
fetch('https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1"
payload := strings.NewReader("{\n \"server_credentials\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{}Overwrite FCMV1 configuration
Overwrite all configuration details of the multi-factor authentication FCMV1 provider associated with your tenant.
PUT
https://{tenantDomain}/api/v2
/
guardian
/
factors
/
push-notification
/
providers
/
fcmv1
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.SetFcmv1ProviderAsync(
new SetGuardianFactorsProviderPushNotificationFcmv1RequestContent()
);
}
}package com.example.usage;
import com.auth0.client.mgmt.ManagementApi;
import com.auth0.client.mgmt.resources.guardian.factors.pushnotification.requests.SetGuardianFactorsProviderPushNotificationFcmv1RequestContent;
public class Example {
public static void main(String[] args) {
ManagementApi client = ManagementApi
.builder()
.token("<token>")
.build();
client.guardian().factors().pushNotification().setFcmv1Provider(
SetGuardianFactorsProviderPushNotificationFcmv1RequestContent
.builder()
.build()
);
}
}<?php
namespace Example;
use Auth0\SDK\API\Management\Management;
use Auth0\SDK\API\Management\Guardian\Factors\PushNotification\Requests\SetGuardianFactorsProviderPushNotificationFcmv1RequestContent;
$client = new Management(
token: '<token>',
);
$client->guardian->factors->pushNotification->setFcmv1Provider(
new SetGuardianFactorsProviderPushNotificationFcmv1RequestContent([]),
);from auth0.management import ManagementClient
client = ManagementClient(
token="<token>",
)
client.guardian.factors.push_notification.set_fcmv_1_provider()require "auth0"
client = Auth0::Management.new(token: "<token>")
client.guardian.factors.push_notification.set_fcmv_1_providercurl --request PUT \
--url https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"server_credentials": "<string>"
}
'const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({server_credentials: '<string>'})
};
fetch('https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{tenantDomain}/api/v2/guardian/factors/push-notification/providers/fcmv1"
payload := strings.NewReader("{\n \"server_credentials\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{}Authorizations
bearerAuthoAuth2ClientCredentials
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/jsonapplication/x-www-form-urlencoded
Required string length:
1 - 10000Response
FCMV1 configuration updated
The response is of type object.
⌘I