over_the_box_migrates
Creates, updates, deletes, gets or lists an over_the_box_migrates resource.
Overview​
| Name | over_the_box_migrates |
| Type | Resource |
| Id | ovh.order.over_the_box_migrates |
Fields​
The following fields are returned by SELECT queries:
- get
successful operation
| Name | Datatype | Description |
|---|---|---|
order_id | integer | Identifier of the order (wire: orderId) |
contracts | array | List of contracts related to the order |
details | array | Details of the order |
prices | object | Prices of the order including with and without taxes |
url | string | URL to download the order |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | hardware, offer, service_name | shipping_contact_id, shipping_method, shipping_relay_id | Get prices and contracts information |
create | insert | service_name, hardware, offer | Create 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.
| 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"}}) |
hardware | boolean | If you want to migrate with a new hardware |
offer | string | Offer name to migrate to |
service_name | string | The internal name of your overTheBox offer (wire: serviceName) |
shipping_contact_id | string | Contact ID to deliver to (wire: shippingContactID) |
shipping_method | string | How do you want your shipment shipped (wire: shippingMethod) |
shipping_relay_id | integer | Relay ID to deliver to. Needed if shipping is mondialRelay (wire: shippingRelayID) |
SELECT examples​
- get
Get prices and contracts information
SELECT
order_id,
contracts,
details,
prices,
url
FROM ovh.order.over_the_box_migrates
WHERE hardware = '{{ hardware }}' -- required
AND offer = '{{ offer }}' -- required
AND service_name = '{{ service_name }}' -- required
AND shipping_contact_id = '{{ shipping_contact_id }}'
AND shipping_method = '{{ shipping_method }}'
AND shipping_relay_id = '{{ shipping_relay_id }}'
;
INSERT examples​
- create
- Manifest
Create order
INSERT INTO ovh.order.over_the_box_migrates (
hardware,
offer,
shipping_contact_id,
shipping_method,
shipping_relay_id,
service_name
)
SELECT
{{ hardware }} /* required */,
'{{ offer }}' /* required */,
'{{ shipping_contact_id }}',
'{{ shipping_method }}',
{{ shipping_relay_id }},
'{{ service_name }}'
RETURNING
order_id,
contracts,
details,
prices,
url
;
# Description fields are for documentation purposes
- name: over_the_box_migrates
props:
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the over_the_box_migrates resource.
- name: hardware
value: {{ hardware }}
description: |
If you want to migrate with a new hardware
- name: offer
value: "{{ offer }}"
description: |
Offer name to migrate to
- name: shipping_contact_id
value: "{{ shipping_contact_id }}"
description: |
Contact ID to deliver to
- name: shipping_method
value: "{{ shipping_method }}"
description: |
How do you want your shipment shipped
valid_values: ['dhl', 'mondialRelay']
- name: shipping_relay_id
value: {{ shipping_relay_id }}
description: |
Relay ID to deliver to. Needed if shipping is mondialRelay