Skip to main content

email_options

Creates, updates, deletes, gets or lists an email_options resource.

Overview​

Nameemail_options
TypeResource
Idovh.hosting_web.email_options

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
idintegerAccount id
creation_datestring (date-time)Creation date (wire: creationDate)
domainstringEmail service domain

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectid, service_nameGet an email option. Returns the domain and creation date of the email option. Its billing information is returned by serviceInfos.
listselectservice_namex_pagination_modeList email options. Returns the IDs of the email options of the hosting. Each option is a mail service linked to the hosting.
terminateexecid, serviceNameTerminate an email option. Requests the termination of the email option. A link to confirm it is sent by email to the administrator contact.

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.

NameDatatypeDescription
api_hoststringThe 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"}})
idintegerId of the object
serviceNamestringThe internal name of your hosting
service_namestringThe internal name of your hosting (wire: serviceName)
x_pagination_modestringSent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode)

SELECT examples​

Get an email option. Returns the domain and creation date of the email option. Its billing information is returned by serviceInfos.

SELECT
id,
creation_date,
domain
FROM ovh.hosting_web.email_options
WHERE id = '{{ id }}' -- required
AND service_name = '{{ service_name }}' -- required
;

Lifecycle Methods​

EXEC variables use wire (API) names.

Terminate an email option. Requests the termination of the email option. A link to confirm it is sent by email to the administrator contact.

EXEC ovh.hosting_web.email_options.terminate
@id='{{ id }}' --required,
@serviceName='{{ serviceName }}' --required
;