UNPKG

purecloud-platform-client-v2

Version:

A JavaScript library to interface with the PureCloud Platform API

1,684 lines (1,535 loc) 102 kB
import ApiClient from '../ApiClient.js'; class TelephonyProvidersEdgeApi { /** * TelephonyProvidersEdge service. * @module purecloud-platform-client-v2/api/TelephonyProvidersEdgeApi * @version 223.0.0 */ /** * Constructs a new TelephonyProvidersEdgeApi. * @alias module:purecloud-platform-client-v2/api/TelephonyProvidersEdgeApi * @class * @param {module:purecloud-platform-client-v2/ApiClient} apiClient Optional API client implementation to use, * default to {@link module:purecloud-platform-client-v2/ApiClient#instance} if unspecified. */ constructor(apiClient) { this.apiClient = apiClient || ApiClient.instance; } /** * Delete a edge. * * @param {String} edgeId Edge ID */ deleteTelephonyProvidersEdge(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling deleteTelephonyProvidersEdge'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}', 'DELETE', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete an edge logical interface * * @param {String} edgeId Edge ID * @param {String} interfaceId Interface ID */ deleteTelephonyProvidersEdgeLogicalinterface(edgeId, interfaceId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling deleteTelephonyProvidersEdgeLogicalinterface'; } // verify the required parameter 'interfaceId' is set if (interfaceId === undefined || interfaceId === null) { throw 'Missing the required parameter "interfaceId" when calling deleteTelephonyProvidersEdgeLogicalinterface'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/logicalinterfaces/{interfaceId}', 'DELETE', { 'edgeId': edgeId,'interfaceId': interfaceId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Cancels any in-progress update for this edge. * * @param {String} edgeId Edge ID */ deleteTelephonyProvidersEdgeSoftwareupdate(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling deleteTelephonyProvidersEdgeSoftwareupdate'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/softwareupdate', 'DELETE', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Deletes alertable presences overrides. * */ deleteTelephonyProvidersEdgesAlertablepresences() { return this.apiClient.callApi( '/api/v2/telephony/providers/edges/alertablepresences', 'DELETE', { }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a certificate authority. * * @param {String} certificateId Certificate ID */ deleteTelephonyProvidersEdgesCertificateauthority(certificateId) { // verify the required parameter 'certificateId' is set if (certificateId === undefined || certificateId === null) { throw 'Missing the required parameter "certificateId" when calling deleteTelephonyProvidersEdgesCertificateauthority'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/certificateauthorities/{certificateId}', 'DELETE', { 'certificateId': certificateId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a DID Pool by ID. * * @param {String} didPoolId DID pool ID */ deleteTelephonyProvidersEdgesDidpool(didPoolId) { // verify the required parameter 'didPoolId' is set if (didPoolId === undefined || didPoolId === null) { throw 'Missing the required parameter "didPoolId" when calling deleteTelephonyProvidersEdgesDidpool'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/didpools/{didPoolId}', 'DELETE', { 'didPoolId': didPoolId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete an edge group. * * @param {String} edgeGroupId Edge group ID */ deleteTelephonyProvidersEdgesEdgegroup(edgeGroupId) { // verify the required parameter 'edgeGroupId' is set if (edgeGroupId === undefined || edgeGroupId === null) { throw 'Missing the required parameter "edgeGroupId" when calling deleteTelephonyProvidersEdgesEdgegroup'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/edgegroups/{edgeGroupId}', 'DELETE', { 'edgeGroupId': edgeGroupId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete an extension pool by ID * * @param {String} extensionPoolId Extension pool ID */ deleteTelephonyProvidersEdgesExtensionpool(extensionPoolId) { // verify the required parameter 'extensionPoolId' is set if (extensionPoolId === undefined || extensionPoolId === null) { throw 'Missing the required parameter "extensionPoolId" when calling deleteTelephonyProvidersEdgesExtensionpool'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensionpools/{extensionPoolId}', 'DELETE', { 'extensionPoolId': extensionPoolId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a Phone by ID * * @param {String} phoneId Phone ID */ deleteTelephonyProvidersEdgesPhone(phoneId) { // verify the required parameter 'phoneId' is set if (phoneId === undefined || phoneId === null) { throw 'Missing the required parameter "phoneId" when calling deleteTelephonyProvidersEdgesPhone'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phones/{phoneId}', 'DELETE', { 'phoneId': phoneId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a Phone Base Settings by ID * * @param {String} phoneBaseId Phone base ID */ deleteTelephonyProvidersEdgesPhonebasesetting(phoneBaseId) { // verify the required parameter 'phoneBaseId' is set if (phoneBaseId === undefined || phoneBaseId === null) { throw 'Missing the required parameter "phoneBaseId" when calling deleteTelephonyProvidersEdgesPhonebasesetting'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phonebasesettings/{phoneBaseId}', 'DELETE', { 'phoneBaseId': phoneBaseId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a Site by ID * * @param {String} siteId Site ID */ deleteTelephonyProvidersEdgesSite(siteId) { // verify the required parameter 'siteId' is set if (siteId === undefined || siteId === null) { throw 'Missing the required parameter "siteId" when calling deleteTelephonyProvidersEdgesSite'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/sites/{siteId}', 'DELETE', { 'siteId': siteId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete Outbound Route * * @param {String} siteId Site ID * @param {String} outboundRouteId Outbound route ID */ deleteTelephonyProvidersEdgesSiteOutboundroute(siteId, outboundRouteId) { // verify the required parameter 'siteId' is set if (siteId === undefined || siteId === null) { throw 'Missing the required parameter "siteId" when calling deleteTelephonyProvidersEdgesSiteOutboundroute'; } // verify the required parameter 'outboundRouteId' is set if (outboundRouteId === undefined || outboundRouteId === null) { throw 'Missing the required parameter "outboundRouteId" when calling deleteTelephonyProvidersEdgesSiteOutboundroute'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/sites/{siteId}/outboundroutes/{outboundRouteId}', 'DELETE', { 'siteId': siteId,'outboundRouteId': outboundRouteId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Delete a Trunk Base Settings object by ID * * @param {String} trunkBaseSettingsId Trunk Base ID */ deleteTelephonyProvidersEdgesTrunkbasesetting(trunkBaseSettingsId) { // verify the required parameter 'trunkBaseSettingsId' is set if (trunkBaseSettingsId === undefined || trunkBaseSettingsId === null) { throw 'Missing the required parameter "trunkBaseSettingsId" when calling deleteTelephonyProvidersEdgesTrunkbasesetting'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/trunkbasesettings/{trunkBaseSettingsId}', 'DELETE', { 'trunkBaseSettingsId': trunkBaseSettingsId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get edge. * * @param {String} edgeId Edge ID * @param {Object} opts Optional parameters * @param {Array.<String>} opts.expand Fields to expand in the response, comma-separated */ getTelephonyProvidersEdge(edgeId, opts) { opts = opts || {}; // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdge'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}', 'GET', { 'edgeId': edgeId }, { 'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get networking-related information from an Edge for a target IP or host. * * @param {String} edgeId Edge Id */ getTelephonyProvidersEdgeDiagnosticNslookup(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeDiagnosticNslookup'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/diagnostic/nslookup', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get networking-related information from an Edge for a target IP or host. * * @param {String} edgeId Edge Id */ getTelephonyProvidersEdgeDiagnosticPing(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeDiagnosticPing'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/diagnostic/ping', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get networking-related information from an Edge for a target IP or host. * * @param {String} edgeId Edge Id */ getTelephonyProvidersEdgeDiagnosticRoute(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeDiagnosticRoute'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/diagnostic/route', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get networking-related information from an Edge for a target IP or host. * * @param {String} edgeId Edge Id */ getTelephonyProvidersEdgeDiagnosticTracepath(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeDiagnosticTracepath'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/diagnostic/tracepath', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get an edge logical interface * * @param {String} edgeId Edge ID * @param {String} interfaceId Interface ID * @param {Object} opts Optional parameters * @param {Array.<String>} opts.expand Field to expand in the response */ getTelephonyProvidersEdgeLogicalinterface(edgeId, interfaceId, opts) { opts = opts || {}; // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeLogicalinterface'; } // verify the required parameter 'interfaceId' is set if (interfaceId === undefined || interfaceId === null) { throw 'Missing the required parameter "interfaceId" when calling getTelephonyProvidersEdgeLogicalinterface'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/logicalinterfaces/{interfaceId}', 'GET', { 'edgeId': edgeId,'interfaceId': interfaceId }, { 'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get edge logical interfaces. * Retrieve a list of all configured logical interfaces from a specific edge. * @param {String} edgeId Edge ID * @param {Object} opts Optional parameters * @param {Array.<String>} opts.expand Field to expand in the response */ getTelephonyProvidersEdgeLogicalinterfaces(edgeId, opts) { opts = opts || {}; // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeLogicalinterfaces'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/logicalinterfaces', 'GET', { 'edgeId': edgeId }, { 'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get an Edge logs job. * * @param {String} edgeId Edge ID * @param {String} jobId Job ID */ getTelephonyProvidersEdgeLogsJob(edgeId, jobId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeLogsJob'; } // verify the required parameter 'jobId' is set if (jobId === undefined || jobId === null) { throw 'Missing the required parameter "jobId" when calling getTelephonyProvidersEdgeLogsJob'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/logs/jobs/{jobId}', 'GET', { 'edgeId': edgeId,'jobId': jobId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the edge metrics. * * @param {String} edgeId Edge Id */ getTelephonyProvidersEdgeMetrics(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeMetrics'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/metrics', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get edge physical interface. * Retrieve a physical interface from a specific edge. * @param {String} edgeId Edge ID * @param {String} interfaceId Interface ID */ getTelephonyProvidersEdgePhysicalinterface(edgeId, interfaceId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgePhysicalinterface'; } // verify the required parameter 'interfaceId' is set if (interfaceId === undefined || interfaceId === null) { throw 'Missing the required parameter "interfaceId" when calling getTelephonyProvidersEdgePhysicalinterface'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/physicalinterfaces/{interfaceId}', 'GET', { 'edgeId': edgeId,'interfaceId': interfaceId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Retrieve a list of all configured physical interfaces from a specific edge. * * @param {String} edgeId Edge ID */ getTelephonyProvidersEdgePhysicalinterfaces(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgePhysicalinterfaces'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/physicalinterfaces', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the setup package for a locally deployed edge device. This is needed to complete the setup process for the virtual edge. * * @param {String} edgeId Edge ID */ getTelephonyProvidersEdgeSetuppackage(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeSetuppackage'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/setuppackage', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Gets software update status information about any edge. * * @param {String} edgeId Edge ID */ getTelephonyProvidersEdgeSoftwareupdate(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeSoftwareupdate'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/softwareupdate', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Gets all the available software versions for this edge. * * @param {String} edgeId Edge ID */ getTelephonyProvidersEdgeSoftwareversions(edgeId) { // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeSoftwareversions'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/softwareversions', 'GET', { 'edgeId': edgeId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the list of available trunks for the given Edge. * Trunks are created by assigning trunk base settings to an Edge or Edge Group. * @param {String} edgeId Edge ID * @param {Object} opts Optional parameters * @param {Number} opts.pageNumber Page number (default to 1) * @param {Number} opts.pageSize Page size (default to 25) * @param {String} opts.sortBy Value by which to sort (default to name) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {String} opts.trunkBaseId Filter by Trunk Base Ids * @param {Object} opts.trunkType Filter by a Trunk type */ getTelephonyProvidersEdgeTrunks(edgeId, opts) { opts = opts || {}; // verify the required parameter 'edgeId' is set if (edgeId === undefined || edgeId === null) { throw 'Missing the required parameter "edgeId" when calling getTelephonyProvidersEdgeTrunks'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/{edgeId}/trunks', 'GET', { 'edgeId': edgeId }, { 'pageNumber': opts['pageNumber'],'pageSize': opts['pageSize'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'trunkBase.id': opts['trunkBaseId'],'trunkType': opts['trunkType'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the list of edges. * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.name Name * @param {String} opts.siteId Filter by site.id * @param {String} opts.edgeGroupId Filter by edgeGroup.id * @param {String} opts.sortBy Sort by (default to name) * @param {Boolean} opts.managed Filter by managed * @param {Boolean} opts.showCloudMedia True to show the cloud media devices in the result. (default to true) */ getTelephonyProvidersEdges(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'name': opts['name'],'site.id': opts['siteId'],'edgeGroup.id': opts['edgeGroupId'],'sortBy': opts['sortBy'],'managed': opts['managed'],'showCloudMedia': opts['showCloudMedia'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the list alertable presences. The 'type' query parameter can be used to If there are any overrides, this is the list of overrides; if there are no overrides, it is the default list. * * @param {Object} opts Optional parameters * @param {Object} opts.type */ getTelephonyProvidersEdgesAlertablepresences(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/alertablepresences', 'GET', { }, { 'type': opts['type'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the list of certificate authorities. * */ getTelephonyProvidersEdgesCertificateauthorities() { return this.apiClient.callApi( '/api/v2/telephony/providers/edges/certificateauthorities', 'GET', { }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a certificate authority. * * @param {String} certificateId Certificate ID */ getTelephonyProvidersEdgesCertificateauthority(certificateId) { // verify the required parameter 'certificateId' is set if (certificateId === undefined || certificateId === null) { throw 'Missing the required parameter "certificateId" when calling getTelephonyProvidersEdgesCertificateauthority'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/certificateauthorities/{certificateId}', 'GET', { 'certificateId': certificateId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a DID by ID. * * @param {String} didId DID ID */ getTelephonyProvidersEdgesDid(didId) { // verify the required parameter 'didId' is set if (didId === undefined || didId === null) { throw 'Missing the required parameter "didId" when calling getTelephonyProvidersEdgesDid'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/dids/{didId}', 'GET', { 'didId': didId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a DID Pool by ID. * * @param {String} didPoolId DID pool ID */ getTelephonyProvidersEdgesDidpool(didPoolId) { // verify the required parameter 'didPoolId' is set if (didPoolId === undefined || didPoolId === null) { throw 'Missing the required parameter "didPoolId" when calling getTelephonyProvidersEdgesDidpool'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/didpools/{didPoolId}', 'GET', { 'didPoolId': didPoolId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of DID Pools * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortBy Sort by (default to number) * @param {Array.<String>} opts.id Filter by a specific list of ID's */ getTelephonyProvidersEdgesDidpools(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/didpools', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortBy': opts['sortBy'],'id': this.apiClient.buildCollectionParam(opts['id'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of unassigned and/or assigned numbers in a set of DID Pools. * * @param {Object} type The type of numbers to return. * @param {Object} opts Optional parameters * @param {Array.<String>} opts.id Filter by a specific list of DID Pools. If this is not provided, numbers from all DID Pools will be returned. * @param {String} opts.numberMatch A number to filter the results by. * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortOrder Sort order (default to ascending) */ getTelephonyProvidersEdgesDidpoolsDids(type, opts) { opts = opts || {}; // verify the required parameter 'type' is set if (type === undefined || type === null) { throw 'Missing the required parameter "type" when calling getTelephonyProvidersEdgesDidpoolsDids'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/didpools/dids', 'GET', { }, { 'type': type,'id': this.apiClient.buildCollectionParam(opts['id'], 'multi'),'numberMatch': opts['numberMatch'],'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortOrder': opts['sortOrder'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of DIDs * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortBy Sort by (default to number) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {String} opts.phoneNumber Filter by phoneNumber * @param {String} opts.ownerId Filter by the owner of a phone number * @param {String} opts.didPoolId Filter by the DID Pool assignment * @param {Array.<String>} opts.id Filter by a specific list of ID's */ getTelephonyProvidersEdgesDids(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/dids', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'phoneNumber': opts['phoneNumber'],'owner.id': opts['ownerId'],'didPool.id': opts['didPoolId'],'id': this.apiClient.buildCollectionParam(opts['id'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get edge group. * * @param {String} edgeGroupId Edge group ID * @param {Object} opts Optional parameters * @param {Array.<String>} opts.expand Fields to expand in the response */ getTelephonyProvidersEdgesEdgegroup(edgeGroupId, opts) { opts = opts || {}; // verify the required parameter 'edgeGroupId' is set if (edgeGroupId === undefined || edgeGroupId === null) { throw 'Missing the required parameter "edgeGroupId" when calling getTelephonyProvidersEdgesEdgegroup'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/edgegroups/{edgeGroupId}', 'GET', { 'edgeGroupId': edgeGroupId }, { 'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Gets the edge trunk base associated with the edge group * * @param {String} edgegroupId Edge Group ID * @param {String} edgetrunkbaseId Edge Trunk Base ID */ getTelephonyProvidersEdgesEdgegroupEdgetrunkbase(edgegroupId, edgetrunkbaseId) { // verify the required parameter 'edgegroupId' is set if (edgegroupId === undefined || edgegroupId === null) { throw 'Missing the required parameter "edgegroupId" when calling getTelephonyProvidersEdgesEdgegroupEdgetrunkbase'; } // verify the required parameter 'edgetrunkbaseId' is set if (edgetrunkbaseId === undefined || edgetrunkbaseId === null) { throw 'Missing the required parameter "edgetrunkbaseId" when calling getTelephonyProvidersEdgesEdgegroupEdgetrunkbase'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/edgegroups/{edgegroupId}/edgetrunkbases/{edgetrunkbaseId}', 'GET', { 'edgegroupId': edgegroupId,'edgetrunkbaseId': edgetrunkbaseId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the list of edge groups. * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.name Name * @param {String} opts.sortBy Sort by (default to name) * @param {Boolean} opts.managed Filter by managed */ getTelephonyProvidersEdgesEdgegroups(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/edgegroups', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'name': opts['name'],'sortBy': opts['sortBy'],'managed': opts['managed'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the edge version report. * The report will not have consistent data about the edge version(s) until all edges have been reset. */ getTelephonyProvidersEdgesEdgeversionreport() { return this.apiClient.callApi( '/api/v2/telephony/providers/edges/edgeversionreport', 'GET', { }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * List of edges more than 4 edge versions behind the latest software. * */ getTelephonyProvidersEdgesExpired() { return this.apiClient.callApi( '/api/v2/telephony/providers/edges/expired', 'GET', { }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get an extension by ID. * * @param {String} extensionId Extension ID */ getTelephonyProvidersEdgesExtension(extensionId) { // verify the required parameter 'extensionId' is set if (extensionId === undefined || extensionId === null) { throw 'Missing the required parameter "extensionId" when calling getTelephonyProvidersEdgesExtension'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensions/{extensionId}', 'GET', { 'extensionId': extensionId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get an extension pool by ID * * @param {String} extensionPoolId Extension pool ID */ getTelephonyProvidersEdgesExtensionpool(extensionPoolId) { // verify the required parameter 'extensionPoolId' is set if (extensionPoolId === undefined || extensionPoolId === null) { throw 'Missing the required parameter "extensionPoolId" when calling getTelephonyProvidersEdgesExtensionpool'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensionpools/{extensionPoolId}', 'GET', { 'extensionPoolId': extensionPoolId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of extension pools * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortBy Sort by * @param {String} opts._number Deprecated, filtering by number not supported * @param {Array.<String>} opts.divisionId List of divisionIds on which to filter. */ getTelephonyProvidersEdgesExtensionpools(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensionpools', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortBy': opts['sortBy'],'number': opts['_number'],'divisionId': this.apiClient.buildCollectionParam(opts['divisionId'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a pageable list of basic extension pool objects filterable by query parameters. * This returns extension pools consisting of name and division. If one or more IDs are specified, the search will fetch flow outcomes that match the given ID(s) and not use any additional supplied query parameters in the search. * @param {Object} opts Optional parameters * @param {Number} opts.pageNumber Page number (default to 1) * @param {Number} opts.pageSize Page size (default to 25) * @param {String} opts.sortBy Sort by (default to name) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {Array.<String>} opts.id ID of the Extension Pools to filter by. * @param {String} opts.name Name of the Extension Pools to filter by. * @param {Array.<String>} opts.divisionId List of divisionIds on which to filter. */ getTelephonyProvidersEdgesExtensionpoolsDivisionviews(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensionpools/divisionviews', 'GET', { }, { 'pageNumber': opts['pageNumber'],'pageSize': opts['pageSize'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'id': this.apiClient.buildCollectionParam(opts['id'], 'multi'),'name': opts['name'],'divisionId': this.apiClient.buildCollectionParam(opts['divisionId'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of extensions * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortBy Sort by (default to number) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {String} opts._number Filter by number */ getTelephonyProvidersEdgesExtensions(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/extensions', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'number': opts['_number'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a Line by ID * * @param {String} lineId Line ID */ getTelephonyProvidersEdgesLine(lineId) { // verify the required parameter 'lineId' is set if (lineId === undefined || lineId === null) { throw 'Missing the required parameter "lineId" when calling getTelephonyProvidersEdgesLine'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/lines/{lineId}', 'GET', { 'lineId': lineId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a line base settings object by ID * * @param {String} lineBaseId Line base ID */ getTelephonyProvidersEdgesLinebasesetting(lineBaseId) { // verify the required parameter 'lineBaseId' is set if (lineBaseId === undefined || lineBaseId === null) { throw 'Missing the required parameter "lineBaseId" when calling getTelephonyProvidersEdgesLinebasesetting'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/linebasesettings/{lineBaseId}', 'GET', { 'lineBaseId': lineBaseId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a listing of line base settings objects * * @param {Object} opts Optional parameters * @param {Number} opts.pageNumber Page number (default to 1) * @param {Number} opts.pageSize Page size (default to 25) * @param {String} opts.sortBy Value by which to sort (default to name) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {Array.<String>} opts.expand Fields to expand in the response, comma-separated */ getTelephonyProvidersEdgesLinebasesettings(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/linebasesettings', 'GET', { }, { 'pageNumber': opts['pageNumber'],'pageSize': opts['pageSize'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a list of Lines * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.name Name * @param {String} opts.sortBy Value by which to sort (default to name) * @param {Array.<String>} opts.expand Fields to expand in the response, comma-separated. The edgeGroup value is deprecated. */ getTelephonyProvidersEdgesLines(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/lines', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'name': opts['name'],'sortBy': opts['sortBy'],'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a Line instance template based on a Line Base Settings object. This object can then be modified and saved as a new Line instance * * @param {String} lineBaseSettingsId The id of a Line Base Settings object upon which to base this Line */ getTelephonyProvidersEdgesLinesTemplate(lineBaseSettingsId) { // verify the required parameter 'lineBaseSettingsId' is set if (lineBaseSettingsId === undefined || lineBaseSettingsId === null) { throw 'Missing the required parameter "lineBaseSettingsId" when calling getTelephonyProvidersEdgesLinesTemplate'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/lines/template', 'GET', { }, { 'lineBaseSettingsId': lineBaseSettingsId }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get edge logical interfaces. * Retrieve the configured logical interfaces for a list edges. Only 100 edges can be requested at a time. * @param {String} edgeIds Comma separated list of Edge Id's * @param {Object} opts Optional parameters * @param {Array.<String>} opts.expand Field to expand in the response */ getTelephonyProvidersEdgesLogicalinterfaces(edgeIds, opts) { opts = opts || {}; // verify the required parameter 'edgeIds' is set if (edgeIds === undefined || edgeIds === null) { throw 'Missing the required parameter "edgeIds" when calling getTelephonyProvidersEdgesLogicalinterfaces'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/logicalinterfaces', 'GET', { }, { 'edgeIds': edgeIds,'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi') }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get media endpoint statistics events. * * @param {String} conversationId Identifier of the conversation * getTelephonyProvidersEdgesMediastatisticsConversation is a preview method and is subject to both breaking and non-breaking changes at any time without notice */ getTelephonyProvidersEdgesMediastatisticsConversation(conversationId) { // verify the required parameter 'conversationId' is set if (conversationId === undefined || conversationId === null) { throw 'Missing the required parameter "conversationId" when calling getTelephonyProvidersEdgesMediastatisticsConversation'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/mediastatistics/conversations/{conversationId}', 'GET', { 'conversationId': conversationId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get media endpoint statistics event. * * @param {String} conversationId Identifier of the conversation * @param {String} communicationId Identifier of the media session * getTelephonyProvidersEdgesMediastatisticsConversationCommunication is a preview method and is subject to both breaking and non-breaking changes at any time without notice */ getTelephonyProvidersEdgesMediastatisticsConversationCommunication(conversationId, communicationId) { // verify the required parameter 'conversationId' is set if (conversationId === undefined || conversationId === null) { throw 'Missing the required parameter "conversationId" when calling getTelephonyProvidersEdgesMediastatisticsConversationCommunication'; } // verify the required parameter 'communicationId' is set if (communicationId === undefined || communicationId === null) { throw 'Missing the required parameter "communicationId" when calling getTelephonyProvidersEdgesMediastatisticsConversationCommunication'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/mediastatistics/conversations/{conversationId}/communications/{communicationId}', 'GET', { 'conversationId': conversationId,'communicationId': communicationId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get the metrics for a list of edges. * * @param {String} edgeIds Comma separated list of Edge Id's. Maximum of 100 edge ids allowed. */ getTelephonyProvidersEdgesMetrics(edgeIds) { // verify the required parameter 'edgeIds' is set if (edgeIds === undefined || edgeIds === null) { throw 'Missing the required parameter "edgeIds" when calling getTelephonyProvidersEdgesMetrics'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/metrics', 'GET', { }, { 'edgeIds': edgeIds }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get outbound routes * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.name Name * @param {String} opts.siteId Filter by site.id * @param {String} opts.externalTrunkBasesIds Filter by externalTrunkBases.ids * @param {String} opts.sortBy Sort by (default to name) */ getTelephonyProvidersEdgesOutboundroutes(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/outboundroutes', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'name': opts['name'],'site.id': opts['siteId'],'externalTrunkBases.ids': opts['externalTrunkBasesIds'],'sortBy': opts['sortBy'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a Phone by ID * * @param {String} phoneId Phone ID */ getTelephonyProvidersEdgesPhone(phoneId) { // verify the required parameter 'phoneId' is set if (phoneId === undefined || phoneId === null) { throw 'Missing the required parameter "phoneId" when calling getTelephonyProvidersEdgesPhone'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phones/{phoneId}', 'GET', { 'phoneId': phoneId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a Phone Base Settings object by ID * * @param {String} phoneBaseId Phone base ID */ getTelephonyProvidersEdgesPhonebasesetting(phoneBaseId) { // verify the required parameter 'phoneBaseId' is set if (phoneBaseId === undefined || phoneBaseId === null) { throw 'Missing the required parameter "phoneBaseId" when calling getTelephonyProvidersEdgesPhonebasesetting'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phonebasesettings/{phoneBaseId}', 'GET', { 'phoneBaseId': phoneBaseId }, { }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a list of Phone Base Settings objects * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) * @param {String} opts.sortBy Value by which to sort (default to name) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {Array.<String>} opts.expand Fields to expand in the response, comma-separated * @param {String} opts.name Name */ getTelephonyProvidersEdgesPhonebasesettings(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phonebasesettings', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'],'sortBy': opts['sortBy'],'sortOrder': opts['sortOrder'],'expand': this.apiClient.buildCollectionParam(opts['expand'], 'multi'),'name': opts['name'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a list of available makes and models to create a new Phone Base Settings * * @param {Object} opts Optional parameters * @param {Number} opts.pageSize Page size (default to 25) * @param {Number} opts.pageNumber Page number (default to 1) */ getTelephonyProvidersEdgesPhonebasesettingsAvailablemetabases(opts) { opts = opts || {}; return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phonebasesettings/availablemetabases', 'GET', { }, { 'pageSize': opts['pageSize'],'pageNumber': opts['pageNumber'] }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a Phone Base Settings instance template from a given make and model. This object can then be modified and saved as a new Phone Base Settings instance * * @param {String} phoneMetabaseId The id of a metabase object upon which to base this Phone Base Settings */ getTelephonyProvidersEdgesPhonebasesettingsTemplate(phoneMetabaseId) { // verify the required parameter 'phoneMetabaseId' is set if (phoneMetabaseId === undefined || phoneMetabaseId === null) { throw 'Missing the required parameter "phoneMetabaseId" when calling getTelephonyProvidersEdgesPhonebasesettingsTemplate'; } return this.apiClient.callApi( '/api/v2/telephony/providers/edges/phonebasesettings/template', 'GET', { }, { 'phoneMetabaseId': phoneMetabaseId }, { }, { }, null, ['PureCloud OAuth'], ['application/json'], ['application/json'] ); } /** * Get a list of Phone Instances. A maximum of 10,000 results is returned when filtering the results or sorting by a field other than the ID. Sorting by only the ID has no result limit. Each filter supports a wildcard, *, as a value to search for partial values. * * @param {Object} opts Optional parameters * @param {Number} opts.pageNumber Page number (default to 1) * @param {Number} opts.pageSize Page size (default to 25) * @param {Object} opts.sortBy The field to sort by (default to name) * @param {String} opts.sortOrder Sort order (default to ASC) * @param {String} opts.siteId Filter by site.id * @param {String} opts.webRtcUserId Filter by webRtcUser.id * @param {String} opts.phoneBaseSettingsId Filter by phoneBaseSettings.id * @param {String} opts.linesLoggedInUserId Filter by lines.loggedInUser.id * @param {String} opts.linesDefaultForUserId Filter by lines.defaultForUser.id * @param {String} opts.phoneHardwareId Filter by phone_hardwareId * @param {String} opts.linesId Filter by lines.id * @param {String} opts.linesName Filter by lines.name * @param {String} opts.name Name of the Phone to fil