All URIs are relative to https://subdomain.okta.com
Method | HTTP request | Description |
---|---|---|
CreatePushProvider | POST /api/v1/push-providers | Create a Push Provider |
DeletePushProvider | DELETE /api/v1/push-providers/{pushProviderId} | Delete a Push Provider |
GetPushProvider | GET /api/v1/push-providers/{pushProviderId} | Retrieve a Push Provider |
ListPushProviders | GET /api/v1/push-providers | List all Push Providers |
ReplacePushProvider | PUT /api/v1/push-providers/{pushProviderId} | Replace a Push Provider |
PushProvider CreatePushProvider (PushProvider pushProvider)
Create a Push Provider
Creates a new push provider. Each Push Provider must have a unique name
.
using System.Collections.Generic;
using System.Diagnostics;
using Okta.Sdk.Api;
using Okta.Sdk.Client;
using Okta.Sdk.Model;
namespace Example
{
public class CreatePushProviderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.OktaDomain = "https://subdomain.okta.com";
// Configure API key authorization: apiToken
config.Token ="YOUR_API_KEY";
// Configure OAuth2 access token for authorization: oauth2
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PushProviderApi(config);
var pushProvider = new PushProvider(); // PushProvider |
try
{
// Create a Push Provider
PushProvider result = apiInstance.CreatePushProvider(pushProvider);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PushProviderApi.CreatePushProvider: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
pushProvider | PushProvider |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
400 | Bad Request | - |
403 | Forbidden | - |
429 | Too Many Requests | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void DeletePushProvider (string pushProviderId)
Delete a Push Provider
Deletes a push provider by pushProviderId
. If the push provider is currently being used in the org by a custom authenticator, the delete will not be allowed.
using System.Collections.Generic;
using System.Diagnostics;
using Okta.Sdk.Api;
using Okta.Sdk.Client;
using Okta.Sdk.Model;
namespace Example
{
public class DeletePushProviderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.OktaDomain = "https://subdomain.okta.com";
// Configure API key authorization: apiToken
config.Token ="YOUR_API_KEY";
// Configure OAuth2 access token for authorization: oauth2
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PushProviderApi(config);
var pushProviderId = "pushProviderId_example"; // string | Id of the push provider
try
{
// Delete a Push Provider
apiInstance.DeletePushProvider(pushProviderId);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PushProviderApi.DeletePushProvider: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
pushProviderId | string | Id of the push provider |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
204 | No Content | - |
403 | Forbidden | - |
404 | Not Found | - |
409 | Conflict | - |
429 | Too Many Requests | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
PushProvider GetPushProvider (string pushProviderId)
Retrieve a Push Provider
Retrieves a push provider by pushProviderId
using System.Collections.Generic;
using System.Diagnostics;
using Okta.Sdk.Api;
using Okta.Sdk.Client;
using Okta.Sdk.Model;
namespace Example
{
public class GetPushProviderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.OktaDomain = "https://subdomain.okta.com";
// Configure API key authorization: apiToken
config.Token ="YOUR_API_KEY";
// Configure OAuth2 access token for authorization: oauth2
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PushProviderApi(config);
var pushProviderId = "pushProviderId_example"; // string | Id of the push provider
try
{
// Retrieve a Push Provider
PushProvider result = apiInstance.GetPushProvider(pushProviderId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PushProviderApi.GetPushProvider: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
pushProviderId | string | Id of the push provider |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
403 | Forbidden | - |
404 | Not Found | - |
429 | Too Many Requests | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
List<PushProvider> ListPushProviders (ProviderType? type = null)
List all Push Providers
Lists all push providers
using System.Collections.Generic;
using System.Diagnostics;
using Okta.Sdk.Api;
using Okta.Sdk.Client;
using Okta.Sdk.Model;
namespace Example
{
public class ListPushProvidersExample
{
public static void Main()
{
Configuration config = new Configuration();
config.OktaDomain = "https://subdomain.okta.com";
// Configure API key authorization: apiToken
config.Token ="YOUR_API_KEY";
// Configure OAuth2 access token for authorization: oauth2
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PushProviderApi(config);
var type = (ProviderType) "APNS"; // ProviderType? | Filters push providers by `providerType` (optional)
try
{
// List all Push Providers
List<PushProvider> result = apiInstance.ListPushProviders(type).ToListAsync();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PushProviderApi.ListPushProviders: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
type | ProviderType? | Filters push providers by `providerType` | [optional] |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
403 | Forbidden | - |
429 | Too Many Requests | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
PushProvider ReplacePushProvider (string pushProviderId, PushProvider pushProvider)
Replace a Push Provider
Replaces a push provider by pushProviderId
using System.Collections.Generic;
using System.Diagnostics;
using Okta.Sdk.Api;
using Okta.Sdk.Client;
using Okta.Sdk.Model;
namespace Example
{
public class ReplacePushProviderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.OktaDomain = "https://subdomain.okta.com";
// Configure API key authorization: apiToken
config.Token ="YOUR_API_KEY";
// Configure OAuth2 access token for authorization: oauth2
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PushProviderApi(config);
var pushProviderId = "pushProviderId_example"; // string | Id of the push provider
var pushProvider = new PushProvider(); // PushProvider |
try
{
// Replace a Push Provider
PushProvider result = apiInstance.ReplacePushProvider(pushProviderId, pushProvider);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PushProviderApi.ReplacePushProvider: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
pushProviderId | string | Id of the push provider | |
pushProvider | PushProvider |
- Content-Type: application/json
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
400 | Bad Request | - |
403 | Forbidden | - |
404 | Not Found | - |
429 | Too Many Requests | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]