Skip to content

Latest commit

 

History

History
executable file
·
766 lines (553 loc) · 28.6 KB

GroAdminLDAPApi.md

File metadata and controls

executable file
·
766 lines (553 loc) · 28.6 KB

GrommunioAdmin.GrommunioAdmin/Api.GroAdminLDAPApi

All URIs are relative to /api/v1

Method HTTP request Description
Invoke-GroAdminCheckUsers GET /domains/ldap/check checkUsers
Invoke-GroAdminDeleteLDAPConf DELETE /system/mconf/ldap deleteLDAPConf
Invoke-GroAdminDeleteOrgLDAPConf DELETE /system/orgs/{ID}/ldap deleteOrgLDAPConf
Invoke-GroAdminDeleteOrphaned DELETE /domains/ldap/check deleteOrphaned
Get-GroAdminLDAP GET /domains/ldap/dump dumpLDAP
Get-GroAdminLDAPConf GET /system/mconf/ldap getLDAPConf
Get-GroAdminOrgLDAPConf GET /system/orgs/{ID}/ldap getOrgLDAPConf
Import-GroAdminLdapUser POST /domains/ldap/importUser importLdapUser
Send-GroAdminDownsync PUT /domains/{domainID}/users/{userID}/downsync putDownsync
Search-GroAdminLDAP GET /domains/ldap/search searchLDAP
Set-GroAdminLDAPConf PUT /system/mconf/ldap setLDAPConf
Set-GroAdminOrgLDAPConf PUT /system/orgs/{ID}/ldap setOrgLDAPConf
Update-GroAdminAllDomainUsers POST /domains/{domainID}/ldap/downsync updateAllDomainUsers
Update-GroAdminAllUsers POST /domains/ldap/downsync updateAllUsers
Update-GroAdminOrgLDAPUsers POST /system/orgs/{ID}/ldap/downsync updateOrgLDAPUsers

Invoke-GroAdminCheckUsers

DomainsLdapCheckResponse Invoke-GroAdminCheckUsers
        [-Domain] <System.Nullable[Int32]>
        [-Organization] <System.Nullable[Int32]>

checkUsers

Check status of ldap imported users

Example

$Domain = 56 # Int32 | ID of the domain (optional)
$Organization = 56 # Int32 | ID of the organization (optional)

