{"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 !"},"cloud.Credit":{"type":"object","description":"Cloud credit","properties":{"available_credit":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Available credit","readOnly":true},"bill":{"type":"string","description":"Credit bill id","nullable":true,"readOnly":true},"description":{"type":"string","description":"Credit description","nullable":true,"readOnly":true},"id":{"type":"integer","description":"Credit id","readOnly":true},"products":{"type":"array","description":"Use credits on following products","nullable":true,"items":{"type":"string"},"readOnly":true},"total_credit":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total credit","readOnly":true},"used_credit":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Used credit","readOnly":true},"validity":{"allOf":[{"$ref":"#/components/schemas/cloud.common.VoucherValidity"}],"description":"Credit validity","nullable":true,"readOnly":true},"voucher":{"type":"string","description":"Voucher code","nullable":true,"readOnly":true}}},"cloud.billingView.BandwidthInstance":{"type":"object","description":"BandwidthInstance","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total bandwidth in GiB","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.BandwidthStorage":{"type":"object","description":"BandwidthStorage","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total bandwidth in GiB","readOnly":true},"resourceIds":{"type":"array","description":"List of resource IDs","items":{"type":"string"},"readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.Component":{"type":"object","description":"Component","properties":{"id":{"type":"string","description":"Component ID","readOnly":true},"name":{"type":"string","description":"Name of the component","readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total quantity for the component","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"type":"number","description":"Total price for this component","readOnly":true}}},"cloud.billingView.HourlyDetail":{"type":"object","description":"HourlyDetail","properties":{"id":{"type":"string","description":"ID","readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Quantity","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyInstance":{"type":"object","description":"HourlyInstance","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about hourly instances","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyInstanceDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Hours of run instances","readOnly":true},"reference":{"type":"string","description":"Instance reference","readOnly":true},"region":{"type":"string","description":"Instance region","readOnly":true},"savingsPlanIds":{"type":"array","description":"Savings Plan IDs","nullable":true,"items":{"type":"string"},"readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.HourlyInstanceBandwidth":{"type":"object","description":"HourlyInstanceBandwidth","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"incomingBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthInstance"}],"description":"Instance incoming bandwidth details","nullable":true,"readOnly":true},"outgoingBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthInstance"}],"description":"Instance outgoing bandwidth details","nullable":true,"readOnly":true},"region":{"type":"string","description":"Region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.HourlyInstanceDetail":{"type":"object","description":"HourlyInstanceDetail","properties":{"instanceId":{"type":"string","description":"Instance ID","readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Hours of run instances","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.HourlyInstanceOption":{"type":"object","description":"HourlyInstanceOption","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about hourly instances option","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyInstanceOptionDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Quantity of instance hours running with this option","readOnly":true},"reference":{"type":"string","description":"Instance reference","readOnly":true},"region":{"type":"string","description":"Instance region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.HourlyInstanceOptionDetail":{"type":"object","description":"HourlyInstanceOptionDetail","properties":{"instanceId":{"type":"string","description":"Instance ID","readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Quantity of instance hours running with this option","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.HourlyManagedKubernetesService":{"type":"object","description":"HourlyManagedKubernetesService","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about managed kubernetes services","nullable":true,"items":{"$ref":"#/components/schemas/cloud.billingView.HourlyDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total hours of usage","readOnly":true},"reference":{"type":"string","description":"Reference","nullable":true,"readOnly":true},"region":{"type":"string","description":"Region","nullable":true,"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyQuantum":{"type":"object","description":"HourlyQuantum","properties":{"notebook":{"type":"array","description":"Details about hourly quantum notebooks","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyQuantumNotebook"},"readOnly":true},"processingUnit":{"type":"array","description":"Details about hourly quantum processing unit","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyQuantumProcessingUnit"},"readOnly":true}}},"cloud.billingView.HourlyQuantumNotebook":{"type":"object","description":"HourlyQuantumNotebook","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about quantums","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Quantum quantity","readOnly":true},"reference":{"type":"string","description":"Quantum reference","readOnly":true},"region":{"type":"string","description":"Quantum region","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyQuantumProcessingUnit":{"type":"object","description":"HourlyQuantumProcessingUnit","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about quantums","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Quantum quantity","readOnly":true},"reference":{"type":"string","description":"Quantum reference","readOnly":true},"region":{"type":"string","description":"Quantum region","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyRancher":{"type":"object","description":"HourlyRancher","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about hourly Rancher","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyRancherDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Hours of Rancher","readOnly":true},"reference":{"type":"string","description":"Instance reference","readOnly":true},"region":{"type":"string","description":"Instance region","readOnly":true},"savingsPlanIds":{"type":"array","description":"Savings Plan IDs","nullable":true,"items":{"type":"string"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyRancherDetail":{"type":"object","description":"HourlyRancherDetail","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Hours of Rancher","readOnly":true},"rancherId":{"type":"string","description":"Rancher ID","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.HourlyResources":{"type":"object","description":"HourlyResources","properties":{"instance":{"type":"array","description":"Details about hourly instances","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyInstance"},"readOnly":true},"instanceBandwidth":{"type":"array","description":"Details about instances bandwidth consumption","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyInstanceBandwidth"},"readOnly":true},"instanceOption":{"type":"array","description":"Details about hourly instances options","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyInstanceOption"},"readOnly":true},"managedKubernetesService":{"type":"array","description":"Details about managed kubernetes services","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyManagedKubernetesService"},"readOnly":true},"quantum":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.HourlyQuantum"}],"description":"Details about hourly quantums","readOnly":true},"rancher":{"type":"array","description":"Details about hourly Rancher","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyRancher"},"readOnly":true},"snapshot":{"type":"array","description":"Details about hourly snapshots","items":{"$ref":"#/components/schemas/cloud.billingView.HourlySnapshot"},"readOnly":true},"storage":{"type":"array","description":"Details about hourly storage","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyStorage"},"readOnly":true},"volume":{"type":"array","description":"Details about hourly volumes","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyVolume"},"readOnly":true}}},"cloud.billingView.HourlySnapshot":{"type":"object","description":"HourlySnapshot","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"instance":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.InstanceSnapshot"}],"description":"Instance snapshot details","nullable":true,"readOnly":true},"region":{"type":"string","description":"Region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true},"volume":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.VolumeSnapshot"}],"description":"Volume snapshot details","nullable":true,"readOnly":true}}},"cloud.billingView.HourlyStorage":{"type":"object","description":"HourlyStorage","properties":{"bucketName":{"type":"string","description":"Bucket Name","nullable":true,"readOnly":true},"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"incomingBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthStorage"}],"description":"Storage incoming bandwidth details","nullable":true,"readOnly":true},"incomingInternalBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthStorage"}],"description":"Storage incoming internal bandwidth details","nullable":true,"readOnly":true},"outgoingBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthStorage"}],"description":"Storage outgoing bandwidth details","nullable":true,"readOnly":true},"outgoingInternalBandwidth":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.BandwidthStorage"}],"description":"Storage outgoing internal bandwidth details","nullable":true,"readOnly":true},"region":{"type":"string","description":"Region","readOnly":true},"retrievalFees":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.RetrievalFees"}],"description":"Storage retrieval fee details","nullable":true,"readOnly":true},"stored":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.StoredStorage"}],"description":"Information about stored data","nullable":true,"readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true},"type":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.StorageTypeEnum"}],"description":"Storage type","readOnly":true}}},"cloud.billingView.HourlyVolume":{"type":"object","description":"HourlyVolume","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Detail about volume consumption","items":{"$ref":"#/components/schemas/cloud.billingView.HourlyVolumeDetail"},"readOnly":true},"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total GiBh of volume","readOnly":true},"region":{"type":"string","description":"Region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true},"type":{"type":"string","description":"Volume type","readOnly":true}}},"cloud.billingView.HourlyVolumeDetail":{"type":"object","description":"HourlyVolumeDetail","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"GiBh of volume","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true},"volumeId":{"type":"string","description":"Volume ID","readOnly":true}}},"cloud.billingView.InstanceSnapshot":{"type":"object","description":"InstanceSnapshot","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"GiBh stored","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyCertification":{"type":"object","description":"MonthlyCertification","properties":{"details":{"type":"array","description":"Details about certifications","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyCertificationDetail"},"readOnly":true},"reference":{"type":"string","description":"Certification reference","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyCertificationDetail":{"type":"object","description":"MonthlyCertificationDetail","properties":{"activation":{"type":"string","description":"Certification activation","format":"date-time","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyInstance":{"type":"object","description":"MonthlyInstance","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about monthly instances","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyInstanceDetail"},"readOnly":true},"reference":{"type":"string","description":"Instance reference","readOnly":true},"region":{"type":"string","description":"Instance region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyInstanceDetail":{"type":"object","description":"MonthlyInstanceDetail","properties":{"activation":{"type":"string","description":"Monthly instance activation","format":"date-time","readOnly":true},"instanceId":{"type":"string","description":"Instance ID","readOnly":true},"resourceId":{"type":"string","description":"Resource ID","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyInstanceOption":{"type":"object","description":"MonthlyInstanceOption","properties":{"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"details":{"type":"array","description":"Details about monthly instances","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyInstanceOptionDetail"},"readOnly":true},"reference":{"type":"string","description":"Instance reference","readOnly":true},"region":{"type":"string","description":"Instance region","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyInstanceOptionDetail":{"type":"object","description":"MonthlyInstanceOptionDetail","properties":{"instanceId":{"type":"string","description":"Instance ID","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.MonthlyResources":{"type":"object","description":"MonthlyResources","properties":{"certification":{"type":"array","description":"Details about certifications","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyCertification"},"readOnly":true},"instance":{"type":"array","description":"Details about monthly instances","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyInstance"},"readOnly":true},"instanceOption":{"type":"array","description":"Details about monthly instances options","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlyInstanceOption"},"readOnly":true},"savingsPlan":{"type":"array","description":"Details about savings plan subscriptions","items":{"$ref":"#/components/schemas/cloud.billingView.MonthlySavingsPlan"},"readOnly":true}}},"cloud.billingView.MonthlySavingsPlan":{"type":"object","description":"MonthlySavingsPlan","properties":{"details":{"type":"array","description":"Detailed listing of all flat fees","items":{"$ref":"#/components/schemas/cloud.plan.Detail"},"readOnly":true},"flavor":{"type":"string","description":"Flavor of the savings plan","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price of the flat fee part of associated savings plans","readOnly":true}}},"cloud.billingView.Quantity":{"type":"object","description":"Quantity","properties":{"unit":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.UnitQuantityEnum"}],"description":"Quantity unit","readOnly":true},"value":{"type":"number","description":"Quantity value","readOnly":true}}},"cloud.billingView.RegionalizedResource":{"type":"object","description":"RegionalizedResource","properties":{"components":{"type":"array","description":"List of components","items":{"$ref":"#/components/schemas/cloud.billingView.Component"},"readOnly":true},"deploymentMode":{"allOf":[{"$ref":"#/components/schemas/common.RegionTypeEnum"}],"description":"Specifies the deployment mode of the region where the resource is deployed (for example, 1-AZ or 3-AZ). Products that are grouped by project or have no region do not include a deployment mode","nullable":true,"readOnly":true},"region":{"type":"string","description":"Region of the resource","readOnly":true}}},"cloud.billingView.RetrievalFees":{"type":"object","description":"RetrievalFees","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"Total retrieval fees in GiB","readOnly":true},"resourceIds":{"type":"array","description":"List of resource IDs","items":{"type":"string"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.billingView.StorageTypeEnum":{"type":"string","description":"StorageTypeEnum","enum":["pca","pcs","storage-coldarchive","storage-glacier-ir","storage-high-perf","storage-standard","storage-standard-ia"]},"cloud.billingView.StoredStorage":{"type":"object","description":"StoredStorage","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"GiBh stored","readOnly":true},"resourceIds":{"type":"array","description":"List of resource IDs","items":{"type":"string"},"readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.billingView.TypedResources":{"type":"object","description":"TypedResources","properties":{"resources":{"type":"array","description":"Resources per region","items":{"$ref":"#/components/schemas/cloud.billingView.RegionalizedResource"},"readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true},"type":{"type":"string","description":"Type of the resources","readOnly":true}}},"cloud.billingView.UnitQuantityEnum":{"type":"string","description":"UnitQuantity","enum":["GiB","GiBh","Hour","Minute","Second","Unit"]},"cloud.billingView.UsedCredit":{"type":"object","description":"UsedCredit","properties":{"description":{"type":"string","description":"Credit description","readOnly":true},"id":{"type":"integer","description":"Credit ID","readOnly":true},"usedAmount":{"type":"number","description":"Total credit used","readOnly":true}}},"cloud.billingView.UsedCredits":{"type":"object","description":"UsedCredits","properties":{"details":{"type":"array","description":"Details about credits that will be used","items":{"$ref":"#/components/schemas/cloud.billingView.UsedCredit"},"readOnly":true},"totalCredit":{"type":"number","description":"Total credit that will be used to pay the bill","readOnly":true}}},"cloud.billingView.VolumeSnapshot":{"type":"object","description":"VolumeSnapshot","properties":{"quantity":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.Quantity"}],"description":"GiBh stored","readOnly":true},"totalPrice":{"type":"number","description":"Total price","readOnly":true}}},"cloud.common.VoucherValidity":{"type":"object","description":"Voucher validity range","properties":{"from":{"type":"string","description":"Valid from","nullable":true,"format":"date-time"},"to":{"type":"string","description":"Valid to","nullable":true,"format":"date-time"}}},"cloud.plan.Detail":{"type":"object","description":"Fee detail","properties":{"id":{"type":"string","description":"The plan id","format":"uuid","readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.usage.Period"}],"description":"Plan period","readOnly":true},"planName":{"type":"string","description":"Name of the plan","nullable":true,"readOnly":true},"size":{"type":"number","description":"The plan size (ex: number of instances)","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price of the plan, computed from size and unit price","readOnly":true},"unitPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Unit price of the plan","readOnly":true}}},"cloud.plan.Fees":{"type":"object","description":"Details of fees for all plan subscriptions for this flavor","properties":{"flatFee":{"allOf":[{"$ref":"#/components/schemas/cloud.plan.FlatFee"}],"description":"Description of the flat fee for the plan","readOnly":true},"overQuota":{"allOf":[{"$ref":"#/components/schemas/cloud.plan.OverQuota"}],"description":"Detailed of fees when the consumption exceeds the size of the plans","readOnly":true},"savedAmount":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total amount saved by using plans","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price of plan subscriptions for this flavor","readOnly":true}}},"cloud.plan.FlatFee":{"type":"object","description":"Details of fees regardless of the consumption","properties":{"details":{"type":"array","description":"Detailed listing of all flat fees","items":{"$ref":"#/components/schemas/cloud.plan.Detail"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price of the flat fee part of associated plans","readOnly":true}}},"cloud.plan.Flavor":{"type":"object","description":"Consumption details by flavor","properties":{"fees":{"allOf":[{"$ref":"#/components/schemas/cloud.plan.Fees"}],"description":"Fees associated to the plans for this flavor","readOnly":true},"flavor":{"type":"string","description":"The flavor for the plans","readOnly":true},"periods":{"type":"array","description":"Listing of all periods concerning this flavor saving plans : every change in usage or plans will make a new period","items":{"$ref":"#/components/schemas/cloud.plan.PlanPeriod"},"readOnly":true},"subscriptions":{"type":"array","description":"List of existing plan subscriptions for the flavor","items":{"$ref":"#/components/schemas/cloud.plan.Subscription"},"readOnly":true}}},"cloud.plan.OverQuota":{"type":"object","description":"Details of fees when the consumption exceeds the size of the plans","properties":{"ids":{"type":"array","description":"List of plan ids","items":{"type":"string","format":"uuid"},"readOnly":true},"quantity":{"type":"number","description":"Quantity consumed over the size of the plans","readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price of the over quota, computed from quantity and unit price","readOnly":true},"unitPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Unit price for the over quota","readOnly":true}}},"cloud.plan.Period":{"type":"object","description":"Period","properties":{"from":{"type":"string","description":"Start of the period","format":"date-time","readOnly":true},"to":{"type":"string","description":"End of the period","format":"date-time","readOnly":true}}},"cloud.plan.PlanPeriod":{"type":"object","description":"Consumption period for a flavor","properties":{"begin":{"type":"string","description":"Begin date of the period","format":"date-time","readOnly":true},"consumptionSize":{"type":"integer","description":"Size of the plan consumed","readOnly":true},"coverage":{"type":"string","description":"Human readable percentage of usages covered by the plan","readOnly":true},"cumulPlanSize":{"type":"integer","description":"Size of all plans combined","readOnly":true},"end":{"type":"string","description":"End date of the period","format":"date-time","readOnly":true},"plansIds":{"type":"array","description":"List of plans Ids","items":{"type":"string","format":"uuid"},"readOnly":true},"resourceIds":{"type":"array","description":"List of resource IDs that could be covered by this plan","items":{"type":"string"},"readOnly":true},"utilization":{"type":"string","description":"Human readable percentage of the savings plan utilization","readOnly":true}}},"cloud.plan.Subscription":{"type":"object","description":"Plan subscription for a flavor","properties":{"begin":{"type":"string","description":"Start date of the savings plan","format":"date-time","readOnly":true},"end":{"type":"string","description":"End date of the savings plan","format":"date-time","readOnly":true},"id":{"type":"string","description":"Id of the plan","format":"uuid","readOnly":true},"size":{"type":"integer","description":"Size of the plans","readOnly":true}}},"cloud.usage.Period":{"type":"object","description":"Period","properties":{"from":{"type":"string","description":"Usage from","format":"date-time","readOnly":true},"to":{"type":"string","description":"Usage to","format":"date-time","readOnly":true}}},"cloud.usage.PlanResponse":{"type":"object","description":"Usage of plans","properties":{"flavors":{"type":"array","description":"List of consumption details by flavor","items":{"$ref":"#/components/schemas/cloud.plan.Flavor"},"readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.plan.Period"}],"description":"Requested period","readOnly":true},"projectId":{"type":"string","description":"Project ID of the fetched plans","readOnly":true},"totalSavings":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total savings for all the flavors","readOnly":true}}},"cloud.usage.UsageCurrent":{"type":"object","description":"UsageCurrent","properties":{"hourlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.HourlyResources"}],"description":"Hourly usage","nullable":true,"readOnly":true},"lastUpdate":{"type":"string","description":"Entry last update","format":"date-time","readOnly":true},"monthlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.MonthlyResources"}],"description":"Monthly usage","nullable":true,"readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.usage.Period"}],"description":"Usage dates (from/to)","readOnly":true},"resourcesUsage":{"type":"array","description":"Resource usage (billed per hour/minute/second/unit)","nullable":true,"items":{"$ref":"#/components/schemas/cloud.billingView.TypedResources"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"cloud.usage.UsageForecast":{"type":"object","description":"UsageForecast","properties":{"hourlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.HourlyResources"}],"description":"Hourly forecast","nullable":true,"readOnly":true},"lastUpdate":{"type":"string","description":"Entry last update","format":"date-time","readOnly":true},"monthlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.MonthlyResources"}],"description":"Monthly forecast","nullable":true,"readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.usage.Period"}],"description":"Forecast dates (from/to)","readOnly":true},"resourcesUsage":{"type":"array","description":"Resource usage forecast (billed per hour/minute/second/unit)","nullable":true,"items":{"$ref":"#/components/schemas/cloud.billingView.TypedResources"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true},"usableCredits":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.UsedCredits"}],"description":"Usable credit to pay next bill","nullable":true,"readOnly":true}}},"cloud.usage.UsageHistory":{"type":"object","description":"UsageHistory","properties":{"id":{"type":"string","description":"Usage id","readOnly":true},"lastUpdate":{"type":"string","description":"Entry last update","format":"date-time","readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.usage.Period"}],"description":"Usage dates (from/to)","readOnly":true}}},"cloud.usage.UsageHistoryDetail":{"type":"object","description":"UsageHistoryDetail","properties":{"hourlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.HourlyResources"}],"description":"Hourly usage","nullable":true,"readOnly":true},"id":{"type":"string","description":"Usage id","readOnly":true},"lastUpdate":{"type":"string","description":"Entry last update","format":"date-time","readOnly":true},"monthlyUsage":{"allOf":[{"$ref":"#/components/schemas/cloud.billingView.MonthlyResources"}],"description":"Monthly usage","nullable":true,"readOnly":true},"period":{"allOf":[{"$ref":"#/components/schemas/cloud.usage.Period"}],"description":"Usage dates (from/to)","readOnly":true},"resourcesUsage":{"type":"array","description":"Resource usage (billed per hour/minute/second/unit)","nullable":true,"items":{"$ref":"#/components/schemas/cloud.billingView.TypedResources"},"readOnly":true},"totalPrice":{"allOf":[{"$ref":"#/components/schemas/order.Price"}],"description":"Total price","readOnly":true}}},"common.RegionTypeEnum":{"type":"string","description":"Typology of the region","enum":["LOCAL-ZONE","REGION-1-AZ","REGION-3-AZ"]},"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"},"order.CurrencyCodeEnum":{"type":"string","enum":["AUD","CAD","CZK","EUR","GBP","INR","LTL","MAD","N/A","PLN","SGD","TND","USD","XOF","points"]},"order.Price":{"type":"object","description":"Price with it's currency and textual representation","properties":{"currencyCode":{"$ref":"#/components/schemas/order.CurrencyCodeEnum"},"text":{"type":"string"},"value":{"type":"number"}}},"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":{"/cloud/project/{serviceName}/credit":{"get":{"summary":"List project credits. Returns the IDs of the credits added to the project.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The project id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"type":"integer"}}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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\nresult = client.get(\"/cloud/project/{serviceName}/credit\")\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(\"/cloud/project/{serviceName}/credit\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:credit/get","required":true}],"x-expanded-response":"CloudCredit"},"post":{"summary":"Add a voucher credit. Adds the credit of a voucher code to the project.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"The project id","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"string","description":"Voucher code"}},"required":["code"]}}}},"responses":{"200":{"description":"successful operation"}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@100"]],"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(\"/cloud/project/{serviceName}/credit\",\n\tcode = None, # Voucher code (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(\"/cloud/project/{serviceName}/credit\", array(\n\tcode => null, // Voucher code (type: string)\n));\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:credit/create","required":true}]}},"/cloud/project/{serviceName}/credit/{id}":{"get":{"summary":"Get a project credit","description":"Get a project credit. Returns the total, used and available amounts of the credit, its validity period and the products it applies to.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"id","description":"Credit id","required":true,"schema":{"type":"integer"}},{"in":"path","name":"serviceName","description":"The project id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cloud.Credit"}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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.get(\"/cloud/project/{serviceName}/credit/{id}\")\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(\"/cloud/project/{serviceName}/credit/{id}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:credit/get","required":true}]}},"/cloud/project/{serviceName}/usage/current":{"get":{"summary":"Get current usage","description":"Returns the usage and price of the project for the current month, by resource type: hourly, monthly and per-unit resources.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"Service name","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cloud.usage.UsageCurrent"}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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(\"/cloud/project/{serviceName}/usage/current\")\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(\"/cloud/project/{serviceName}/usage/current\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:usage/current/get","required":true}]}},"/cloud/project/{serviceName}/usage/forecast":{"get":{"summary":"Get usage forecast","description":"Returns the forecast usage and price of the project at the end of the current month, and the credits that can pay the next bill.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"Service name","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cloud.usage.UsageForecast"}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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(\"/cloud/project/{serviceName}/usage/forecast\")\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(\"/cloud/project/{serviceName}/usage/forecast\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:usage/forecast/get","required":true}]}},"/cloud/project/{serviceName}/usage/history":{"get":{"summary":"List past usage periods","description":"Returns the past usage periods of the project. Filter them with the `from` and `to` dates, then get the details of one period with its ID.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"query","name":"from","description":"Filter results having date superior to from","schema":{"type":"string","format":"date-time"}},{"in":"path","name":"serviceName","description":"Service name","required":true,"schema":{"type":"string"}},{"in":"query","name":"to","description":"Filter results having date inferior to","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/cloud.usage.UsageHistory"}}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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(\"/cloud/project/{serviceName}/usage/history\")\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(\"/cloud/project/{serviceName}/usage/history\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:usage/history/get","required":true}]}},"/cloud/project/{serviceName}/usage/history/{usageId}":{"get":{"summary":"Get a past usage period","description":"Returns the usage and price of the project for one past period, by resource type.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"path","name":"serviceName","description":"Service name","required":true,"schema":{"type":"string"}},{"in":"path","name":"usageId","description":"Usage ID","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cloud.usage.UsageHistoryDetail"}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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.get(\"/cloud/project/{serviceName}/usage/history/{usageId}\")\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(\"/cloud/project/{serviceName}/usage/history/{usageId}\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:usage/history/get","required":true}],"x-response-identifier":"id"}},"/cloud/project/{serviceName}/usage/plans":{"get":{"summary":"Get savings plan consumption","description":"Returns, for each flavor, the savings plan subscriptions, their coverage and utilization over time, and the amount saved. Filter by flavor, year and month.","security":[{"oAuth2AuthCode":[]}],"parameters":[{"in":"query","name":"flavor","description":"Flavor to filter plans on","schema":{"type":"string"}},{"in":"query","name":"month","description":"Month of the period to extract plans consumption","schema":{"type":"integer"}},{"in":"path","name":"serviceName","description":"Service name","required":true,"schema":{"type":"string"}},{"in":"query","name":"year","description":"Year of the period to extract plans consumption","schema":{"type":"integer"}}],"responses":{"200":{"description":"successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/cloud.usage.PlanResponse"}}}}},"x-developer-hub-navigation":[["Public Cloud","Project Management","Usage@@@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\nresult = client.get(\"/cloud/project/{serviceName}/usage/plans\")\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(\"/cloud/project/{serviceName}/usage/plans\");\n\nprint_r($result);\n?>"}],"x-iam-actions":[{"name":"publicCloudProject:apiovh:usage/plans/get","required":true}]}}}}
