User Tools

Site Tools


api:presenceproxy:update

API : Presence Proxy Update

Introduction

This request will update an existing Presence Proxy server.

Request

URL https://api.telecomx.dk/presenceproxy/PRESENCE_PROXY_ID
Method POST
Access level OWNER, RESELLER or ADMIN
Params PRESENCE_PROXY_ID Id of the Presence Proxy (25-char hex string).
Body license String License model:
TCX1 (up to 25 users on TCX network)
TCX2 (over 25 users on TCX network)
OTHER1 - up to 25 users on 3rd party network
OTHER2 - over 25 users on 3rd party network
ipAddress String IP address to listen for call events (on proxy server).
ipPort Number Port number to listen for call events (on proxy server).
oipServer String IP address of the OIP server.
calendarMessage String Message to show in calendar appointment when busy on mobile phone.
calendarRemote Boolean If remote caller/callee's number should be appended to the calendarMessage.
calendarState String State to set on user when busy: UNKNOWN, AVAILABLE, MEETING, OCCUPIED, NOT_AVAILABLE, ABSENT.
calendarLength Number Duration of the calendar item in minutes, default 30.
provider String Name of provider of call events: TELECOMX, TDC, TELENOR, TELIA, 3, OTHER.
providerSettings Object Provider specific configuration - currently only for Telenor.
providerSettings.username String Username for Telenor long polling interface.
providerSettings.password String Password for Telenor long polling interface.
providerSettings.host String Host name and port for Telenor long polling interface.
providerSettings.pni String PNI code for Telenor.
users Array List of mobile users.
users[x].user String User name, usually extension.
users[x].pin String User pin or password.
users[x].number String Users 8-digit mobile phone number.

Only the properties that need to be updated must be provided. If Users are provided, the complete user list must always be sent.

Query examples

{
  ipAddress: '192.168.1.22',
  ipPort: 55555,
  oipServer: '192.168.1.22'
}

Response

The updated Presence Proxy server.

JSON object
_id ObjectId Unique ID of the presence proxy.
customer ObjectId Id of customer.
license String License model:
TCX1 (up to 25 users on TCX network)
TCX2 (over 25 users on TCX network)
OTHER1 - up to 25 users on 3rd party network
OTHER2 - over 25 users on 3rd party network
ipAddress String IP address to listen for call events (on proxy server).
ipPort Number Port number to listen for call events (on proxy server).
accessToken String Auto-generated access token, required by the Presence Proxy to fetch its configuration.
oipServer String IP address of the OIP server.
calendarMessage String Message to show in calendar appointment when busy on mobile phone.
calendarRemote Boolean If remote caller/callee's number should be appended to the calendarMessage.
calendarState String State to set on user when busy: UNKNOWN, AVAILABLE, MEETING, OCCUPIED, NOT_AVAILABLE, ABSENT.
calendarLength Number Duration of the calendar item in minutes, default 30.
provider String Name of provider of call events: TELECOMX, TDC, TELENOR, TELIA, 3, OTHER.
providerSettings Object Provider specific configuration - currently only for Telenor.
providerSettings.username String Username for Telenor long polling interface.
providerSettings.password String Password for Telenor long polling interface.
providerSettings.host String Host name and port for Telenor long polling interface.
providerSettings.pni String PNI code for Telenor.
users Array List of mobile users.
users[x].user String User name, usually extension.
users[x].pin String User pin or password.
users[x].number String Users 8-digit mobile phone number.
synced Date Date and time when the presence proxy server last fetched it's configuration.

Note that properties holding no value may be omitted from the object.

Example

{
  _id: ObjectId('12345678901234567890ABCD'),
  customer: ObjectId('12345678901234567890BBBB'),
  license: 'TCX1',
  ipAddress: '192.168.1.22',
  ipPort: 55555,
  accessToken: '8fhyyuvhewfuvhwru329eu37etudsgew8gdd',
  oipServer: '192.168.1.22',
  calendarMessage: 'Mobile busy',
  calendarRemote: true,
  calendarState: 'OCCUPIED',
  calendarLength: 30,
  provider: 'TELENOR',
  providerSettings: {
    username: 'ew238feghjie2',
    password: 'sdw2hyufbjkw',
    host: 'http://12.34.56.78:1234'
  },
  users: [
    {
      user: '201',
      pin: '1234',
      number: '81808888'
    },
    ...
  ],
  synced: ISODate('2016-01-01T00:00:00.000Z')
}

Errors

Error code Message Description
403 access_denied Insufficient access level
422 users[x] Required user data missing
422 providerSettings Provider settings are missing or invalid
404 users No users found
422 ipAddress Invalid IP address
422 ipPort Port is invalid
422 oipServer Invalid OIP server IP address
422 calendarLength Length is invalid, only 5, 10, 15, 20, 30, 45, 120 or 180 is allowed
500 internal_error <Unspecified>
api/presenceproxy/update.txt · Last modified: 2017/08/07 10:34 by Per Møller

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki