All URIs are relative to https://subdomain.okta.com
Method | HTTP request | Description |
---|---|---|
Invoke-OktaActivateBehaviorDetectionRule | POST /api/v1/behaviors/{behaviorId}/lifecycle/activate | Activate a Behavior Detection Rule |
New-OktaBehaviorDetectionRule | POST /api/v1/behaviors | Create a Behavior Detection Rule |
Invoke-OktaDeactivateBehaviorDetectionRule | POST /api/v1/behaviors/{behaviorId}/lifecycle/deactivate | Deactivate a Behavior Detection Rule |
Invoke-OktaDeleteBehaviorDetectionRule | DELETE /api/v1/behaviors/{behaviorId} | Delete a Behavior Detection Rule |
Get-OktaBehaviorDetectionRule | GET /api/v1/behaviors/{behaviorId} | Retrieve a Behavior Detection Rule |
Invoke-OktaListBehaviorDetectionRules | GET /api/v1/behaviors | List all Behavior Detection Rules |
Update-OktaBehaviorDetectionRule | PUT /api/v1/behaviors/{behaviorId} | Replace a Behavior Detection Rule |
BehaviorRule Invoke-OktaActivateBehaviorDetectionRule
[-BehaviorId]
Activate a Behavior Detection Rule
Activate Behavior Detection Rule
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$BehaviorId = "abcd1234" # String | id of the Behavior Detection Rule
# Activate a Behavior Detection Rule
try {
$Result = Invoke-OktaActivateBehaviorDetectionRule -BehaviorId $BehaviorId
} catch {
Write-Host ("Exception occurred when calling Invoke-OktaActivateBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
BehaviorId | String | id of the Behavior Detection Rule |
BehaviorRule (PSCustomObject)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BehaviorRule New-OktaBehaviorDetectionRule
[-Rule]
Create a Behavior Detection Rule
Adds a new Behavior Detection Rule to your organization.
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$HrefObjectHints = Initialize-HrefObjectHints -Allow "DELETE"
$HrefObject = Initialize-HrefObject -Hints $HrefObjectHints -Href "MyHref" -Name "MyName" -Type "MyType"
$ApiTokenLink = Initialize-ApiTokenLink -Self $HrefObject
$BehaviorRule = Initialize-BehaviorRule -Created (Get-Date) -Id "MyId" -LastUpdated (Get-Date) -Name "MyName" -Status "ACTIVE" -Type "ANOMALOUS_DEVICE" -Link $ApiTokenLink # BehaviorRule |
# Create a Behavior Detection Rule
try {
$Result = New-OktaBehaviorDetectionRule -Rule $Rule
} catch {
Write-Host ("Exception occurred when calling New-OktaBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
Rule | BehaviorRule |
BehaviorRule (PSCustomObject)
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BehaviorRule Invoke-OktaDeactivateBehaviorDetectionRule
[-BehaviorId]
Deactivate a Behavior Detection Rule
Deactivate Behavior Detection Rule
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$BehaviorId = "abcd1234" # String | id of the Behavior Detection Rule
# Deactivate a Behavior Detection Rule
try {
$Result = Invoke-OktaDeactivateBehaviorDetectionRule -BehaviorId $BehaviorId
} catch {
Write-Host ("Exception occurred when calling Invoke-OktaDeactivateBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
BehaviorId | String | id of the Behavior Detection Rule |
BehaviorRule (PSCustomObject)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void Invoke-OktaDeleteBehaviorDetectionRule
[-BehaviorId]
Delete a Behavior Detection Rule
Delete a Behavior Detection Rule by behaviorId
.
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$BehaviorId = "abcd1234" # String | id of the Behavior Detection Rule
# Delete a Behavior Detection Rule
try {
$Result = Invoke-OktaDeleteBehaviorDetectionRule -BehaviorId $BehaviorId
} catch {
Write-Host ("Exception occurred when calling Invoke-OktaDeleteBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
BehaviorId | String | id of the Behavior Detection Rule |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BehaviorRule Get-OktaBehaviorDetectionRule
[-BehaviorId]
Retrieve a Behavior Detection Rule
Fetches a Behavior Detection Rule by behaviorId
.
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$BehaviorId = "abcd1234" # String | id of the Behavior Detection Rule
# Retrieve a Behavior Detection Rule
try {
$Result = Get-OktaBehaviorDetectionRule -BehaviorId $BehaviorId
} catch {
Write-Host ("Exception occurred when calling Get-OktaBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
BehaviorId | String | id of the Behavior Detection Rule |
BehaviorRule (PSCustomObject)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BehaviorRule[] Invoke-OktaListBehaviorDetectionRules
List all Behavior Detection Rules
Enumerates Behavior Detection Rules in your organization with pagination.
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
# List all Behavior Detection Rules
try {
$Result = Invoke-OktaListBehaviorDetectionRules
} catch {
Write-Host ("Exception occurred when calling Invoke-OktaListBehaviorDetectionRules: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
This endpoint does not need any parameter.
BehaviorRule[] (PSCustomObject)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BehaviorRule Update-OktaBehaviorDetectionRule
[-BehaviorId]
[-Rule]
Replace a Behavior Detection Rule
Update a Behavior Detection Rule by behaviorId
.
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-OktaConfiguration
# Configure your client ID and scope for authorization
$Configuration.ClientId = "YOUR_CLIENT_ID"
$Configuration.Scope = "OKTA_SCOPES" # for example okta.users.read
$BehaviorId = "abcd1234" # String | id of the Behavior Detection Rule
$HrefObjectHints = Initialize-HrefObjectHints -Allow "DELETE"
$HrefObject = Initialize-HrefObject -Hints $HrefObjectHints -Href "MyHref" -Name "MyName" -Type "MyType"
$ApiTokenLink = Initialize-ApiTokenLink -Self $HrefObject
$BehaviorRule = Initialize-BehaviorRule -Created (Get-Date) -Id "MyId" -LastUpdated (Get-Date) -Name "MyName" -Status "ACTIVE" -Type "ANOMALOUS_DEVICE" -Link $ApiTokenLink # BehaviorRule |
# Replace a Behavior Detection Rule
try {
$Result = Update-OktaBehaviorDetectionRule -BehaviorId $BehaviorId -Rule $Rule
} catch {
Write-Host ("Exception occurred when calling Update-OktaBehaviorDetectionRule: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
Name | Type | Description | Notes |
---|---|---|---|
BehaviorId | String | id of the Behavior Detection Rule | |
Rule | BehaviorRule |
BehaviorRule (PSCustomObject)
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]