Extensions

Version 22.1 by michaely on 2015/07/09 19:37
Warning
For security reasons, the document is displayed in restricted mode as it is not the current version. There may be differences and errors due to this.

Description

The live extension REST resource provides access to information about extensions in the system. This resource also provides actions for originating calls, and enabling/disabling Do Not Disturb on an extension.

Information

This resource is restricted by licensing. See the resource and action path information below for more details.


On this page:

The [toc] macro is a standalone macro and it cannot be used inline. Click on this message for details.
 

JSON Representation

{
 "id": "e640205f-bc76-4db4-8e03-bf34eb33a8ce",
 "extensionNumber": "4224",
 "displayName": "Michael Y",
 "configurationId": "813936dd-98a4-4ccc-8bcf-dd1f27673c1f",
 "permissionId": "813936dd-98a4-4ccc-8bcf-dd1f27673c1f"
}

Property

Type

Description

id

String

The id of the extension.

extensionNumber

String

The number used to access the extension.

displayName

String

The display name of the extension.

configurationId

String

The id of the configuration object that represents the extension.

permissionId

String

The extension's permission id.

Root Resource Paths

Paths used to access this resource, in relation to parent resources.

communication_manager/rest/live/coreServers/[{core_server_id} | getByName/{core_server_slug}]/extensions

Description

Provides access to all extensions in a specified core server.

Information

Excludes any extensions that are not bound to a licensed/full user.

Parameters:

  • core_server_id: the id of the parent core server
  • core_server_slug: the slug of the parent core server

Errors:

  • 404 Not Found: Returned if no core server with the given id or slug exists

GET

Gets all extensions in the specified core server.

 

 

communication_manager/rest/live/coreServers/[{core_server_id} | getByName/{core_server_slug}]/user/[{user_id} | getByName/{username}]/extensions

Description

Provides access to all the extensions bound to the specified user.

Information

Excludes any extensions that are not bound to a licensed/full user.

Parameters:

  • core_server_id: the id of the parent core server
  • core_server_slug: the slug of the parent core server
  • user_id: the id of the parent user
  • username: the username of the parent user

Errors:

  • 404 Not Found: Returned if no core server with the given id or slug exists
  • 404 Not Found: Returned if no user with the given id or username exists

GET

Gets all extensions bound to the specified extension.

Instance Resource Paths

Paths used to access a specific instance of this resource.

{root_resource_path}/{extension_id}

Description

Provides access to a specific extension, by extension id.

Information

This resource will not be available if the extension is not bound to a licensed/full user.

Parameters:

  • root_resource_path: One of the root resource paths for this resource. See Root Resource Paths above
  • core_server_id: the id of the parent core server
  • core_server_slug: the slug of the parent core server
  • extension_id: the id of the extension to access

Errors:

  • 404 Not Found: Returned if any of the ancestors in the root resource path could not be found
  • 403 Forbidden: Returned if the extension is not bound to a licensed/full user

GET

Gets the specified extension.

 

{root_resource_path}/getByName/{extension_number}

Description

Provides access to a specific extension, by extension number.

Information

This resource will not be available if the extension is not bound to a licensed/full user.

Parameters:

  • root_resource_path: One of the root resource paths for this resource. See Root Resource Paths above
  • core_server_id: the id of the parent core server
  • core_server_slug: the slug of the parent core server
  • extension_number: the extension number of the extension to access

Errors:

  • 404 Not Found: Returned if any of the ancestors in the root resource path could not be found
  • 403 Forbidden: Returned if if the extension is not bound to a licensed/full user

GET

Gets the specified extension.

Sub Resource Paths

Paths used to access the child resources, this resource provides.

{instance_resource_path}/agents

Description

See Agents.

Information

This resource will not be available if the extension is not bound to a licensed/full user.

Parameters:

  • instance_resource_path: One of the instance resource paths for this resource. See Instance Resource Paths above

Errors:

  • 404 Not Found: Returned if any of the ancestors in the instance resource path could not be found
  • 403 Forbidden: Returned if if the extension is not bound to a licensed/full user
{instance_resource_path}/callSegments

Description

See Call Segments.

Information

This resource will not be available if the extension is not bound to a licensed/full user.

Parameters:

  • instance_resource_path: One of the instance resource paths for this resource. See Instance Resource Paths above

Errors:

  • 404 Not Found: Returned if any of the ancestors in the instance resource path could not be found
  • 403 Forbidden: Returned if if the extension is not bound to a licensed/full user

Action Paths

Actions that can be performed on this resource.

{instance_resource_path}/originate

Description

Originates a call from the specified extension.

Information

This action will not be available if the extension is not bound to a licensed/full user.

Parameters:

  • instance_resource_path: One of the instance resource paths for this resource. See Instance Resource Paths above

Errors:

  • 404 Not Found: Returned if any of the ancestors in the instance resource path could not be found
  • 403 Forbidden: Returned if if the extension is not bound to a licensed/full user

JSON

{
 "destinationNumber": "18005555555"
}

Properties:

Property

Type

Description

destinationNumber

String

The number to originate to.


POST

Originates a call from the specified extension to a destination number.

Curl Examples

Get the status of a user in a specific core server

curl --user manager:manag3rpa55word -i -H "Accept: application/json" http://localhost:58080/communication_manager/rest/live/coreServers/ca5de6c4-17bd-46ce-95a2-8b29c7812ca4/users/status

Set the status of a user in a specific core server

curl --user manager:manag3rpa55word -i -H "Content-Type: application/json" -X POST -d '{"name" : "Went back in time", "type" : "away", "note" : "Tell Doc Brown", "returnTime" : 499132800}' http://localhost:58080/communication_manager/rest/live/coreServers/ca5de6c4-17bd-46ce-95a2-8b29c7812ca4/users/status/set