Skip to end of metadata
Go to start of metadata

This page is currently being written. Although the information below is probably accurate, it may not be complete or may have errors.

The information on this page applies to iSymphony 3.1+.

Description

The Asterisk parking lot REST resource allows access to the configuration for parking lots in the system. This resource allows adding, removing, and updating of parking lots in the system.

 

On this page:

 

Root Resource Path

communication_manager/rest/config/asterisk/{coreServerId}/parkingLots

JSON Representation

{
  "id": "ce87c947-81a4-4c10-80ec-0a3f4d67a460",
  "name": "Main",
  "identifier": "default",
  "destinationExtension": "70",
  "destinationContext": "from-internal",
  "permissionDisplayName": "Main <default>",
  "permissionId": "ce87c947-81a4-4c10-80ec-0a3f4d67a460"
}
PropertyTypeDescription
id
String

Configuration id of the parking lot.

name
StringThe display name of the parking lot.
identifierStringThe Asterisk identifier of the parking lot.
destinationExtension
StringThe extension used to call the parking lot from the panel.
destinationContext
StringThe context used to call the parking lot from the panel.
permissionDisplayName
StringDisplay name of the parking lot in the permission system.
permissionId
StringPermission id of the parking lot.

Resource Paths

communication_manager/rest/config/asterisk/{coreServerId}/parkingLots
DescriptionAccesses all the parking lots in the core server.
GET Gets all the configuration for all the parking lot in the system.
POST

Adds a parking lot to the configuration.

Errors:

  • 409 'A parkingLot with the given id already exists.': Returned if a parking lot with the given id already exists.
  • 409 'A parkingLot with the given identifier already exists.': Returned if a parking lot with the given identifier already exists.
  • 412 'No identifier provided.': Returned if no identifier was provided.
  • 412 'No displayName provided.': Returned if no display name was provided.
  • 412 'No destinationContext provided.': Returned if no destination context was provided.
  • 412 'No destinationExtension provided.': Returned if no destination extension was provided.
 
communication_manager/rest/config/asterisk/{coreServerId}/parkingLots/{parkingLotId}
Description

Accesses the configuration of a specific parking lot.

Parameters:

  • parkingLotId: The configuration id of the parking lot.
GET

Gets the configuration of the specified parking lot.

Errors:

  • 404 'A parking lot with the given id does not exist': Returned if no parking lot exists with the given id.
PUT

Updates the specified parking lot configuration.

Errors:

  • 404 'A parkingLot with the given id does not exist': Returned if no parking lot exists with the given id.
  • 409 'A parkingLot with the given identifier already exists.': Returned if a parking lot with the given identifier already exists.
  • 412 'No identifier provided.': Returned if no identifier was provided.
  • 412 'No displayName provided.': Returned if no display name was provided.
  • 412 'No destinationContext provided.': Returned if no destination context was provided.
  • 412 'No destinationExtension provided.': Returned if no destination extension was provided.
DELETE

Deletes the specified parking lot.

Errors:

  • 404 'A ParkingLot with the given id does not exist': Returned if no parking lot exists with the given id.

Curl Examples

Get all parking lots in a core server

curl --user manager:manag3rpa55word -k -i -H "Accept: application/json" http://localhost:58080/communication_manager/rest/config/asterisk/ee828da8-5ee6-412d-82ac-1273f598659d/parkingLots

Get the configuration for a specific parking lot

curl --user manager:manag3rpa55word -k -i -H "Accept: application/json" http://localhost:58080/communication_manager/rest/config/asterisk/ee828da8-5ee6-412d-82ac-1273f598659d/parkingLots/56cf70a3-1ee0-4b09-8f40-297430eeeddf

Add a new parking lot

curl --user manager:manag3rpa55word -k -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"id":"ce87c947-81a4-4c10-80ec-0a3f4d67a460","name":"Main","identifier":"default","destinationExtension":"70","destinationContext":"from-internal"}' http://localhost:58080/communication_manager/rest/config/asterisk/ee828da8-5ee6-412d-82ac-1273f598659d/parkingLots

Delete a parking lot

curl --user manager:manag3rpa55word -k -i -X DELETE http://localhost:58080/communication_manager/rest/config/asterisk/ee828da8-5ee6-412d-82ac-1273f598659d/parkingLots/56cf70a3-1ee0-4b09-8f40-297430eeeddf

Update a parking lot

curl --user manager:manag3rpa55word -k -i -H "Content-Type: application/json" -H "Accept: application/json" -X PUT -d '{"id":"ce87c947-81a4-4c10-80ec-0a3f4d67a460","name":"Main New","identifier":"default","destinationExtension":"70","destinationContext":"from-internal"}' http://localhost:58080/communication_manager/rest/config/asterisk/ee828da8-5ee6-412d-82ac-1273f598659d/parkingLots/ce87c947-81a4-4c10-80ec-0a3f4d67a460
  • No labels