Skip to main content

splas

Creates, updates, deletes, gets or lists a splas resource.

Overview​

Namesplas
TypeResource
Idovh.dedicated_server.splas

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
idintegerLicense id
last_updatestring (date-time)Last update timestamp (wire: lastUpdate)
serial_numberstringLicense serial number (wire: serialNumber)
statusstringStatus of license (terminated, used, waitingToCheck)
typestringLicense type (os, sqlstd, sqlweb)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectid, service_nameGet an SPLA license. Returns an SPLA license attached to the server: its serial number, type, status and last update date. The status is waitingToCheck, used or terminated.
listselectservice_namestatus, type, x_pagination_modeList SPLA licenses. Returns the IDs of your own SPLA licenses attached to the server. The list can be filtered by status and by license type.
createinsertservice_name, serial_number, typeAdd an SPLA license. Attaches an SPLA license to the server from its serial number and its type: os, sqlstd or sqlweb. Returns the ID of the new license.
updateupdateid, service_nameUpdate an SPLA license. Updates the serial number of an SPLA license. The serial number is the only writable field of the license.
revokeexecid, serviceNameRevoke an SPLA license. Revokes an SPLA license attached to the server, identified by its license ID. The call returns no content.

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"}})
idintegerLicense id
serviceNamestringThe internal name of your dedicated server
service_namestringThe internal name of your dedicated server (wire: serviceName)
statusstringFilter the value of status property (=)
typestringFilter the value of type property (=)
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 SPLA license. Returns an SPLA license attached to the server: its serial number, type, status and last update date. The status is waitingToCheck, used or terminated.

SELECT
id,
last_update,
serial_number,
status,
type
FROM ovh.dedicated_server.splas
WHERE id = '{{ id }}' -- required
AND service_name = '{{ service_name }}' -- required
;

INSERT examples​

Add an SPLA license. Attaches an SPLA license to the server from its serial number and its type: os, sqlstd or sqlweb. Returns the ID of the new license.

INSERT INTO ovh.dedicated_server.splas (
serial_number,
type,
service_name
)
SELECT
'{{ serial_number }}' /* required */,
'{{ type }}' /* required */,
'{{ service_name }}'
;

UPDATE examples​

Update an SPLA license. Updates the serial number of an SPLA license. The serial number is the only writable field of the license.

UPDATE ovh.dedicated_server.splas
SET
serial_number = '{{ serial_number }}'
WHERE
id = '{{ id }}' --required
AND service_name = '{{ service_name }}' --required;

Lifecycle Methods​

EXEC variables use wire (API) names.

Revoke an SPLA license. Revokes an SPLA license attached to the server, identified by its license ID. The call returns no content.

EXEC ovh.dedicated_server.splas.revoke
@id='{{ id }}' --required,
@serviceName='{{ serviceName }}' --required
;