All URIs are relative to https://subdomain.okta.com
Method | HTTP request | Description |
---|---|---|
ListRoleSubscriptions | Get /api/v1/roles/{roleTypeOrRoleId}/subscriptions | List all Subscriptions of a Custom Role |
ListRoleSubscriptionsByNotificationType | Get /api/v1/roles/{roleTypeOrRoleId}/subscriptions/{notificationType} | List all Subscriptions of a Custom Role with a specific notification type |
ListUserSubscriptions | Get /api/v1/users/{userId}/subscriptions | List all Subscriptions |
ListUserSubscriptionsByNotificationType | Get /api/v1/users/{userId}/subscriptions/{notificationType} | List all Subscriptions by type |
SubscribeRoleSubscriptionByNotificationType | Post /api/v1/roles/{roleTypeOrRoleId}/subscriptions/{notificationType}/subscribe | Subscribe a Custom Role to a specific notification type |
SubscribeUserSubscriptionByNotificationType | Post /api/v1/users/{userId}/subscriptions/{notificationType}/subscribe | Subscribe to a specific notification type |
UnsubscribeRoleSubscriptionByNotificationType | Post /api/v1/roles/{roleTypeOrRoleId}/subscriptions/{notificationType}/unsubscribe | Unsubscribe a Custom Role from a specific notification type |
UnsubscribeUserSubscriptionByNotificationType | Post /api/v1/users/{userId}/subscriptions/{notificationType}/unsubscribe | Unsubscribe from a specific notification type |
[]Subscription ListRoleSubscriptions(ctx, roleTypeOrRoleId).Execute()
List all Subscriptions of a Custom Role
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
roleTypeOrRoleId := "roleTypeOrRoleId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.ListRoleSubscriptions(context.Background(), roleTypeOrRoleId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.ListRoleSubscriptions``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListRoleSubscriptions`: []Subscription
fmt.Fprintf(os.Stdout, "Response from `SubscriptionApi.ListRoleSubscriptions`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
roleTypeOrRoleId | string |
Other parameters are passed through a pointer to a apiListRoleSubscriptionsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Subscription ListRoleSubscriptionsByNotificationType(ctx, roleTypeOrRoleId, notificationType).Execute()
List all Subscriptions of a Custom Role with a specific notification type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
roleTypeOrRoleId := "roleTypeOrRoleId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.ListRoleSubscriptionsByNotificationType(context.Background(), roleTypeOrRoleId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.ListRoleSubscriptionsByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListRoleSubscriptionsByNotificationType`: Subscription
fmt.Fprintf(os.Stdout, "Response from `SubscriptionApi.ListRoleSubscriptionsByNotificationType`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
roleTypeOrRoleId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiListRoleSubscriptionsByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
[]Subscription ListUserSubscriptions(ctx, userId).Execute()
List all Subscriptions
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
userId := "userId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.ListUserSubscriptions(context.Background(), userId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.ListUserSubscriptions``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListUserSubscriptions`: []Subscription
fmt.Fprintf(os.Stdout, "Response from `SubscriptionApi.ListUserSubscriptions`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
userId | string |
Other parameters are passed through a pointer to a apiListUserSubscriptionsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Subscription ListUserSubscriptionsByNotificationType(ctx, userId, notificationType).Execute()
List all Subscriptions by type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
userId := "userId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.ListUserSubscriptionsByNotificationType(context.Background(), userId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.ListUserSubscriptionsByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListUserSubscriptionsByNotificationType`: Subscription
fmt.Fprintf(os.Stdout, "Response from `SubscriptionApi.ListUserSubscriptionsByNotificationType`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
userId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiListUserSubscriptionsByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SubscribeRoleSubscriptionByNotificationType(ctx, roleTypeOrRoleId, notificationType).Execute()
Subscribe a Custom Role to a specific notification type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
roleTypeOrRoleId := "roleTypeOrRoleId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.SubscribeRoleSubscriptionByNotificationType(context.Background(), roleTypeOrRoleId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.SubscribeRoleSubscriptionByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
roleTypeOrRoleId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiSubscribeRoleSubscriptionByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
SubscribeUserSubscriptionByNotificationType(ctx, userId, notificationType).Execute()
Subscribe to a specific notification type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
userId := "userId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.SubscribeUserSubscriptionByNotificationType(context.Background(), userId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.SubscribeUserSubscriptionByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
userId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiSubscribeUserSubscriptionByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
UnsubscribeRoleSubscriptionByNotificationType(ctx, roleTypeOrRoleId, notificationType).Execute()
Unsubscribe a Custom Role from a specific notification type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
roleTypeOrRoleId := "roleTypeOrRoleId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.UnsubscribeRoleSubscriptionByNotificationType(context.Background(), roleTypeOrRoleId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.UnsubscribeRoleSubscriptionByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
roleTypeOrRoleId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiUnsubscribeRoleSubscriptionByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
UnsubscribeUserSubscriptionByNotificationType(ctx, userId, notificationType).Execute()
Unsubscribe from a specific notification type
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
userId := "userId_example" // string |
notificationType := "notificationType_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SubscriptionApi.UnsubscribeUserSubscriptionByNotificationType(context.Background(), userId, notificationType).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SubscriptionApi.UnsubscribeUserSubscriptionByNotificationType``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
userId | string | ||
notificationType | string |
Other parameters are passed through a pointer to a apiUnsubscribeUserSubscriptionByNotificationTypeRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]