Skip to main content

saas_csp2_news

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

Overview​

Namesaas_csp2_news
TypeResource
Idovh.order.saas_csp2_news

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
order_idintegerIdentifier of the order (wire: orderId)
contractsarrayList of contracts related to the order
detailsarrayDetails of the order
pricesobjectPrices of the order including with and without taxes
urlstringURL to download the order

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectdurationgift_code, office_business_quantity, office_pro_plus_quantityGet prices and contracts information
listselectgift_code, office_business_quantity, office_pro_plus_quantity, x_pagination_modeGet allowed durations for 'new' option
createinsertdurationCreate order

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"}})
durationstringDuration
gift_codestringGift code for office license (wire: giftCode)
office_business_quantityintegerNumber of prepaid office business license (wire: officeBusinessQuantity)
office_pro_plus_quantityintegerNumber of prepaid office pro plus license (wire: officeProPlusQuantity)
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 prices and contracts information

SELECT
order_id,
contracts,
details,
prices,
url
FROM ovh.order.saas_csp2_news
WHERE duration = '{{ duration }}' -- required
AND gift_code = '{{ gift_code }}'
AND office_business_quantity = '{{ office_business_quantity }}'
AND office_pro_plus_quantity = '{{ office_pro_plus_quantity }}'
;

INSERT examples​

Create order

INSERT INTO ovh.order.saas_csp2_news (
gift_code,
office_business_quantity,
office_pro_plus_quantity,
duration
)
SELECT
'{{ gift_code }}',
{{ office_business_quantity }},
{{ office_pro_plus_quantity }},
'{{ duration }}'
RETURNING
order_id,
contracts,
details,
prices,
url
;