line_abbreviated_numbers
Creates, updates, deletes, gets or lists a line_abbreviated_numbers resource.
Overview​
| Name | line_abbreviated_numbers |
| Type | Resource |
| Id | ovh.telephony.line_abbreviated_numbers |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
name | string | |
abbreviated_number | integer | The abbreviated number which must start with "2" and must have a length of 3 or 4 digits (wire: abbreviatedNumber) |
destination_number | string (phone-number) | The destination of the abbreviated number (wire: destinationNumber) |
surname | string |
Abbreviated number
| Name | Datatype | Description |
|---|---|---|
name | string | |
abbreviated_number | integer | The abbreviated number which must start with "2" and must have a length of 3 or 4 digits (wire: abbreviatedNumber) |
destination_number | string (phone-number) | The destination of the abbreviated number (wire: destinationNumber) |
surname | string |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | abbreviated_number, billing_account, service_name | Get a speed dial number | |
list | select | billing_account, service_name | x_pagination_mode | List speed dial numbers |
create | insert | billing_account, service_name, abbreviated_number, destination_number, name, surname | Create a speed dial number | |
update | update | abbreviated_number, billing_account, service_name | Update a speed dial number | |
delete | delete | abbreviated_number, billing_account, service_name | Delete a speed dial number |
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 |
|---|---|---|
abbreviated_number | integer | The abbreviated number which must start with "2" and must have a length of 3 or 4 digits (wire: abbreviatedNumber) |
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"}}) |
billing_account | string | The name of your billingAccount (wire: billingAccount) |
service_name | string | (wire: serviceName) |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Get a speed dial number
SELECT
name,
abbreviated_number,
destination_number,
surname
FROM ovh.telephony.line_abbreviated_numbers
WHERE abbreviated_number = '{{ abbreviated_number }}' -- required
AND billing_account = '{{ billing_account }}' -- required
AND service_name = '{{ service_name }}' -- required
;
List speed dial numbers
SELECT
name,
abbreviated_number,
destination_number,
surname
FROM ovh.telephony.line_abbreviated_numbers
WHERE billing_account = '{{ billing_account }}' -- required
AND service_name = '{{ service_name }}' -- required
AND x_pagination_mode = '{{ x_pagination_mode }}'
;
INSERT examples​
- create
- Manifest
Create a speed dial number
INSERT INTO ovh.telephony.line_abbreviated_numbers (
abbreviated_number,
destination_number,
name,
surname,
billing_account,
service_name
)
SELECT
{{ abbreviated_number }} /* required */,
'{{ destination_number }}' /* required */,
'{{ name }}' /* required */,
'{{ surname }}' /* required */,
'{{ billing_account }}',
'{{ service_name }}'
RETURNING
name,
abbreviated_number,
destination_number,
surname
;
# Description fields are for documentation purposes
- name: line_abbreviated_numbers
props:
- name: billing_account
value: "{{ billing_account }}"
description: Required parameter for the line_abbreviated_numbers resource.
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the line_abbreviated_numbers resource.
- name: abbreviated_number
value: {{ abbreviated_number }}
description: |
The abbreviated number which must start with "2" and must have a length of 3 or 4 digits
- name: destination_number
value: "{{ destination_number }}"
description: |
Phone number
- name: name
value: "{{ name }}"
- name: surname
value: "{{ surname }}"
UPDATE examples​
- update
Update a speed dial number
UPDATE ovh.telephony.line_abbreviated_numbers
SET
destination_number = '{{ destination_number }}',
name = '{{ name }}',
surname = '{{ surname }}'
WHERE
abbreviated_number = '{{ abbreviated_number }}' --required
AND billing_account = '{{ billing_account }}' --required
AND service_name = '{{ service_name }}' --required;
DELETE examples​
- delete
Delete a speed dial number
DELETE FROM ovh.telephony.line_abbreviated_numbers
WHERE abbreviated_number = '{{ abbreviated_number }}' --required
AND billing_account = '{{ billing_account }}' --required
AND service_name = '{{ service_name }}' --required
;