Skip to content

Commit

Permalink
Automated build 'Automated commit 'ISCCOMPLI-819 : API docs for delet…
Browse files Browse the repository at this point in the history
…e campaign filters API (#1474)

* ISCCOMPLI-819 API docs for delete campaign filters API

* ISCCOMPLI-819 updated the example id' by github action: 6706699674' powershell sdk: 6706708506
  • Loading branch information
tyler-mairose-sp committed Oct 31, 2023
1 parent 1f80188 commit afd4511
Show file tree
Hide file tree
Showing 5 changed files with 153 additions and 1 deletion.
3 changes: 2 additions & 1 deletion PSSailpoint/PSSailpoint.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ FunctionsToExport = 'New-AccessProfile', 'Remove-AccessProfile',
'Get-AccountEntitlements', 'Get-Accounts', 'Send-Account',
'Invoke-ReloadAccount', 'Unlock-Account', 'Update-Account',
'Get-UsagesByAccountId', 'Get-AuthUser', 'Update-AuthUser',
'New-CampaignFilter', 'Get-CampaignFilterById', 'Get-CampaignFilters',
'New-CampaignFilter', 'Remove-CampaignFilters',
'Get-CampaignFilterById', 'Get-CampaignFilters',
'Update-CampaignFilter', 'Complete-Campaign', 'New-Campaign',
'New-CampaignTemplate', 'Remove-CampaignTemplate', 'Remove-Campaigns',
'Get-ActiveCampaigns', 'Get-Campaign', 'Get-CampaignReports',
Expand Down
1 change: 1 addition & 0 deletions PSSailpoint/v3/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ Class | Method | HTTP request | Description
*AuthUserApi* | [**Get-AuthUser**](docs/AuthUserApi.md#Get-AuthUser) | **GET** /auth-users/{id} | Auth User Details
*AuthUserApi* | [**Update-AuthUser**](docs/AuthUserApi.md#Update-AuthUser) | **PATCH** /auth-users/{id} | Auth User Update
*CertificationCampaignFiltersApi* | [**New-CampaignFilter**](docs/CertificationCampaignFiltersApi.md#New-CampaignFilter) | **POST** /campaign-filters | Create a Campaign Filter
*CertificationCampaignFiltersApi* | [**Remove-CampaignFilters**](docs/CertificationCampaignFiltersApi.md#Remove-CampaignFilters) | **POST** /campaign-filters/delete | Deletes Campaign Filters
*CertificationCampaignFiltersApi* | [**Get-CampaignFilterById**](docs/CertificationCampaignFiltersApi.md#Get-CampaignFilterById) | **GET** /campaign-filters/{id} | Get Campaign Filter by ID
*CertificationCampaignFiltersApi* | [**Get-CampaignFilters**](docs/CertificationCampaignFiltersApi.md#Get-CampaignFilters) | **GET** /campaign-filters | List Campaign Filters
*CertificationCampaignFiltersApi* | [**Update-CampaignFilter**](docs/CertificationCampaignFiltersApi.md#Update-CampaignFilter) | **POST** /campaign-filters/{id} | Updates a Campaign Filter
Expand Down
52 changes: 52 additions & 0 deletions PSSailpoint/v3/docs/CertificationCampaignFiltersApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ All URIs are relative to *https://sailpoint.api.identitynow.com/v3*
Method | HTTP request | Description
------------- | ------------- | -------------
[**New-CampaignFilter**](CertificationCampaignFiltersApi.md#New-CampaignFilter) | **POST** /campaign-filters | Create a Campaign Filter
[**Remove-CampaignFilters**](CertificationCampaignFiltersApi.md#Remove-CampaignFilters) | **POST** /campaign-filters/delete | Deletes Campaign Filters
[**Get-CampaignFilterById**](CertificationCampaignFiltersApi.md#Get-CampaignFilterById) | **GET** /campaign-filters/{id} | Get Campaign Filter by ID
[**Get-CampaignFilters**](CertificationCampaignFiltersApi.md#Get-CampaignFilters) | **GET** /campaign-filters | List Campaign Filters
[**Update-CampaignFilter**](CertificationCampaignFiltersApi.md#Update-CampaignFilter) | **POST** /campaign-filters/{id} | Updates a Campaign Filter
Expand Down Expand Up @@ -62,6 +63,57 @@ Name | Type | Description | Notes

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

<a name="Remove-CampaignFilters"></a>
# **Remove-CampaignFilters**
> void Remove-CampaignFilters<br>
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[-RequestBody] <String[]><br>
Deletes Campaign Filters

Deletes campaign filters whose Ids are specified in the provided list of campaign filter Ids. Authorized callers must be an ORG_ADMIN or a CERT_ADMIN.

### Example
```powershell
# general setting of the PowerShell module, e.g. base URL, authentication, etc
$Configuration = Get-Configuration
# Configure OAuth2 access token for authorization: UserContextAuth
$Configuration.AccessToken = "YOUR_ACCESS_TOKEN"
# Configure OAuth2 access token for authorization: UserContextAuth
$Configuration.AccessToken = "YOUR_ACCESS_TOKEN"
$RequestBody = "MyRequestBody" # String[] | A json list of IDs of campaign filters to delete.
# Deletes Campaign Filters
try {
$Result = Remove-CampaignFilters -RequestBody $RequestBody
} catch {
Write-Host ("Exception occurred when calling Remove-CampaignFilters: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**RequestBody** | [**String[]**](String.md)| A json list of IDs of campaign filters to delete. |

### Return type

void (empty response body)

### Authorization

[UserContextAuth](../README.md#UserContextAuth), [UserContextAuth](../README.md#UserContextAuth)

### HTTP request headers

- **Content-Type**: application/json
- **Accept**: application/json

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

<a name="Get-CampaignFilterById"></a>
# **Get-CampaignFilterById**
> CampaignFilterDetails[] Get-CampaignFilterById<br>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,96 @@ function New-CampaignFilter {
<#
.SYNOPSIS
Deletes Campaign Filters
.DESCRIPTION
Deletes campaign filters whose Ids are specified in the provided list of campaign filter Ids. Authorized callers must be an ORG_ADMIN or a CERT_ADMIN.
.PARAMETER RequestBody
A json list of IDs of campaign filters to delete.
.PARAMETER WithHttpInfo
A switch when turned on will return a hash table of Response, StatusCode and Headers instead of just the Response
.OUTPUTS
None
#>
function Remove-CampaignFilters {
[CmdletBinding()]
Param (
[Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $false)]
[String[]]
${RequestBody},
[Switch]
$WithHttpInfo
)

Process {
'Calling method: Remove-CampaignFilters' | Write-Debug
$PSBoundParameters | Out-DebugParameter | Write-Debug

$LocalVarAccepts = @()
$LocalVarContentTypes = @()
$LocalVarQueryParameters = @{}
$LocalVarHeaderParameters = @{}
$LocalVarFormParameters = @{}
$LocalVarPathParameters = @{}
$LocalVarCookieParameters = @{}
$LocalVarBodyParameter = $null

# HTTP header 'Accept' (if needed)
$LocalVarAccepts = @('application/json')

# HTTP header 'Content-Type'
$LocalVarContentTypes = @('application/json')

$LocalVarUri = '/campaign-filters/delete'

if (!$RequestBody) {
throw "Error! The required parameter `RequestBody` missing when calling deleteCampaignFilters."
}

if ($LocalVarContentTypes.Contains('application/json-patch+json')) {
$LocalVarBodyParameter = $RequestBody | ConvertTo-Json -AsArray -Depth 100
} else {
$LocalVarBodyParameter = $RequestBody | ForEach-Object {
# Get array of names of object properties that can be cast to boolean TRUE
# PSObject.Properties - https://msdn.microsoft.com/en-us/library/system.management.automation.psobject.properties.aspx
$NonEmptyProperties = $_.psobject.Properties | Where-Object {$null -ne $_.Value} | Select-Object -ExpandProperty Name

# Convert object to JSON with only non-empty properties
$_ | Select-Object -Property $NonEmptyProperties | ConvertTo-Json -Depth 100
}
}



$LocalVarResult = Invoke-ApiClient -Method 'POST' `
-Uri $LocalVarUri `
-Accepts $LocalVarAccepts `
-ContentTypes $LocalVarContentTypes `
-Body $LocalVarBodyParameter `
-HeaderParameters $LocalVarHeaderParameters `
-QueryParameters $LocalVarQueryParameters `
-FormParameters $LocalVarFormParameters `
-CookieParameters $LocalVarCookieParameters `
-ReturnType "" `
-IsBodyNullable $false

if ($WithHttpInfo.IsPresent) {
return $LocalVarResult
} else {
return $LocalVarResult["Response"]
}
}
}

<#
.SYNOPSIS
Get Campaign Filter by ID
.DESCRIPTION
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,14 @@ Describe -tag 'PSSailpoint' -name 'CertificationCampaignFiltersApi' {
}
}

Context 'Remove-CampaignFilters' {
It 'Test Remove-CampaignFilters' {
#$TestResult = Remove-CampaignFilters -RequestBody "TEST_VALUE"
#$TestResult | Should -BeOfType TODO
#$TestResult.property | Should -Be 0
}
}

Context 'Get-CampaignFilterById' {
It 'Test Get-CampaignFilterById' {
#$TestResult = Get-CampaignFilterById -FilterId "TEST_VALUE"
Expand Down

0 comments on commit afd4511

Please sign in to comment.