# checkUsers
try {
    $Result = Invoke-GroAdminCheckUsers -Domain $Domain -Organization $Organization
} catch {
    Write-Host ("Exception occurred when calling Invoke-GroAdminCheckUsers: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
Domain Int32 ID of the domain [optional]
Organization Int32 ID of the organization [optional]

Return type

DomainsLdapCheckResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Invoke-GroAdminDeleteLDAPConf

void Invoke-GroAdminDeleteLDAPConf
        [-XCsrfToken]

deleteLDAPConf

Remove LDAP configuration and disable service

Example

$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)

# deleteLDAPConf
try {
    $Result = Invoke-GroAdminDeleteLDAPConf -XCsrfToken $XCsrfToken
} catch {
    Write-Host ("Exception occurred when calling Invoke-GroAdminDeleteLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
XCsrfToken String CSRF Token [optional]

Return type

void (empty response body)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Invoke-GroAdminDeleteOrgLDAPConf

void Invoke-GroAdminDeleteOrgLDAPConf
        [-ID]
        [-XCsrfToken]

deleteOrgLDAPConf

Reset organization specific LDAP configuration

Example

$ID = 56 # Int32 | ID of the object
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)

# deleteOrgLDAPConf
try {
    $Result = Invoke-GroAdminDeleteOrgLDAPConf -ID $ID -XCsrfToken $XCsrfToken
} catch {
    Write-Host ("Exception occurred when calling Invoke-GroAdminDeleteOrgLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID Int32 ID of the object
XCsrfToken String CSRF Token [optional]

Return type

void (empty response body)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Invoke-GroAdminDeleteOrphaned

DomainsLdapCheckResponse1 Invoke-GroAdminDeleteOrphaned
        [-XCsrfToken]
        [-DeleteFiles] <System.Nullable[Boolean]>

deleteOrphaned

Check status of ldap import users and delete orphaned

Example

$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$DeleteFiles = $true # Boolean | Delete user files on disk (optional) (default to $false)

# deleteOrphaned
try {
    $Result = Invoke-GroAdminDeleteOrphaned -XCsrfToken $XCsrfToken -DeleteFiles $DeleteFiles
} catch {
    Write-Host ("Exception occurred when calling Invoke-GroAdminDeleteOrphaned: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
XCsrfToken String CSRF Token [optional]
DeleteFiles Boolean Delete user files on disk [optional] [default to $false]

Return type

DomainsLdapCheckResponse1 (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Get-GroAdminLDAP

DomainsLdapDumpResponse Get-GroAdminLDAP
        [-ID]
        [-Domain] <System.Nullable[Int32]>
        [-Organization] <System.Nullable[Int32]>

dumpLDAP

Dump LDAP object

Example

$ID = "MyID" # String | LDAP object ID of the person to import
$Domain = 56 # Int32 | ID of the domain (optional)
$Organization = 56 # Int32 | ID of the organization (optional)

# dumpLDAP
try {
    $Result = Get-GroAdminLDAP -ID $ID -Domain $Domain -Organization $Organization
} catch {
    Write-Host ("Exception occurred when calling Get-GroAdminLDAP: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID String LDAP object ID of the person to import
Domain Int32 ID of the domain [optional]
Organization Int32 ID of the organization [optional]

Return type

DomainsLdapDumpResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Get-GroAdminLDAPConf

SystemMconfLdapResponse Get-GroAdminLDAPConf

getLDAPConf

Get the current LDAP configuration

Example

# getLDAPConf
try {
    $Result = Get-GroAdminLDAPConf
} catch {
    Write-Host ("Exception occurred when calling Get-GroAdminLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

This endpoint does not need any parameter.

Return type

SystemMconfLdapResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Get-GroAdminOrgLDAPConf

SystemOrgsLdapResponse Get-GroAdminOrgLDAPConf
        [-ID]

getOrgLDAPConf

Get organization specific LDAP configuration

Example

$ID = 56 # Int32 | ID of the object

# getOrgLDAPConf
try {
    $Result = Get-GroAdminOrgLDAPConf -ID $ID
} catch {
    Write-Host ("Exception occurred when calling Get-GroAdminOrgLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID Int32 ID of the object

Return type

SystemOrgsLdapResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Import-GroAdminLdapUser

ImportLdapUser200Response Import-GroAdminLdapUser
        [-ID]
        [-XCsrfToken]
        [-Force] <System.Nullable[Boolean]>
        [-Lang]
        [-Domain] <System.Nullable[Int32]>
        [-Organization] <System.Nullable[Int32]>

importLdapUser

Import user from ldap

Example

$ID = "MyID" # String | LDAP object ID of the person to import
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$Force = $true # Boolean | Force update existing users that are not associated with the LDAP object (optional) (default to $false)
$Lang = "MyLang" # String | Default language for imported users (optional)
$Domain = 56 # Int32 | ID of the domain (optional)
$Organization = 56 # Int32 | ID of the organization (optional)

# importLdapUser
try {
    $Result = Import-GroAdminLdapUser -ID $ID -XCsrfToken $XCsrfToken -Force $Force -Lang $Lang -Domain $Domain -Organization $Organization
} catch {
    Write-Host ("Exception occurred when calling Import-GroAdminLdapUser: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID String LDAP object ID of the person to import
XCsrfToken String CSRF Token [optional]
Force Boolean Force update existing users that are not associated with the LDAP object [optional] [default to $false]
Lang String Default language for imported users [optional]
Domain Int32 ID of the domain [optional]
Organization Int32 ID of the organization [optional]

Return type

ImportLdapUser200Response (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Send-GroAdminDownsync

User Send-GroAdminDownsync
        [-DomainID]
        [-UserID]
        [-XCsrfToken]
        [-ID]
        [-Lang]

putDownsync

Update user from LDAP

Example

$DomainID = 56 # Int32 | ID of the domain
$UserID = 56 # Int32 | ID of the user
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$ID = "MyID" # String | Optional LDAP object ID (optional)
$Lang = "MyLang" # String | Default language for imported users (optional)

# putDownsync
try {
    $Result = Send-GroAdminDownsync -DomainID $DomainID -UserID $UserID -XCsrfToken $XCsrfToken -ID $ID -Lang $Lang
} catch {
    Write-Host ("Exception occurred when calling Send-GroAdminDownsync: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
DomainID Int32 ID of the domain
UserID Int32 ID of the user
XCsrfToken String CSRF Token [optional]
ID String Optional LDAP object ID [optional]
Lang String Default language for imported users [optional]

Return type

User (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Search-GroAdminLDAP

DomainsLdapSearchResponse Search-GroAdminLDAP
        [-Query]
        [-Limit] <System.Nullable[Int32]>
        [-Domain] <System.Nullable[Int32]>
        [-Organization] <System.Nullable[Int32]>
        [-ShowAll] <System.Nullable[Boolean]>

searchLDAP

Perform LDAP user search

Example

$Query = "MyQuery" # String | Search term
$Limit = 56 # Int32 | Maximum number of results to return (optional) (default to 50)
$Domain = 56 # Int32 | ID of the domain (optional)
$Organization = 56 # Int32 | ID of the organization (optional)
$ShowAll = $true # Boolean | Do not filter un-importable results (optional) (default to $false)

# searchLDAP
try {
    $Result = Search-GroAdminLDAP -Query $Query -Limit $Limit -Domain $Domain -Organization $Organization -ShowAll $ShowAll
} catch {
    Write-Host ("Exception occurred when calling Search-GroAdminLDAP: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
Query String Search term
Limit Int32 Maximum number of results to return [optional] [default to 50]
Domain Int32 ID of the domain [optional]
Organization Int32 ID of the organization [optional]
ShowAll Boolean Do not filter un-importable results [optional] [default to $false]

Return type

DomainsLdapSearchResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Set-GroAdminLDAPConf

void Set-GroAdminLDAPConf
        [-XCsrfToken]
        [-Force] <System.Nullable[Boolean]>
        [-SetOrgLDAPConfRequest]

setLDAPConf

Set new LDAP configuration

Example

$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$Force = $true # Boolean | Update configuration even if validation failed (optional)
$LdapConfigConnection = Initialize-LdapConfigConnection -Server "MyServer" -BindUser "MyBindUser" -BindPass "MyBindPass" -Starttls $false
$LdapConfigUsers = Initialize-LdapConfigUsers -Username "MyUsername" -DisplayName "MyDisplayName" -Filters "MyFilters" -VarFilter "(&(objectclass=person)(mailPrimaryAddress=*))" -Templates "MyTemplates" -Attributes @{ key_example = "MyInner" } -DefaultQuota 0 -SearchAttributes "MySearchAttributes" -Aliases "MyAliases"
$SetOrgLDAPConfRequest = Initialize-SetOrgLDAPConfRequest -Disabled $false -Connection $LdapConfigConnection -BaseDn "MyBaseDn" -ObjectID "MyObjectID" -Users $LdapConfigUsers # SetOrgLDAPConfRequest |  (optional)

# setLDAPConf
try {
    $Result = Set-GroAdminLDAPConf -XCsrfToken $XCsrfToken -Force $Force -SetOrgLDAPConfRequest $SetOrgLDAPConfRequest
} catch {
    Write-Host ("Exception occurred when calling Set-GroAdminLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
XCsrfToken String CSRF Token [optional]
Force Boolean Update configuration even if validation failed [optional]
SetOrgLDAPConfRequest SetOrgLDAPConfRequest [optional]

Return type

void (empty response body)

Authorization

No authorization required

HTTP request headers

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

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Set-GroAdminOrgLDAPConf

void Set-GroAdminOrgLDAPConf
        [-ID]
        [-XCsrfToken]
        [-SetOrgLDAPConfRequest]

setOrgLDAPConf

Set organization specific LDAP configuration

Example

$ID = 56 # Int32 | ID of the object
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$LdapConfigConnection = Initialize-LdapConfigConnection -Server "MyServer" -BindUser "MyBindUser" -BindPass "MyBindPass" -Starttls $false
$LdapConfigUsers = Initialize-LdapConfigUsers -Username "MyUsername" -DisplayName "MyDisplayName" -Filters "MyFilters" -VarFilter "(&(objectclass=person)(mailPrimaryAddress=*))" -Templates "MyTemplates" -Attributes @{ key_example = "MyInner" } -DefaultQuota 0 -SearchAttributes "MySearchAttributes" -Aliases "MyAliases"
$SetOrgLDAPConfRequest = Initialize-SetOrgLDAPConfRequest -Disabled $false -Connection $LdapConfigConnection -BaseDn "MyBaseDn" -ObjectID "MyObjectID" -Users $LdapConfigUsers # SetOrgLDAPConfRequest |  (optional)

# setOrgLDAPConf
try {
    $Result = Set-GroAdminOrgLDAPConf -ID $ID -XCsrfToken $XCsrfToken -SetOrgLDAPConfRequest $SetOrgLDAPConfRequest
} catch {
    Write-Host ("Exception occurred when calling Set-GroAdminOrgLDAPConf: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID Int32 ID of the object
XCsrfToken String CSRF Token [optional]
SetOrgLDAPConfRequest SetOrgLDAPConfRequest [optional]

Return type

void (empty response body)

Authorization

No authorization required

HTTP request headers

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

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Update-GroAdminAllDomainUsers

DomainsLdapDownsyncResponse Update-GroAdminAllDomainUsers
        [-DomainID]
        [-XCsrfToken]
        [-Import] <System.Nullable[Boolean]>
        [-Lang]
        [-Timeout] <System.Nullable[Double]>

updateAllDomainUsers

Update all LDAP imported users in this domain

Example

$DomainID = 56 # Int32 | ID of the domain
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$Import = $true # Boolean | Import new users from LDAP (optional)
$Lang = "MyLang" # String | Default language for imported users (optional)
$Timeout = 1.2 # Double | Time in seconds to wait for completion (optional) (default to 1)

# updateAllDomainUsers
try {
    $Result = Update-GroAdminAllDomainUsers -DomainID $DomainID -XCsrfToken $XCsrfToken -Import $Import -Lang $Lang -Timeout $Timeout
} catch {
    Write-Host ("Exception occurred when calling Update-GroAdminAllDomainUsers: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
DomainID Int32 ID of the domain
XCsrfToken String CSRF Token [optional]
Import Boolean Import new users from LDAP [optional]
Lang String Default language for imported users [optional]
Timeout Double Time in seconds to wait for completion [optional] [default to 1]

Return type

DomainsLdapDownsyncResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Update-GroAdminAllUsers

DomainsLdapDownsyncResponse Update-GroAdminAllUsers
        [-XCsrfToken]
        [-Import] <System.Nullable[Boolean]>
        [-Lang]
        [-Timeout] <System.Nullable[Double]>

updateAllUsers

Update all LDAP imported users

Example

$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$Import = $true # Boolean | Import new users from LDAP (optional)
$Lang = "MyLang" # String | Default language for imported users (optional)
$Timeout = 1.2 # Double | Time in seconds to wait for completion (optional) (default to 1)

# updateAllUsers
try {
    $Result = Update-GroAdminAllUsers -XCsrfToken $XCsrfToken -Import $Import -Lang $Lang -Timeout $Timeout
} catch {
    Write-Host ("Exception occurred when calling Update-GroAdminAllUsers: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
XCsrfToken String CSRF Token [optional]
Import Boolean Import new users from LDAP [optional]
Lang String Default language for imported users [optional]
Timeout Double Time in seconds to wait for completion [optional] [default to 1]

Return type

DomainsLdapDownsyncResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

Update-GroAdminOrgLDAPUsers

SystemOrgsLdapDownsyncResponse Update-GroAdminOrgLDAPUsers
        [-ID]
        [-XCsrfToken]
        [-Import] <System.Nullable[Boolean]>
        [-Lang]
        [-Timeout] <System.Nullable[Double]>

updateOrgLDAPUsers

Update all LDAP imported users in this organization

Example

$ID = 56 # Int32 | ID of the object
$XCsrfToken = "MyXCsrfToken" # String | CSRF Token (optional)
$Import = $true # Boolean | Import new users from LDAP (optional)
$Lang = "MyLang" # String | Default language for imported users (optional)
$Timeout = 1.2 # Double | Time in seconds to wait for completion (optional) (default to 1)

# updateOrgLDAPUsers
try {
    $Result = Update-GroAdminOrgLDAPUsers -ID $ID -XCsrfToken $XCsrfToken -Import $Import -Lang $Lang -Timeout $Timeout
} catch {
    Write-Host ("Exception occurred when calling Update-GroAdminOrgLDAPUsers: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
    Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
}

Parameters

Name Type Description Notes
ID Int32 ID of the object
XCsrfToken String CSRF Token [optional]
Import Boolean Import new users from LDAP [optional]
Lang String Default language for imported users [optional]
Timeout Double Time in seconds to wait for completion [optional] [default to 1]

Return type

SystemOrgsLdapDownsyncResponse (PSCustomObject)

Authorization

No authorization required

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]