End Users¶
List users¶
-
GET
/api/v1/tenants/
(string: tenant_id)/groups/
(string: group_id)/users/
¶ List the users (without service users) known in the group by case sensitive username containing the given string.
Example request:
GET /api/v1/tenants/foo/groups/foogroup/users/ HTTP/1.1 Host: example.com { "sensitiveUserNameContains": "Test" }
List all the users known in the group by case sensitive username containing the given string.
Example request:
GET /api/v1/tenants/foo/groups/foogroup/users/ HTTP/1.1 Host: example.com { "sensitiveUserNameContains": "Test", "includeHiddenUsers": true }
- Request JSON Object:
sensitiveUserIdStarts (string) – See sensitiveUserIdStarts from Search criteria.
sensitiveUserIdContains (string) – See sensitiveUserIdContains from Search criteria.
sensitiveUserIdEquals (string) – See sensitiveUserIdEquals from Search criteria.
insensitiveUserIdStarts (string) – See insensitiveUserIdStarts from Search criteria.
insensitiveUserIdContains (string) – See insensitiveUserIdContains from Search criteria.
insensitiveUserIdEquals (string) – See insensitiveUserIdEquals from Search criteria.
sensitiveUserLastNameStarts (string) – See sensitiveUserLastNameStarts from Search criteria.
sensitiveUserLastNameContains (string) – See sensitiveUserLastNameContains from Search criteria.
sensitiveUserLastNameEquals (string) – See sensitiveUserLastNameEquals from Search criteria.
insensitiveUserLastNameStarts (string) – See insensitiveUserLastNameStarts from Search criteria.
insensitiveUserLastNameContains (string) – See insensitiveUserLastNameContains from Search criteria.
insensitiveUserLastNameEquals (string) – See insensitiveUserLastNameEquals from Search criteria.
sensitiveUserFirstNameStarts (string) – See sensitiveUserFirstNameStarts from Search criteria.
sensitiveUserFirstNameContains (string) – See sensitiveUserFirstNameContains from Search criteria.
sensitiveUserFirstNameEquals (string) – See sensitiveUserFirstNameEquals from Search criteria.
insensitiveUserFirstNameStarts (string) – See insensitiveUserFirstNameStarts from Search criteria.
insensitiveUserFirstNameContains (string) – See insensitiveUserFirstNameContains from Search criteria.
insensitiveUserFirstNameEquals (string) – See insensitiveUserFirstNameEquals from Search criteria.
insensitivePhoneNumberStarts (string) – See insensitivePhoneNumberStarts from Search criteria.
insensitivePhoneNumberContains (string) – See insensitivePhoneNumberContains from Search criteria.
insensitivePhoneNumberEquals (string) – See insensitivePhoneNumberEquals from Search criteria.
sensitiveEmailAddressStarts (string) – See sensitiveEmailAddressStarts from Search criteria.
sensitiveEmailAddressContains (string) – See sensitiveEmailAddressContains from Search criteria.
sensitiveEmailAddressEquals (string) – See sensitiveEmailAddressEquals from Search criteria.
insensitiveEmailAddressStarts (string) – See insensitiveEmailAddressStarts from Search criteria.
insensitiveEmailAddressContains (string) – See insensitiveEmailAddressContains from Search criteria.
insensitiveEmailAddressEquals (string) – See insensitiveEmailAddressEquals from Search criteria.
insensitiveExtensionStarts (string) – See insensitiveExtensionStarts from Search criteria.
insensitiveExtensionContains (string) – See insensitiveExtensionContains from Search criteria.
insensitiveExtensionEquals (string) – See insensitiveExtensionEquals from Search criteria.
insensitiveUserInTrunkGroupEquals (string) – See insensitiveUserInTrunkGroupEquals from Search criteria.
sensitiveDepartmentEquals (object) – See sensitiveDepartmentEquals from Search criteria.
responseSizeLimit (integer) – See responseSizeLimit from Search criteria.
includeHiddenUsers (boolean) – See includeHiddenUsers from Search criteria.
Example response:
HTTP/1.1 200 OK Content-Type: "application/json" { "users": [ {"userId": "user1@netaxis.be", "firstName": "tom", "lastName": "smith", "extension": "1234", "emailAddress": "", "phoneNumber": "+3225126777", "inTrunkGroup": false}, {"userId": "user2@sip.netaxis.be", "firstName": "john", "lastName": "doe", "extension": "4321", "emailAddress": "", "department": {"tenantId": "ApioSpTest", "groupId": "ApioGrpTest", "departmentName": "test_department_initial", "fullPathName": "test_department_parent_1 \\ test_department_initial"}, "phoneNumber": "+3225125757", "inTrunkGroup": false} ] }
- Response JSON Object:
users (array) – a list of user objects as defined as User in List attributes.
- Status Codes:
200 OK – no error
Create an user¶
-
POST
/api/v1/tenants/
(string: tenant_id)/groups/
(string: group_id)/users/
¶ Create a user in the group.
Example request:
POST /api/v1/tenants/foo/groups/foogroup/users/ HTTP/1.1 Host: example.com Content-Type: "application/json" { "firstName": "tom", "lastName": "smith", "extension": "1234", "emailAddress": "test_email@netaxis.be", "phoneNumber": "+3225126777" }
- Request JSON Object:
userId (string) – See userId from User Profile Attributes.
lastName (string) – See lastName from User Profile Attributes.
firstName (string) – See firstName from User Profile Attributes.
cliLastName (string) – See cliLastName from User Profile Attributes.
cliFirstName (string) – See cliFirstName from User Profile Attributes.
department (object) – An object as Group department key attributes.
phoneNumber (string) – See phoneNumber from User Profile Attributes.
extension (string) – See extension from User Profile Attributes.
password (string) – See password from User Profile Attributes.
cliPhoneNumber (string) – See cliPhoneNumber from User Profile Attributes.
language (string) – See language from User Profile Attributes.
emailAddress (string) – See emailAddress from User Profile Attributes.
timeZone (string) – See timeZone from User Profile Attributes.
accessDeviceEndpoint (object) – (Optional) An access device endpoint as defined in Access Device Endpoint. Mutually exclsuive with trunkEndpoint.
trunkEndpoint (object) – (Optional) A trunk endpoint as defined in Trunk Endpoint. Mutually exclusive with accessDeviceEndpoint.
templateName (string) – (Optional) The name of the template to be used during the User creation.
title (string) – See title from User Profile Attributes.
pagerPhoneNumber (string) – See pagerPhoneNumber from User Profile Attributes.
mobilePhoneNumber (string) – See mobilePhoneNumber from User Profile Attributes.
yahooId (string) – See yahooId from User Profile Attributes.
addressLocation (string) – See addressLocation from User Profile Attributes.
address (object) – See address from User Profile Attributes.
- Note:
accessDeviceEndpoint and trunkEndpoint are mutually exclusive fields.
Example response:
- Response JSON Object:
userId (string) – See userId from User Profile Attributes. It is provided because it can be auto-generated
lastName (string) – See lastName from User Profile Attributes.
firstName (string) – See firstName from User Profile Attributes.
cliLastName (string) – See cliLastName from User Profile Attributes.
cliFirstName (string) – See cliFirstName from User Profile Attributes.
department (object) – An object as Group department key attributes.
phoneNumber (string) – See phoneNumber from User Profile Attributes.
extension (string) – See extension from User Profile Attributes.
cliPhoneNumber (string) – See cliPhoneNumber from User Profile Attributes.
language (string) – See language from User Profile Attributes.
emailAddress (string) – See emailAddress from User Profile Attributes.
networkClassOfService (string) – See networkClassOfService from User Profile Attributes.
timeZone (string) – See timeZone from User Profile Attributes.
accessDeviceEndpoint (object) – (Optional) An access device endpoint as defined in Access Device Endpoint.
trunkEndpoint (object) – (Optional) A trunk endpoint as defined in Trunk Endpoint.
title (string) – See title from User Profile Attributes.
pagerPhoneNumber (string) – See pagerPhoneNumber from User Profile Attributes.
mobilePhoneNumber (string) – See mobilePhoneNumber from User Profile Attributes.
yahooId (string) – See yahooId from User Profile Attributes.
addressLocation (string) – See addressLocation from User Profile Attributes.
address (object) – See address from User Profile Attributes.
- Status Codes:
201 Created – no error
Note
See User for more operations on the user.
Template Information for User¶
The template category is user
Configuration Information for the User Id¶
In the POST the userId can be omitted and then it will be auto-generated using the configured rule
The APIO behaviour is controlled by the following settings:
"APIO_OBJECT_CREATION": { "GENERATED_ID_DATA": true, }, "AUTOMATIC_ID_RULES": { "USER_ID_AUTO_GENERATE": true, "USER_ID_RULE": "{{group_id}}_u{{RND_4}}@{{domain}}" }
- Explanation fo the parameters:
USER_ID_AUTO_GENERATE: If set to True and no user id is provided in the data, one will be generated. Default is True.
GENERATED_ID_DATA: APIO will enable the auto-generation of ids. Default is False.
USER_ID_RULE: the formatting rule for the user id. Default is “{{group_id}}_u{{RND_4}}@{{domain}}”.
- In these rules the following variables can be used:
phone_number_e164: The phone number in E164 format
country_code: The country code of the phone number
national_no_0: The national number, without trailing 0, of the phone number
domain: the domain
tenant_id: the Tenant Id
group_id: the Group Id
Configuration Information for the Line Port¶
In the POST and PUT instance APIs a line port can be specified when a (trunk) device is linked to a user.
The APIO behaviour is controlled by the following settings:
"USER_LINE_PORT_ALLOW_INPUT" : False, "USER_TRUNK_LINE_PORT_ALLOW_INPUT" : True, "APIO_OBJECT_CREATION": { "GENERATED_ID_DATA": True, }, "AUTOMATIC_ID_RULES": { "LINE_PORT_USER_MAIN_DEVICE": "{{phone_number_e164}}@{{domain}}", "FALLBACK_LINE_PORT_USER_MAIN_DEVICE": "{{user_id}}@{{domain}}", "LINE_PORT_TRUNK_USER": "{{phone_number_e164}}@{{domain}}" }
By default the line_port of a User is of the format LP_test_user@sip.netxais.be where test_user is the user part of the user_id. If an other format is needed the Automatic Id mechanism can be used.It must be enabled using the GENERATED_ID_DATA wiuth value True and by specifying a LINE_PORT_USER_MAIN_DEVICE formating rule and optionaly a FALLBACK_LINE_PORT_USER_MAIN_DEVICE formating rule.- Explanation fo the parameters:
USER_LINE_PORT_ALLOW_INPUT: If set to True and a line port for an access device is provided in the API it will be used, in all other cases the APIO will generate one. Default is False.
USER_TRUNK_LINE_PORT_ALLOW_INPUT: If set to True and a line port for a trunk device is provided in the API it will be used, in all other cases the APIO will generate one. Default is True.
GENERATED_ID_DATA: APIO will enable the autogeneration of ids. Default is False.
LINE_PORT_USER_MAIN_DEVICE: the formating rule for the line port. None by default.
FALLBACK_LINE_PORT_USER_MAIN_DEVICE: the fallback formating rule if the main one has failed (for example based on a phone number but the user has no phone number). None by default.
LINE_PORT_TRUNK_USER: the formating rule for the line port in case the user is linked to a Trunk Group ‘trunkEndpoint). It must be noted that this feature should in theorey be used via the specific Trunk Users APIs. None by default.
- In these rules the following variables can be used:
phone_number_e164: The phone number in E164 format
country_code: The country code of the phone number
national_no_0: The national number, without trailing 0, of the phone number
domain: the domain
tenant_id: the Tenant Id
group_id: the Group Id
user_id: the user part (aka left part) of the user id
Configuration Information for the Password¶
The APIO behaviour for the validation of the passwords is controlled by the following setting:
"VALIDATE_PASSWORD_LOCALLY": true "VALIDATE_PASSWORD_LOCAL_RULE": true
- Settings description:
VALIDATE_PASSWORD_LOCALLY: APIO will check the password provided in the API based on the user level rules from the network element. Default is false.
VALIDATE_PASSWORD_LOCAL_RULE: if the previous settings is false and that this settings is true, the APIO will check the password with respect to an hardcoded local rule (min 8 chars, aat least 1 upper and 1 lower cases). This local rule can be overwritten in project mode. Default is false.
When no password is provided in the API data, then one will be generated. The generation will, by default, be based on the rules defined in the AS with the possibility (from 1.11.0) to have minium rules defined.
This is controlled by following parameters:
"NEW_PASSWORD_RESET_GEN": true, "MINIMUM_PASSWORD_RULES": { "END_USER" : { "PASSWORD_MIN_SPECIAL_CHARACTERS": 1, "PASSWORD_MIN_UPPERCASE_LETTERS": 1, "PASSWORD_MIN_LOWERCASE_LETTERS": 1, "PASSWORD_MIN_DIGITS": 1, "PASSWORD_MIN_LENGTH": 8 } },
- Settings description:
NEW_PASSWORD_RESET_GEN: If true the new logic based on rules will be used for the random passwords generation. Else the legacy hardcoded config will be used (and the minimum rules ignored). Default is true. Note that this is a global parameter.
MINIMUM_PASSWORD_RULES.**END_USER**: (from 1.11.0) minium password rules for End Users. Default are the ones in the example. Please note that this settings will also be used when creating hidden users for APIO features.
Configuration Information for the User Ids in the List answer¶
The APIO will add the AS System Default Domain to be User Ids in the answer of the List API or not depending on the following setting:
DISPLAY_USER_ID_WITH_SYSTEM_DEFAULT_DOMAIN": true
- Settings description:
DISPLAY_USER_ID_WITH_SYSTEM_DEFAULT_DOMAIN: (Boolean) Adapt the OCI answers. Default is true.
This has been introduced in release 1.10.3.