{"openapi":"3.0.0","info":{"title":"OVHcloud API specification","description":"Specification for OVHcloud API","version":"1.0","contact":{"name":"OVH","email":"api@ml.ovh.net"}},"servers":[{"url":"https://api.eu.ovhcloud.com/1.0"}],"components":{"schemas":{"any":{"description":"Can be anything (text, int, bool, json, html, etc.)","example":"This is a content of any type !"},"complexType.UnitAndValue_double":{"type":"object","description":"A numeric value tagged with its unit","properties":{"unit":{"type":"string"},"value":{"type":"number"}}},"dedicated.server.MrtgPeriodEnum":{"type":"string","description":"distincts MRTG period","enum":["daily","hourly","monthly","weekly","yearly"]},"dedicated.server.MrtgTimestampValue":{"type":"object","description":"A timestamp associated to a value","properties":{"timestamp":{"type":"integer"},"value":{"allOf":[{"$ref":"#/components/schemas/complexType.UnitAndValue_double"}],"nullable":true}}},"dedicated.server.MrtgTypeEnum":{"type":"string","description":"distincts MRTG type","enum":["errors:download","errors:upload","packets:download","packets:upload","traffic:download","traffic:upload"]},"duration":{"type":"string","description":"Duration (e.g., P1Y2M3DT4H6M9S)","example":"P1Y2M3DT4H6M9S"},"email":{"type":"string","description":"Email address (e.g., api@ml.ovh.net)","format":"email","example":"api@ml.ovh.net"},"internationalPhoneNumber":{"type":"string","description":"International phone number","format":"phone-number"},"ip":{"type":"string","description":"IP address (e.g., 192.0.2.0)","format":"ipv4","example":"192.0.2.0"},"ipBlock":{"type":"string","description":"IP (v4 or v6) CIDR notation (e.g., 192.0.2.0/24)","format":"ip-block","example":"192.0.2.0/24"},"ipInterface":{"type":"string","description":"IP address (e.g., 192.0.2.0)","format":"ipv4","example":"192.0.2.0"},"ipv4":{"type":"string","description":"IPv4 address (e.g., 192.0.2.0)","format":"ipv4","example":"192.0.2.0"},"ipv4Block":{"type":"string","description":"IPv4 CIDR notation (e.g., 192.0.2.0/24)","format":"ipv4-block","example":"192.0.2.0/24"},"ipv6":{"type":"string","description":"IPv6 address (e.g., 2001:41d0:1:1994::1)","format":"ipv6","example":"2001:41d0:1:1994::1"},"ipv6Block":{"type":"string","description":"IPv6 CIDR notation (e.g., 2001:41d0::/128)","format":"ipv6-block","example":"2001:41d0::/128"},"macAddress":{"type":"string","description":"MAC address (e.g., 00:00:5e:00:53:01)","format":"mac-address","example":"00:00:5e:00:53:01"},"phoneNumber":{"type":"string","description":"Phone number","format":"phone-number"},"time":{"type":"string","description":"Time (e.g., 15:04:05)","format":"time","example":"15:04:05"},"vrack.AllowedDedicatedServerInterfaces":{"type":"object","description":"A structure giving all dedicated server interfaces allowed for this vrack","properties":{"dedicatedServer":{"type":"string","description":"the name of dedicatedServer"},"dedicatedServerInterface":{"type":"string","description":"the unique identifier of dedicatedServerInterface"},"name":{"type":"string","description":"the name of dedicatedServerInterface"}}},"vrack.Task":{"type":"object","description":"vrack tasks","properties":{"function":{"type":"string","readOnly":true},"id":{"type":"integer","readOnly":true},"lastUpdate":{"type":"string","nullable":true,"format":"date-time","readOnly":true},"orderId":{"type":"integer","nullable":true,"readOnly":true},"serviceName":{"type":"string","nullable":true,"readOnly":true},"status":{"allOf":[{"$ref":"#/components/schemas/vrack.TaskStatusEnum"}],"description":"Task status","readOnly":true},"targetDomain":{"type":"string","nullable":true,"readOnly":true},"todoDate":{"type":"string","nullable":true,"format":"date-time","readOnly":true}}},"vrack.TaskStatusEnum":{"type":"string","description":"All states a vRack Task can be in","enum":["cancelled","doing","done","init","todo"]},"vrack.dedicatedServer":{"type":"object","description":"vrack dedicated server interfaces (LEGACY)","properties":{"dedicatedServer":{"type":"string","description":"Dedicated Server","readOnly":true},"vrack":{"type":"string","description":"vrack name","readOnly":true}}},"vrack.dedicatedServerInterface":{"type":"object","description":"vrack dedicated server interfaces","properties":{"dedicatedServerInterface":{"type":"string","description":"Dedicated Server Interface","readOnly":true},"vrack":{"type":"string","description":"vrack name","readOnly":true}}}},"securitySchemes":{"oAuth2AuthCode":{"type":"oauth2","description":"Oauth2","x-client-id":"1bb9c7df371741c0","x-client-secret":"a5b4de870aca620d10fbf63cd18d205b","flows":{"authorizationCode":{"authorizationUrl":"https://auth.eu.ovhcloud.com/oauth2/authorize","tokenUrl":"https://auth.eu.ovhcloud.com/oauth2/token","scopes":{"account/all":"Manage your account","all":"Manage your whole account and all your services","services/all":"Manage your services lifecycle and billing"}}}}}},"paths":{"/vrack/{serviceName}/dedicatedServer":{"get":{"summary":"List servers (legacy)","description":"List servers (legacy). Returns the dedicated servers attached as a whole to the vRack, in the legacy mode. Attaching by interface replaces it.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@60"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServer\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServer\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServer/get","required":true}],"x-expanded-response":"VrackDedicatedServer"},"post":{"summary":"Attach a server (legacy)","description":"Attach a server (legacy). Attaches a whole dedicated server to the vRack, in the legacy mode. Prefer attaching one of its interfaces. Returns the task that performs it.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"dedicatedServer":{"type":"string","description":"Dedicated server to add "}},"required":["dedicatedServer"]}}}},"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.Task"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@80"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\n# Request body type: string\nresult = client.post(\"/vrack/{serviceName}/dedicatedServer\",\n\tdedicatedServer = None, # Dedicated server to add  (type: string)\n)\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n// Request body type: string\n$result = $ovh->post(\"/vrack/{serviceName}/dedicatedServer\", array(\n\tdedicatedServer => null, // Dedicated server to add  (type: string)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServer/attach","required":true},{"name":"dedicatedServer:apiovh:vrack/attach","required":true}]}},"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}":{"delete":{"summary":"Detach a server (legacy)","description":"Detach a server (legacy). Detaches a whole dedicated server from the vRack, in the legacy mode. Returns the task that performs it.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"dedicatedServer","description":"Dedicated Server","required":true,"schema":{"type":"string"}},{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.Task"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@90"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.delete(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->delete(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServer/detach","required":true}]},"get":{"summary":"Get a server link (legacy)","description":"Get a server link (legacy). Returns the attached server and its vRack. This is the legacy whole-server link, not an interface link.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"dedicatedServer","description":"Dedicated Server","required":true,"schema":{"type":"string"}},{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.dedicatedServer"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@70"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServer/get","required":true}]}},"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}/mrtg":{"get":{"summary":"Get traffic graph values (deprecated)","description":"Get traffic graph values (deprecated). Returns the traffic, packets or errors measured on the vRack port of the server, for a period from hourly to yearly. Deprecated: use the dedicated server statistics instead.","deprecated":true,"x-deprecation-date":"2017-10-23T00:00:00+01:00","x-deletion-date":"2018-04-23T00:00:00+01:00","x-replacement-route":"/dedicated/server/{serviceName}/networkInterfaceController","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"dedicatedServer","description":"Dedicated Server","required":true,"schema":{"type":"string"}},{"in":"query","name":"period","description":"mrtg period","required":true,"schema":{"$ref":"#/components/schemas/dedicated.server.MrtgPeriodEnum"}},{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}},{"in":"query","name":"type","description":"mrtg type","required":true,"schema":{"$ref":"#/components/schemas/dedicated.server.MrtgTypeEnum"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/dedicated.server.MrtgTimestampValue"}}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@100"]],"x-badges":[{"color":"red","label":"Deprecated, will be removed"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}/mrtg\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServer/{dedicatedServer}/mrtg\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServer/mrtg/get","required":true}]}},"/vrack/{serviceName}/dedicatedServerInterface":{"get":{"summary":"List server interfaces. Returns the dedicated server network interfaces attached to the vRack.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"type":"string"}}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@10"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServerInterface\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServerInterface\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServerInterface/get","required":true}],"x-expanded-response":"VrackDedicatedServerInterface"},"post":{"summary":"Attach a server interface","description":"Attach a server interface. Attaches a dedicated server network interface to the vRack. Returns the task that performs it.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"dedicatedServerInterface":{"type":"string","description":"Dedicated server interface to add "}},"required":["dedicatedServerInterface"]}}}},"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.Task"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@30"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\n# Request body type: string\nresult = client.post(\"/vrack/{serviceName}/dedicatedServerInterface\",\n\tdedicatedServerInterface = None, # Dedicated server interface to add  (type: string)\n)\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n// Request body type: string\n$result = $ovh->post(\"/vrack/{serviceName}/dedicatedServerInterface\", array(\n\tdedicatedServerInterface => null, // Dedicated server interface to add  (type: string)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServerInterface/attach","required":true},{"name":"dedicatedServer:apiovh:vrack/attach","description":"Check the action on the Dedicated Server that bares the Dedicated Server Interface","required":true}]}},"/vrack/{serviceName}/dedicatedServerInterface/{dedicatedServerInterface}":{"delete":{"summary":"Detach a server interface. Detaches the interface from the vRack. Returns the task that performs it.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"dedicatedServerInterface","description":"Dedicated Server Interface","required":true,"schema":{"type":"string"}},{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.Task"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@40"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.delete(\"/vrack/{serviceName}/dedicatedServerInterface/{dedicatedServerInterface}\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->delete(\"/vrack/{serviceName}/dedicatedServerInterface/{dedicatedServerInterface}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServerInterface/detach","required":true}]},"get":{"summary":"Get a server interface. Returns the attached interface and its vRack.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"dedicatedServerInterface","description":"Dedicated Server Interface","required":true,"schema":{"type":"string"}},{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/vrack.dedicatedServerInterface"}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@20"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServerInterface/{dedicatedServerInterface}\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServerInterface/{dedicatedServerInterface}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServerInterface/get","required":true}]}},"/vrack/{serviceName}/dedicatedServerInterfaceDetails":{"get":{"summary":"List server interface details. Returns the attached interfaces with the server each one belongs to.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The internal name of your vrack","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/vrack.AllowedDedicatedServerInterfaces"}}}}}},"x-developer-hub-navigation":[["Network","vRack","Attached services","Dedicated servers@@@50"]],"x-badges":[{"color":"green","label":"Stable production version"}],"x-code-samples":[{"lang":"python","label":"Python","source":"'''\nFirst, install the latest release of Python wrapper: $ pip install ovh\n'''\nimport json\nimport ovh\n\n# Instantiate an OVH Client.\n# You can generate new credentials with full access to your account on\n# the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\nclient = ovh.Client(\n\tendpoint='ovh-eu',               # Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n\tapplication_key='xxxxxxxxxx',    # Application Key\n\tapplication_secret='xxxxxxxxxx', # Application Secret\n\tconsumer_key='xxxxxxxxxx',       # Consumer Key\n)\n\nresult = client.get(\"/vrack/{serviceName}/dedicatedServerInterfaceDetails\")\n\n# Pretty print\nprint(json.dumps(result, indent=4))"},{"lang":"php","label":"PHP","source":"<?php\n/**\n * First, download the latest release of PHP wrapper on github\n * And include this script into the folder with extracted files\n */\nrequire __DIR__ . '/vendor/autoload.php';\nuse \\Ovh\\Api;\n\n/**\n * Instantiate an OVH Client.\n * You can generate new credentials with full access to your account on\n * the token creation page (https://api.ovh.com/createToken/index.cgi?GET=/*&PUT=/*&POST=/*&DELETE=/*)\n */\n$ovh = new Api('xxxxxxxxxx',  // Application Key\n               'xxxxxxxxxx',  // Application Secret\n               'ovh-eu',      // Endpoint of API OVH (List of available endpoints: https://github.com/ovh/python-ovh#2-configure-your-application)\n               'xxxxxxxxxx'); // Consumer Key\n\n$result = $ovh->get(\"/vrack/{serviceName}/dedicatedServerInterfaceDetails\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"vrack:apiovh:dedicatedServerInterfaceDetails/get","required":true}]}}}}
