line_phones
Creates, updates, deletes, gets or lists a line_phones resource.
Overview​
| Name | line_phones |
| Type | Resource |
| Id | ovh.telephony.line_phones |
Fields​
The following fields are returned by SELECT queries:
- get
successful operation
| Name | Datatype | Description |
|---|---|---|
brand | string | Brand name |
description | string | The phone description |
mac_address | string | Mac Address (wire: macAddress) |
max_simultaneous_calls | integer | Maximum simultaneous calls managed by the phone (wire: maxSimultaneousCalls) |
maxline | integer | Maximum number of lines managed by a phone |
mgcp_ip_restriction | string (ipv4) | The ip restriction of your MGCP phone (example: 192.0.2.0) (wire: mgcpIpRestriction) |
phone_configuration | array | Current phone properties (wire: phoneConfiguration) |
protocol | string | Phone protocol (mgcp, sip) |
user_password | string (password) | The phone user password (wire: userPassword) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | billing_account, service_name | Get the phone | |
update | update | billing_account, service_name | Update the phone | |
change_phone_configuration | exec | billingAccount, serviceName | Change the phone configuration | |
reboot | exec | billingAccount, serviceName | Reboot the phone | |
refresh_screen | exec | billingAccount, serviceName | Refresh the phone screen | |
reset_config | exec | billingAccount, serviceName, ip | Reset the phone configuration |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
billingAccount | string | The name of your billingAccount |
billing_account | string | The name of your billingAccount (wire: billingAccount) |
serviceName | string | |
service_name | string | (wire: serviceName) |
SELECT examples​
- get
Get the phone
SELECT
brand,
description,
mac_address,
max_simultaneous_calls,
maxline,
mgcp_ip_restriction,
phone_configuration,
protocol,
user_password
FROM ovh.telephony.line_phones
WHERE billing_account = '{{ billing_account }}' -- required
AND service_name = '{{ service_name }}' -- required
;
UPDATE examples​
- update
Update the phone
UPDATE ovh.telephony.line_phones
SET
mgcp_ip_restriction = '{{ mgcp_ip_restriction }}'
WHERE
billing_account = '{{ billing_account }}' --required
AND service_name = '{{ service_name }}' --required;
Lifecycle Methods​
EXEC variables use wire (API) names.
- change_phone_configuration
- reboot
- refresh_screen
- reset_config
Change the phone configuration
EXEC ovh.telephony.line_phones.change_phone_configuration
@billingAccount='{{ billingAccount }}' --required,
@serviceName='{{ serviceName }}' --required
@@json=
'{
"autoReboot": {{ autoReboot }},
"newConfigurations": "{{ newConfigurations }}"
}'
;
Reboot the phone
EXEC ovh.telephony.line_phones.reboot
@billingAccount='{{ billingAccount }}' --required,
@serviceName='{{ serviceName }}' --required
;
Refresh the phone screen
EXEC ovh.telephony.line_phones.refresh_screen
@billingAccount='{{ billingAccount }}' --required,
@serviceName='{{ serviceName }}' --required
;
Reset the phone configuration
EXEC ovh.telephony.line_phones.reset_config
@billingAccount='{{ billingAccount }}' --required,
@serviceName='{{ serviceName }}' --required
@@json=
'{
"ip": "{{ ip }}"
}'
;