{"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.CurrentTask":{"type":"object","description":"Asynchronous operation currently running","properties":{"errors":{"type":"array","description":"Errors that occurred on the task","nullable":true,"items":{"$ref":"#/components/schemas/common.TaskError"},"readOnly":true},"id":{"type":"string","description":"Identifier of the current task","format":"uuid","readOnly":true},"link":{"type":"string","description":"Link to the task details","readOnly":true},"status":{"allOf":[{"$ref":"#/components/schemas/common.CurrentTaskStatusEnum"}],"description":"Current global status of the current task","nullable":true,"readOnly":true},"type":{"type":"string","description":"Type of the current task","readOnly":true}}},"common.CurrentTaskStatusEnum":{"type":"string","description":"Current status of a task. A task in ERROR cannot be retried without your inputs. PENDING tasks will be executed as soon as possible. A RUNNING task is currently executing your original request. SCHEDULED is used for tasks that will be executed in the future.","enum":["ERROR","PENDING","RUNNING","SCHEDULED","WAITING_USER_INPUT"]},"common.ResourceStatusEnum":{"type":"string","description":"Current status of a resource","enum":["CREATING","CREATION_PLANNED","DELETING","ERROR","OUT_OF_SYNC","READY","SUSPENDED","UNKNOWN","UPDATING"]},"common.TaskError":{"type":"object","description":"Errors that occurred on the task","properties":{"message":{"type":"string","description":"Error description","readOnly":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"},"publicCloud.common.Location":{"type":"object","description":"Resource location","properties":{"availabilityZone":{"type":"string","description":"Availability zone within the region","nullable":true},"region":{"type":"string","description":"Region code"}},"required":["region"]},"publicCloud.quota.Quota":{"type":"object","description":"A Public Cloud project quota","properties":{"checksum":{"type":"string","description":"Computed hash representing the current target specification value","readOnly":true},"createdAt":{"type":"string","description":"Creation date of the quota","format":"date-time","readOnly":true},"currentState":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaCurrentState"}],"description":"Current state of the quota","nullable":true,"readOnly":true},"currentTasks":{"type":"array","description":"Ongoing asynchronous tasks related to the quota","nullable":true,"items":{"$ref":"#/components/schemas/common.CurrentTask"},"readOnly":true},"id":{"type":"string","description":"Project ID this quota belongs to","readOnly":true},"resourceStatus":{"allOf":[{"$ref":"#/components/schemas/common.ResourceStatusEnum"}],"description":"Quota readiness in the system","readOnly":true},"targetSpec":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaTargetSpec"}],"description":"Last target specification of the quota","readOnly":true},"updatedAt":{"type":"string","description":"Last update date of the quota","format":"date-time","readOnly":true}}},"publicCloud.quota.QuotaCurrentState":{"type":"object","description":"Current state of the project quota","properties":{"availableProfiles":{"type":"array","description":"Quota profiles available to this project","nullable":true,"items":{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfile"},"readOnly":true},"preventAutomaticQuotaUpgrade":{"type":"boolean","description":"When true, automatic quota upgrades are disabled for this project","readOnly":true},"regions":{"type":"array","description":"Current state per region","nullable":true,"items":{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionCurrentState"},"readOnly":true}}},"publicCloud.quota.QuotaLimit":{"type":"object","description":"Quota limit without usage tracking (for per-item size caps)","properties":{"limit":{"type":"integer","description":"Maximum allowed","readOnly":true},"unit":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUnitEnum"}],"description":"Unit of measurement","readOnly":true}}},"publicCloud.quota.QuotaProfile":{"type":"object","description":"A Public Cloud quota profile (read-only reference data)","properties":{"compute":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileCompute"}],"description":"Compute limits","nullable":true,"readOnly":true},"keyManager":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileKeyManager"}],"description":"Key manager limits","nullable":true,"readOnly":true},"keypair":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileKeypair"}],"description":"Keypair limits","nullable":true,"readOnly":true},"loadbalancer":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileLoadbalancer"}],"description":"Loadbalancer limits","nullable":true,"readOnly":true},"name":{"type":"string","description":"Profile name","readOnly":true},"network":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileNetwork"}],"description":"Network limits","nullable":true,"readOnly":true},"share":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileShare"}],"description":"File storage limits","nullable":true,"readOnly":true},"volume":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaProfileVolume"}],"description":"Block storage limits","nullable":true,"readOnly":true}}},"publicCloud.quota.QuotaProfileCompute":{"type":"object","description":"Compute limits for a quota profile","properties":{"cores":{"type":"integer","description":"Maximum allowed CPU cores","readOnly":true},"instances":{"type":"integer","description":"Maximum allowed instances","readOnly":true},"memory":{"type":"integer","description":"Maximum allowed memory in MB","readOnly":true}}},"publicCloud.quota.QuotaProfileKeyManager":{"type":"object","description":"Key manager limits for a quota profile","properties":{"containers":{"type":"integer","description":"Maximum allowed containers","readOnly":true},"secrets":{"type":"integer","description":"Maximum allowed secrets","readOnly":true}}},"publicCloud.quota.QuotaProfileKeypair":{"type":"object","description":"Keypair limits for a quota profile","properties":{"keypairs":{"type":"integer","description":"Maximum allowed keypairs","readOnly":true}}},"publicCloud.quota.QuotaProfileLoadbalancer":{"type":"object","description":"Loadbalancer limits for a quota profile","properties":{"healthMonitors":{"type":"integer","description":"Maximum allowed health monitors","readOnly":true},"l7Policies":{"type":"integer","description":"Maximum allowed L7 policies","readOnly":true},"l7Rules":{"type":"integer","description":"Maximum allowed L7 rules","readOnly":true},"listeners":{"type":"integer","description":"Maximum allowed listeners","readOnly":true},"loadbalancers":{"type":"integer","description":"Maximum allowed loadbalancers","readOnly":true},"members":{"type":"integer","description":"Maximum allowed pool members","readOnly":true},"pools":{"type":"integer","description":"Maximum allowed pools","readOnly":true}}},"publicCloud.quota.QuotaProfileNetwork":{"type":"object","description":"Network limits for a quota profile","properties":{"floatingIps":{"type":"integer","description":"Maximum allowed floating IPs","readOnly":true},"gateways":{"type":"integer","description":"Maximum allowed gateways","readOnly":true},"networks":{"type":"integer","description":"Maximum allowed networks","readOnly":true},"securityGroupRules":{"type":"integer","description":"Maximum allowed security group rules","readOnly":true},"securityGroups":{"type":"integer","description":"Maximum allowed security groups","readOnly":true},"subnets":{"type":"integer","description":"Maximum allowed subnets","readOnly":true}}},"publicCloud.quota.QuotaProfileShare":{"type":"object","description":"File storage limits for a quota profile","properties":{"backupSizeTotal":{"type":"integer","description":"Maximum allowed total backup storage size in GB","readOnly":true},"backups":{"type":"integer","description":"Maximum allowed share backups","readOnly":true},"shares":{"type":"integer","description":"Maximum allowed shares","readOnly":true},"sizeTotal":{"type":"integer","description":"Maximum allowed total share storage size in GB","readOnly":true},"snapshots":{"type":"integer","description":"Maximum allowed share snapshots","readOnly":true}}},"publicCloud.quota.QuotaProfileVolume":{"type":"object","description":"Block storage limits for a quota profile","properties":{"backupSizeTotal":{"type":"integer","description":"Maximum allowed total backup storage size in GB","readOnly":true},"backups":{"type":"integer","description":"Maximum allowed volume backups","readOnly":true},"sizeTotal":{"type":"integer","description":"Maximum allowed total volume storage size in GB","readOnly":true},"snapshots":{"type":"integer","description":"Maximum allowed volume snapshots","readOnly":true},"volumes":{"type":"integer","description":"Maximum allowed volumes","readOnly":true}}},"publicCloud.quota.QuotaRegionCompute":{"type":"object","description":"Per-region compute quota usage","properties":{"cores":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"CPU cores quota usage","readOnly":true},"instances":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Instances quota usage","readOnly":true},"memory":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Memory quota usage in MB","readOnly":true}}},"publicCloud.quota.QuotaRegionCurrentState":{"type":"object","description":"Current state of the project quota in a single region","properties":{"location":{"allOf":[{"$ref":"#/components/schemas/publicCloud.common.Location"}],"description":"Region where the quota applies","readOnly":true},"profile":{"type":"string","description":"Currently applied quota profile name","readOnly":true},"usage":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsageDetails"}],"description":"Quota usage for this region","nullable":true,"readOnly":true}}},"publicCloud.quota.QuotaRegionKeyManager":{"type":"object","description":"Per-region key manager quota usage","properties":{"containers":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Containers quota usage","readOnly":true},"secrets":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Secrets quota usage","readOnly":true}}},"publicCloud.quota.QuotaRegionKeypair":{"type":"object","description":"Per-region keypair quota","properties":{"keypairs":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Keypairs quota","readOnly":true}}},"publicCloud.quota.QuotaRegionLoadbalancer":{"type":"object","description":"Per-region load balancer quota usage","properties":{"healthMonitors":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Health monitors quota usage","readOnly":true},"l7Policies":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"L7 policies quota usage","readOnly":true},"l7Rules":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"L7 rules quota usage","readOnly":true},"listeners":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Listeners quota usage","readOnly":true},"loadbalancers":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Load balancers quota usage","readOnly":true},"members":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Pool members quota usage","readOnly":true},"pools":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Pools quota usage","readOnly":true}}},"publicCloud.quota.QuotaRegionNetwork":{"type":"object","description":"Per-region network quota usage","properties":{"floatingIps":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Floating IPs quota usage","readOnly":true},"gateways":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Gateways quota usage","readOnly":true},"networks":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Networks quota usage","readOnly":true},"securityGroupRules":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Security group rules quota usage","readOnly":true},"securityGroups":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Security groups quota usage","readOnly":true},"subnets":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Subnets quota usage","readOnly":true}}},"publicCloud.quota.QuotaRegionShare":{"type":"object","description":"Per-region file storage quota usage","properties":{"backupSizeTotal":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"File storage backup storage quota usage","readOnly":true},"backups":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"File storage backups quota usage","readOnly":true},"perShareSize":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaLimit"}],"description":"Maximum size per individual share","readOnly":true},"shareNetworks":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Share networks quota usage","readOnly":true},"shares":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"File storages quota usage","readOnly":true},"sizeTotal":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Total file storage size quota usage in GB","readOnly":true},"snapshotSizeTotal":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"File storage snapshot storage quota usage","readOnly":true},"snapshots":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"File storage snapshots quota usage","readOnly":true}}},"publicCloud.quota.QuotaRegionTargetSpec":{"type":"object","description":"Target specification for the project quota in a single region","properties":{"location":{"allOf":[{"$ref":"#/components/schemas/publicCloud.common.Location"}],"description":"Region where the profile applies"},"profile":{"type":"string","description":"Quota profile to apply in this region. Available values are in currentState.availableProfiles."}},"required":["location","profile"]},"publicCloud.quota.QuotaRegionVolume":{"type":"object","description":"Per-region volume quota usage","properties":{"backupSizeTotal":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Volume backup storage quota usage","readOnly":true},"backups":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Volume backups quota usage","readOnly":true},"perVolumeSize":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaLimit"}],"description":"Maximum size per individual volume","readOnly":true},"sizeTotal":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Total volume storage quota usage","readOnly":true},"snapshots":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Volume snapshots quota usage","readOnly":true},"volumes":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUsage"}],"description":"Volumes quota usage","readOnly":true}}},"publicCloud.quota.QuotaTargetSpec":{"type":"object","description":"Target specification for the project quota","properties":{"preventAutomaticQuotaUpgrade":{"type":"boolean","description":"When true, automatic quota upgrades are disabled for this project","readOnly":true},"regions":{"type":"array","description":"Target quota profile per region","items":{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionTargetSpec"},"readOnly":true}}},"publicCloud.quota.QuotaUnitEnum":{"type":"string","description":"Unit of measurement for quota limits and usage","enum":["COUNT","GB","GiB","MB","MiB","TB","TiB"]},"publicCloud.quota.QuotaUpdate":{"type":"object","description":"Payload to update a Public Cloud project quota","properties":{"checksum":{"type":"string","description":"Optional concurrency-control checksum. When supplied, it must match the resource's current checksum or the request is rejected with a 409 checksum-mismatch conflict. When omitted or empty, the concurrency check is skipped and the write is forced (last-write-wins).","nullable":true},"targetSpec":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUpdateTargetSpec"}],"description":"Update specification"}},"required":["targetSpec"]},"publicCloud.quota.QuotaUpdateTargetSpec":{"type":"object","description":"Update specification for the project quota","properties":{"preventAutomaticQuotaUpgrade":{"type":"boolean","description":"When true, automatic quota upgrades are disabled for this project"},"regions":{"type":"array","description":"Target quota profile per region. Regions omitted are left unchanged. This is the one deliberate exception to the replace semantics every other update route on this API follows: the list is applied as an element-level upsert keyed by region, not as a whole-list replacement, so that raising the quota of one region does not force a caller to restate every other region of the project.","items":{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionTargetSpec"}}},"required":["preventAutomaticQuotaUpgrade","regions"]},"publicCloud.quota.QuotaUsage":{"type":"object","description":"Quota usage with limit and current consumption","properties":{"limit":{"type":"integer","description":"Maximum allowed","readOnly":true},"unit":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaUnitEnum"}],"description":"Unit of measurement","readOnly":true},"used":{"type":"integer","description":"Currently used (may be omitted when not available)","nullable":true,"readOnly":true}}},"publicCloud.quota.QuotaUsageDetails":{"type":"object","description":"Quota usage across all services for a single region","properties":{"compute":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionCompute"}],"description":"Compute quota usage","nullable":true,"readOnly":true},"keyManager":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionKeyManager"}],"description":"Key manager quota usage","nullable":true,"readOnly":true},"keypair":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionKeypair"}],"description":"Keypair quota usage","nullable":true,"readOnly":true},"loadbalancer":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionLoadbalancer"}],"description":"Load balancer quota usage","nullable":true,"readOnly":true},"network":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionNetwork"}],"description":"Network quota usage","nullable":true,"readOnly":true},"share":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionShare"}],"description":"File storage quota usage","nullable":true,"readOnly":true},"volume":{"allOf":[{"$ref":"#/components/schemas/publicCloud.quota.QuotaRegionVolume"}],"description":"Block storage quota usage","nullable":true,"readOnly":true}}},"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":{"/publicCloud/project/{projectId}/quota":{"get":{"operationId":"getQuota","summary":"Get the project quota","description":"Returns the project quota. When the `region` query parameter is set, the response narrows `targetSpec.regions` and `currentState.regions` to that single region. Omit it to get all regions.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"projectId","description":"Project ID","required":true,"schema":{"type":"string"}},{"in":"query","name":"region","description":"Optional region filter","schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/publicCloud.quota.Quota"}}}},"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::ServiceNotAvailableInRegion":{"value":{"class":"Client::BadRequest::ServiceNotAvailableInRegion","message":"This service is not available in the selected region"}}}}}},"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::ResourceInInvalidState":{"value":{"class":"Client::Conflict::ResourceInInvalidState","message":"Resource cannot be modified in its current state"}}}}}}},"tags":["Quota"],"x-developer-hub-navigation":[["Public Cloud","Project Management","Quota@@@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(\"/v2/publicCloud/project/{projectId}/quota\")\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/publicCloud/project/{projectId}/quota\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:quota/get","required":true}],"x-response-identifier":"id"},"put":{"operationId":"editQuota","summary":"Update the project quota","description":"Updates the project quota region by region. Each region listed in `targetSpec.regions` is added or updated, and the regions you omit are left unchanged, so raising the quota of one region does not require restating the others. Unlike the other update routes of this API, this list is merged, not replaced. `preventAutomaticQuotaUpgrade` is required.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"projectId","description":"Project ID","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/publicCloud.quota.QuotaUpdate"}}}},"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/publicCloud.quota.Quota"}}}},"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::InvalidParameter":{"value":{"class":"Client::BadRequest::InvalidParameter","message":"Invalid parameter in the request"}},"Client::BadRequest::ServiceNotAvailableInRegion":{"value":{"class":"Client::BadRequest::ServiceNotAvailableInRegion","message":"This service is not available in the selected region"}}}}}},"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::ChecksumMismatch":{"value":{"class":"Client::Conflict::ChecksumMismatch","message":"Checksum mismatch — a concurrent update was detected. Refresh the resource and retry"}},"Client::Conflict::ResourceInInvalidState":{"value":{"class":"Client::Conflict::ResourceInInvalidState","message":"Resource cannot be modified in its current state"}}}}}}},"tags":["Quota"],"x-developer-hub-navigation":[["Public Cloud","Project Management","Quota@@@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\n# Request body type: publicCloud.quota.QuotaUpdate\nresult = client.put(\"/v2/publicCloud/project/{projectId}/quota\",\n\tchecksum = None, # Optional concurrency-control checksum. When supplied, it must match the resource's current checksum or the request is rejected with a 409 checksum-mismatch conflict. When omitted or empty, the concurrency check is skipped and the write is forced (last-write-wins). (type: string, nullable)\n\ttargetSpec = None, # Update specification (type: publicCloud.quota.QuotaUpdateTargetSpec)\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: publicCloud.quota.QuotaUpdate\n$result = $ovh->put(\"/v2/publicCloud/project/{projectId}/quota\", array(\n\tchecksum => null, // Optional concurrency-control checksum. When supplied, it must match the resource's current checksum or the request is rejected with a 409 checksum-mismatch conflict. When omitted or empty, the concurrency check is skipped and the write is forced (last-write-wins). (type: string, nullable)\n\ttargetSpec => null, // Update specification (type: publicCloud.quota.QuotaUpdateTargetSpec)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:quota/edit","required":true}]}}},"tags":[{"name":"Quota","x-tag-expanded":false,"description":"Missing description"}]}
