{"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/v2"}],"components":{"schemas":{"any":{"description":"Can be anything (text, int, bool, json, html, etc.)","example":"This is a content of any type !"},"common.CountryEnum":{"type":"string","description":"Country, as an ISO 3166-1 alpha-2 code","enum":["AC","AD","AE","AF","AG","AI","AL","AM","AO","AQ","AR","AS","AT","AU","AW","AX","AZ","BA","BB","BD","BE","BF","BG","BH","BI","BJ","BL","BM","BN","BO","BQ","BR","BS","BT","BW","BY","BZ","CA","CC","CD","CF","CG","CH","CI","CK","CL","CM","CN","CO","CR","CU","CV","CW","CX","CY","CZ","DE","DG","DJ","DK","DM","DO","DZ","EA","EC","EE","EG","EH","ER","ES","ET","FI","FJ","FK","FM","FO","FR","GA","GB","GD","GE","GF","GG","GH","GI","GL","GM","GN","GP","GQ","GR","GS","GT","GU","GW","GY","HK","HN","HR","HT","HU","IC","ID","IE","IL","IM","IN","IO","IQ","IR","IS","IT","JE","JM","JO","JP","KE","KG","KH","KI","KM","KN","KP","KR","KW","KY","KZ","LA","LB","LC","LI","LK","LR","LS","LT","LU","LV","LY","MA","MC","MD","ME","MF","MG","MH","MK","ML","MM","MN","MO","MP","MQ","MR","MS","MT","MU","MV","MW","MX","MY","MZ","NA","NC","NE","NF","NG","NI","NL","NO","NP","NR","NU","NZ","OM","PA","PE","PF","PG","PH","PK","PL","PM","PN","PR","PS","PT","PW","PY","QA","RE","RO","RS","RU","RW","SA","SB","SC","SD","SE","SG","SH","SI","SJ","SK","SL","SM","SN","SO","SR","SS","ST","SV","SX","SY","SZ","TA","TC","TD","TF","TG","TH","TJ","TK","TL","TM","TN","TO","TR","TT","TV","TW","TZ","UA","UG","UM","UNKNOWN","US","UY","UZ","VA","VC","VE","VG","VI","VN","VU","WF","WS","XK","YE","YT","ZA","ZM","ZW"]},"common.ResourceStatusEnum":{"type":"string","description":"Current status of a resource","enum":["CREATING","CREATION_PLANNED","DELETING","ERROR","OUT_OF_SYNC","READY","SUSPENDED","UNKNOWN","UPDATING"]},"dns.gslb.ContinentCodeEnum":{"type":"string","description":"GEOLOCATION continent codes","enum":["AF","AN","AS","EU","NA","OC","SA"]},"dns.gslb.Coordinates":{"type":"object","description":"Endpoint coordinates for GEOPROXIMITY routing","properties":{"latitude":{"type":"number","description":"Latitude from -90 to 90 degrees"},"longitude":{"type":"number","description":"Longitude from -180 to 180 degrees"}},"required":["latitude","longitude"]},"dns.gslb.CreateRecordSetRequest":{"type":"object","description":"Create a GSLB record set. Provide values, a chainTarget, or both, in which case values are the fallback when the chain target is unhealthy.","properties":{"chainTarget":{"type":"string","description":"Target record name for chaining, up to three hops. Unavailable for GEOPROXIMITY parents.","nullable":true},"coordinates":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.Coordinates"}],"description":"Endpoint coordinates, required for GEOPROXIMITY routing","nullable":true},"evaluateTargetHealth":{"type":"boolean","description":"Whether to fall through to the global scope when the chain target is unhealthy. Only supported for GEOLOCATION chains.","nullable":true},"failover":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.FailoverTypeEnum"}],"description":"Failover role of this entry, required for FAILOVER routing. PRIMARY requires a health check. Immutable after creation.","nullable":true},"geoLocation":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.GeoLocation"}],"description":"Geographic scope of this entry, required for GEOLOCATION routing. An empty object is the global fallback.","nullable":true},"healthCheckId":{"type":"string","description":"Associated health check. Unsupported for SIMPLE.","nullable":true,"format":"uuid"},"name":{"type":"string","description":"Fully qualified domain name in the hosted zone, ending with a dot. Immutable after creation."},"routingPolicy":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.RoutingPolicyEnum"}],"description":"Traffic routing policy, defaults to SIMPLE. Immutable after creation.","nullable":true},"setIdentifier":{"type":"string","description":"Identifier that distinguishes entries with the same name and type. Required for non-SIMPLE routing. At most 128 characters.","nullable":true},"ttl":{"type":"integer","description":"Time to live in seconds. Record sets with the same name and type share one TTL. The value must equal the TTL of any existing one. From 0 to 2147483647."},"type":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.RecordTypeEnum"}],"description":"DNS record type. FAILOVER, GEOLOCATION, MULTIVALUE and GEOPROXIMITY require A or AAAA. Immutable after creation."},"values":{"type":"array","description":"Record values. Required unless `chainTarget` is set. A `CNAME` accepts a single value. `MULTIVALUE` and `GEOPROXIMITY` accept one value per entry.","nullable":true,"items":{"type":"string"}},"weight":{"type":"integer","description":"Relative weight of this entry for WEIGHTED routing. Required for WEIGHTED routing. From 0 to 255.","nullable":true}},"required":["name","ttl","type"]},"dns.gslb.FailoverTypeEnum":{"type":"string","description":"Role of an endpoint in FAILOVER routing","enum":["PRIMARY","SECONDARY"]},"dns.gslb.GeoLocation":{"type":"object","description":"Scope of a `GEOLOCATION` entry. Continent and country are mutually exclusive. A subdivision requires a country. An empty object is the global fallback.","properties":{"continentCode":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.ContinentCodeEnum"}],"description":"Continent code","nullable":true},"countryCode":{"allOf":[{"$ref":"#/components/schemas/common.CountryEnum"}],"description":"ISO 3166-1 alpha-2 country code","nullable":true},"subdivisionCode":{"type":"string","description":"ISO 3166-2 subdivision code without its country prefix, for example CA for US-CA. Requires `countryCode`. When omitted, the scope is not a subdivision.","nullable":true}}},"dns.gslb.RecordSet":{"type":"object","description":"GSLB record set with routing configuration","properties":{"chainTarget":{"type":"string","description":"Target record name for chained routing. Null when the record set is not chained.","nullable":true,"readOnly":true},"coordinates":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.Coordinates"}],"description":"Endpoint coordinates for GEOPROXIMITY","nullable":true,"readOnly":true},"createdAt":{"type":"string","description":"Creation timestamp","format":"date-time","readOnly":true},"evaluateTargetHealth":{"type":"boolean","description":"Whether to fall through to the global scope when a GEOLOCATION chain target is unhealthy, always false for other record sets","readOnly":true},"failover":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.FailoverTypeEnum"}],"description":"Failover role of this entry, null for routing policies other than FAILOVER","nullable":true,"readOnly":true},"geoLocation":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.GeoLocation"}],"description":"Geographic routing scope, required for GEOLOCATION routing. Null when not set.","nullable":true,"readOnly":true},"healthCheckId":{"type":"string","description":"Identifier of the associated health check. Null when no health check is linked.","nullable":true,"format":"uuid","readOnly":true},"id":{"type":"string","description":"Unique identifier of the record set","format":"uuid","readOnly":true},"name":{"type":"string","description":"Fully qualified domain name with a trailing dot","readOnly":true},"resourceStatus":{"allOf":[{"$ref":"#/components/schemas/common.ResourceStatusEnum"}],"description":"Resource lifecycle status","readOnly":true},"routingPolicy":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.RoutingPolicyEnum"}],"description":"Traffic routing policy","readOnly":true},"setIdentifier":{"type":"string","description":"Identifier distinguishing entries with the same name and type, can be null only for SIMPLE routing","nullable":true,"readOnly":true},"ttl":{"type":"integer","description":"Time to live in seconds. Record sets with the same name and type share one TTL. Updating the TTL updates all of them.","readOnly":true},"type":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.RecordTypeEnum"}],"description":"DNS record type","readOnly":true},"updatedAt":{"type":"string","description":"Last modification timestamp","format":"date-time","readOnly":true},"values":{"type":"array","description":"DNS record values. Empty when chainTarget is set.","items":{"type":"string"},"readOnly":true},"weight":{"type":"integer","description":"Weight from 0 to 255, required for WEIGHTED routing. Null when not set.","nullable":true,"readOnly":true},"zoneId":{"type":"string","description":"Identifier of the parent hosted zone","format":"uuid","readOnly":true}}},"dns.gslb.RecordTypeEnum":{"type":"string","description":"DNS record types a GSLB record set can have. The `NS` and `SOA` records of the hosted zone apex are managed through the hosted zone `nameServers` and `soa`.","enum":["A","AAAA","CNAME","MX","TXT"]},"dns.gslb.RoutingPolicyEnum":{"type":"string","description":"GSLB traffic routing policies","enum":["FAILOVER","GEOLOCATION","GEOPROXIMITY","MULTIVALUE","SIMPLE","WEIGHTED"]},"dns.gslb.UpdateRecordSetRequest":{"type":"object","description":"Partial update of a GSLB record set. Omitted fields keep their current value. A null value removes a field, except `ttl` and `values`, which cannot be null. The result is validated against the routing policy as on creation. The name, type, routing policy and failover role cannot be changed.","properties":{"chainTarget":{"type":"string","description":"New target record name for chained routing. When null or empty, the chain target is removed.","nullable":true},"coordinates":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.Coordinates"}],"description":"New endpoint coordinates for `GEOPROXIMITY` routing. When null, the coordinates are removed.","nullable":true},"evaluateTargetHealth":{"type":"boolean","description":"Whether to fall through to the global scope when a `GEOLOCATION` chain target is unhealthy. When null, the value is reset to false.","nullable":true},"geoLocation":{"allOf":[{"$ref":"#/components/schemas/dns.gslb.GeoLocation"}],"description":"New geographic scope for `GEOLOCATION` routing. When null, the scope is removed.","nullable":true},"healthCheckId":{"type":"string","description":"Health check to link. Omit it to keep the current link, or set it to null to unlink the current health check.","nullable":true,"format":"uuid"},"setIdentifier":{"type":"string","description":"New identifier distinguishing entries with the same name and type. When null, the identifier is removed, which is only valid for `SIMPLE` routing.","nullable":true},"ttl":{"type":"integer","description":"New time to live in seconds. Record sets with the same name and type share one TTL. Updating the TTL updates all of them. When omitted, the current TTL is kept. A null value is rejected. From 0 to 2147483647.","nullable":true},"values":{"type":"array","description":"New record values. The list replaces the one currently set. When omitted, the current values are kept. A null value is rejected.","nullable":true,"items":{"type":"string"}},"weight":{"type":"integer","description":"New relative weight for `WEIGHTED` routing. When null, the weight is removed. From 0 to 255.","nullable":true}}},"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"}},"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":{"/dns/gslb/zone/{zoneId}/recordSet":{"get":{"operationId":"getAllGslbRecordSets","summary":"List GSLB record sets in a hosted zone","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"header","name":"X-Pagination-Cursor","description":"Pagination cursor","schema":{"type":"string"}},{"in":"header","name":"X-Pagination-Size","description":"Pagination size","schema":{"type":"integer"}},{"in":"query","name":"name","description":"Filter by exact record set name, ignoring case. The trailing dot is optional.","schema":{"type":"string"}},{"in":"query","name":"type","description":"Filter by DNS record type","schema":{"$ref":"#/components/schemas/dns.gslb.RecordTypeEnum"}},{"in":"path","name":"zoneId","description":"Zone ID","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/dns.gslb.RecordSet"}}}}},"400":{"description":"Error 400 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::BadRequest::ValidationError":{"value":{"class":"Client::BadRequest::ValidationError","message":"Your request contains an invalid parameter or configuration: {{.reason}}"}}}}}},"404":{"description":"Error 404 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::NotFound::HostedZoneNotFound":{"value":{"class":"Client::NotFound::HostedZoneNotFound","message":"Your hosted zone was not found."}}}}}}},"x-developer-hub-navigation":[["Network","Global LB","Record sets@@@10"]],"x-badges":[{"color":"blue","label":"Alpha 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(\"/v2/dns/gslb/zone/{zoneId}/recordSet\")\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(\"/v2/dns/gslb/zone/{zoneId}/recordSet\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"gslbZone:apiovh:record/get","required":true}],"x-response-identifier":"id","x-expanded-response":"DnsGslbRecordSet"},"post":{"operationId":"createGslbRecordSet","summary":"Create a GSLB record set","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"zoneId","description":"Zone ID","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/dns.gslb.CreateRecordSetRequest"}}}},"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/dns.gslb.RecordSet"}}}},"400":{"description":"Error 400 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::BadRequest::ValidationError":{"value":{"class":"Client::BadRequest::ValidationError","message":"Your request contains an invalid parameter or configuration: {{.reason}}"}}}}}},"403":{"description":"Error 403 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::Forbidden":{"value":{"class":"Client::Forbidden","message":"You are not authorized to access this GSLB resource."}}}}}},"404":{"description":"Error 404 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::NotFound::HealthCheckNotFound":{"value":{"class":"Client::NotFound::HealthCheckNotFound","message":"Your health check was not found."}},"Client::NotFound::HostedZoneNotFound":{"value":{"class":"Client::NotFound::HostedZoneNotFound","message":"Your hosted zone was not found."}}}}}},"409":{"description":"Error 409 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::Conflict::RecordSetConflict":{"value":{"class":"Client::Conflict::RecordSetConflict","message":"Your record set conflicts with an existing record or routing configuration."}}}}}}},"x-developer-hub-navigation":[["Network","Global LB","Record sets@@@30"]],"x-badges":[{"color":"blue","label":"Alpha 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: dns.gslb.CreateRecordSetRequest\nresult = client.post(\"/v2/dns/gslb/zone/{zoneId}/recordSet\",\n\tchainTarget = None, # Target record name for chaining, up to three hops. Unavailable for GEOPROXIMITY parents. (type: string, nullable)\n\tcoordinates = None, # Endpoint coordinates, required for GEOPROXIMITY routing (type: dns.gslb.Coordinates, nullable)\n\tevaluateTargetHealth = None, # Whether to fall through to the global scope when the chain target is unhealthy. Only supported for GEOLOCATION chains. (type: boolean, nullable)\n\tfailover = None, # Failover role of this entry, required for FAILOVER routing. PRIMARY requires a health check. Immutable after creation. (type: dns.gslb.FailoverTypeEnum, nullable)\n\tgeoLocation = None, # Geographic scope of this entry, required for GEOLOCATION routing. An empty object is the global fallback. (type: dns.gslb.GeoLocation, nullable)\n\thealthCheckId = None, # Associated health check. Unsupported for SIMPLE. (type: string, nullable)\n\tname = None, # Fully qualified domain name in the hosted zone, ending with a dot. Immutable after creation. (type: string)\n\troutingPolicy = None, # Traffic routing policy, defaults to SIMPLE. Immutable after creation. (type: dns.gslb.RoutingPolicyEnum, nullable)\n\tsetIdentifier = None, # Identifier that distinguishes entries with the same name and type. Required for non-SIMPLE routing. At most 128 characters. (type: string, nullable)\n\tttl = None, # Time to live in seconds. Record sets with the same name and type share one TTL. The value must equal the TTL of any existing one. From 0 to 2147483647. (type: integer)\n\ttype = None, # DNS record type. FAILOVER, GEOLOCATION, MULTIVALUE and GEOPROXIMITY require A or AAAA. Immutable after creation. (type: dns.gslb.RecordTypeEnum)\n\tvalues = None, # Record values. Required unless `chainTarget` is set. A `CNAME` accepts a single value. `MULTIVALUE` and `GEOPROXIMITY` accept one value per entry. (type: array, nullable)\n\tweight = None, # Relative weight of this entry for WEIGHTED routing. Required for WEIGHTED routing. From 0 to 255. (type: integer, nullable)\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: dns.gslb.CreateRecordSetRequest\n$result = $ovh->post(\"/v2/dns/gslb/zone/{zoneId}/recordSet\", array(\n\tchainTarget => null, // Target record name for chaining, up to three hops. Unavailable for GEOPROXIMITY parents. (type: string, nullable)\n\tcoordinates => null, // Endpoint coordinates, required for GEOPROXIMITY routing (type: dns.gslb.Coordinates, nullable)\n\tevaluateTargetHealth => null, // Whether to fall through to the global scope when the chain target is unhealthy. Only supported for GEOLOCATION chains. (type: boolean, nullable)\n\tfailover => null, // Failover role of this entry, required for FAILOVER routing. PRIMARY requires a health check. Immutable after creation. (type: dns.gslb.FailoverTypeEnum, nullable)\n\tgeoLocation => null, // Geographic scope of this entry, required for GEOLOCATION routing. An empty object is the global fallback. (type: dns.gslb.GeoLocation, nullable)\n\thealthCheckId => null, // Associated health check. Unsupported for SIMPLE. (type: string, nullable)\n\tname => null, // Fully qualified domain name in the hosted zone, ending with a dot. Immutable after creation. (type: string)\n\troutingPolicy => null, // Traffic routing policy, defaults to SIMPLE. Immutable after creation. (type: dns.gslb.RoutingPolicyEnum, nullable)\n\tsetIdentifier => null, // Identifier that distinguishes entries with the same name and type. Required for non-SIMPLE routing. At most 128 characters. (type: string, nullable)\n\tttl => null, // Time to live in seconds. Record sets with the same name and type share one TTL. The value must equal the TTL of any existing one. From 0 to 2147483647. (type: integer)\n\ttype => null, // DNS record type. FAILOVER, GEOLOCATION, MULTIVALUE and GEOPROXIMITY require A or AAAA. Immutable after creation. (type: dns.gslb.RecordTypeEnum)\n\tvalues => null, // Record values. Required unless `chainTarget` is set. A `CNAME` accepts a single value. `MULTIVALUE` and `GEOPROXIMITY` accept one value per entry. (type: array, nullable)\n\tweight => null, // Relative weight of this entry for WEIGHTED routing. Required for WEIGHTED routing. From 0 to 255. (type: integer, nullable)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"gslbZone:apiovh:record/create","required":true},{"name":"gslbHealthCheck:apiovh:get","description":"Required on the health check referenced by `healthCheckId`, when one is set","required":true}]}},"/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}":{"delete":{"operationId":"deleteGslbRecordSet","summary":"Delete a GSLB record set","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"recordSetId","description":"Record set ID","required":true,"schema":{"type":"string","format":"uuid"}},{"in":"path","name":"zoneId","description":"Zone ID","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"successful operation"}},"x-developer-hub-navigation":[["Network","Global LB","Record sets@@@50"]],"x-badges":[{"color":"blue","label":"Alpha 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(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\")\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(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"gslbZone:apiovh:record/delete","required":true}]},"get":{"operationId":"getGslbRecordSet","summary":"Get a GSLB record set","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"recordSetId","description":"Record set ID","required":true,"schema":{"type":"string","format":"uuid"}},{"in":"path","name":"zoneId","description":"Zone ID","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/dns.gslb.RecordSet"}}}},"404":{"description":"Error 404 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::NotFound::HostedZoneNotFound":{"value":{"class":"Client::NotFound::HostedZoneNotFound","message":"Your hosted zone was not found."}},"Client::NotFound::RecordSetNotFound":{"value":{"class":"Client::NotFound::RecordSetNotFound","message":"Your record set was not found."}}}}}}},"x-developer-hub-navigation":[["Network","Global LB","Record sets@@@20"]],"x-badges":[{"color":"blue","label":"Alpha 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(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\")\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(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"gslbZone:apiovh:record/get","required":true}],"x-response-identifier":"id"},"patch":{"operationId":"updateGslbRecordSet","summary":"Update a GSLB record set. Name, type, routing policy and failover role are immutable.","description":"Omitted fields keep their current value. A null value removes a field, except `ttl` and `values`, which cannot be null.\n\nRecord sets with the same name and type share one TTL. Updating the TTL updates all of them.\n\nLinking a health check also requires the `gslbHealthCheck:apiovh:get` action on that health check.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"recordSetId","description":"Record set ID","required":true,"schema":{"type":"string","format":"uuid"}},{"in":"path","name":"zoneId","description":"Zone ID","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/dns.gslb.UpdateRecordSetRequest"}}}},"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/dns.gslb.RecordSet"}}}},"400":{"description":"Error 400 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::BadRequest::ValidationError":{"value":{"class":"Client::BadRequest::ValidationError","message":"Your request contains an invalid parameter or configuration: {{.reason}}"}}}}}},"403":{"description":"Error 403 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::Forbidden":{"value":{"class":"Client::Forbidden","message":"You are not authorized to access this GSLB resource."}}}}}},"404":{"description":"Error 404 response","content":{"application/json":{"schema":{"type":"object","description":"Common error model","properties":{"class":{"type":"string","description":"Class of the error"},"message":{"type":"string","description":"Error message"}}},"examples":{"Client::NotFound::HealthCheckNotFound":{"value":{"class":"Client::NotFound::HealthCheckNotFound","message":"Your health check was not found."}},"Client::NotFound::HostedZoneNotFound":{"value":{"class":"Client::NotFound::HostedZoneNotFound","message":"Your hosted zone was not found."}},"Client::NotFound::RecordSetNotFound":{"value":{"class":"Client::NotFound::RecordSetNotFound","message":"Your record set was not found."}}}}}}},"x-developer-hub-navigation":[["Network","Global LB","Record sets@@@40"]],"x-badges":[{"color":"blue","label":"Alpha 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: dns.gslb.UpdateRecordSetRequest\nresult = client.patch(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\",\n\tchainTarget = None, # New target record name for chained routing. When null or empty, the chain target is removed. (type: string, nullable)\n\tcoordinates = None, # New endpoint coordinates for `GEOPROXIMITY` routing. When null, the coordinates are removed. (type: dns.gslb.Coordinates, nullable)\n\tevaluateTargetHealth = None, # Whether to fall through to the global scope when a `GEOLOCATION` chain target is unhealthy. When null, the value is reset to false. (type: boolean, nullable)\n\tgeoLocation = None, # New geographic scope for `GEOLOCATION` routing. When null, the scope is removed. (type: dns.gslb.GeoLocation, nullable)\n\thealthCheckId = None, # Health check to link. Omit it to keep the current link, or set it to null to unlink the current health check. (type: string, nullable)\n\tsetIdentifier = None, # New identifier distinguishing entries with the same name and type. When null, the identifier is removed, which is only valid for `SIMPLE` routing. (type: string, nullable)\n\tttl = None, # New time to live in seconds. Record sets with the same name and type share one TTL. Updating the TTL updates all of them. When omitted, the current TTL is kept. A null value is rejected. From 0 to 2147483647. (type: integer, nullable)\n\tvalues = None, # New record values. The list replaces the one currently set. When omitted, the current values are kept. A null value is rejected. (type: array, nullable)\n\tweight = None, # New relative weight for `WEIGHTED` routing. When null, the weight is removed. From 0 to 255. (type: integer, nullable)\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: dns.gslb.UpdateRecordSetRequest\n$result = $ovh->patch(\"/v2/dns/gslb/zone/{zoneId}/recordSet/{recordSetId}\", array(\n\tchainTarget => null, // New target record name for chained routing. When null or empty, the chain target is removed. (type: string, nullable)\n\tcoordinates => null, // New endpoint coordinates for `GEOPROXIMITY` routing. When null, the coordinates are removed. (type: dns.gslb.Coordinates, nullable)\n\tevaluateTargetHealth => null, // Whether to fall through to the global scope when a `GEOLOCATION` chain target is unhealthy. When null, the value is reset to false. (type: boolean, nullable)\n\tgeoLocation => null, // New geographic scope for `GEOLOCATION` routing. When null, the scope is removed. (type: dns.gslb.GeoLocation, nullable)\n\thealthCheckId => null, // Health check to link. Omit it to keep the current link, or set it to null to unlink the current health check. (type: string, nullable)\n\tsetIdentifier => null, // New identifier distinguishing entries with the same name and type. When null, the identifier is removed, which is only valid for `SIMPLE` routing. (type: string, nullable)\n\tttl => null, // New time to live in seconds. Record sets with the same name and type share one TTL. Updating the TTL updates all of them. When omitted, the current TTL is kept. A null value is rejected. From 0 to 2147483647. (type: integer, nullable)\n\tvalues => null, // New record values. The list replaces the one currently set. When omitted, the current values are kept. A null value is rejected. (type: array, nullable)\n\tweight => null, // New relative weight for `WEIGHTED` routing. When null, the weight is removed. From 0 to 255. (type: integer, nullable)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"gslbZone:apiovh:record/edit","required":true},{"name":"gslbHealthCheck:apiovh:get","description":"Required on the health check referenced by `healthCheckId`, when one is set","required":true}]}}}}
