Checking the number of users to be imported from LDAP servers

Ops Center Common Services REST API Reference Guide

Version
10.9.x
File Size
533 KB
Audience
anonymous
Part Number
MK-99OPS003-06
Check the number of users to be imported from LDAP servers that are not Active Directory servers.

Execution permission

You must be a system administrator or a security administrator.

Request line

POST base-URL/security/v1/external-user-storage-test-search-limit-exceeded

Request message

Object ID
None.
Query parameters
None.
Body
{
    "connectionUrl": "ldaps://example.com",
    "bindDn": "cn=Directory Manager",
    "bindPassword": "password",
    "baseDn": "OU=Subtree,DC=example,DC=com",
    "objectClasses": "person, organizationalPerson",
    "searchScope": "1",
    "customUserSearchFilter": "(ou=Ops Center*)",
    "usernameLDAPAttribute": "uid"
}

Attribute

Type

Description

connectionUrl

string

(Required) URL of the connection-destination LDAP server

Specify a URL that starts with ldaps:// .

bindDn

string

(Required) Bind DN

bindPassword

string

(Required) Password for the bind DN

baseDn

string

(Required) BaseDN

objectClasses

string

(Required) The object class of the users to be imported

To specify multiple values, separate the values by using commas.

searchScope

string

(Required) The range of hierarchy levels in which to search for users to be imported

Specify either of the following.

  • 1: One level
  • 2: Subtree

customUserSearchFilter

string

(Optional) The search filter for narrowing down the users to be imported

The syntax of the search filter conforms to RFC 2254.

usernameLDAPAttribute

string

(Required) LDAP attribute that uniquely identifies the imported user

Response message

Body
{
    "count" : 0,
    "maxValue" : 100
}

Attribute

Type

Description

count

int

The number of LDAP server users to be imported

If the number of users is greater than the value of the maxValue attribute, -1 is returned.

maxValue

int

The maximum number of LDAP server users that can be imported to Common Services

Coding example

curl -v -X POST -H "Content-Type:application/json" -s "https://example.com:443/portal/security/v1/external-user-storage-test-search-limit-exceeded" -d @./request.json -H "Authorization:Bearer eyJhbxxx"
Tip: Because this request uses SSL communication, you must either run the curl command with the root certificate of the Common Services server certificate specified for the --cacert option, or run the command with the -k option specified. (The -k option runs the command by ignoring SSL errors.)