AWS CLIにpricingコマンドが追加されました
はじめに
中山(順)です
AWS CLIにpricingコマンドが追加されました。
同時に、Price List APIで取得可能な情報が増えたようです。
Access detailed product pricing information using the AWS Price List API
早速、どんな感じか確認してみました。
サブコマンド一覧
3つのサブコマンドが用意されているようです。
コマンドの詳細はリファレンスをご確認ください。
少ないので、全部見ていきましょう。
describe-services
このコマンドでは、価格を取得できるサービスとその価格に紐づく属性情報を確認できます。
(このコマンドでは価格自体は取得していません)
結果も表示していますが、長すぎるので一部カットしています。
1 | aws pricing describe-services |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 | { "Services": [ { "ServiceCode": "AWSBudgets", "AttributeNames": [ "productFamily", "servicecode", "groupDescription", "termType", "usagetype", "locationType", "location" ] }, { "ServiceCode": "AWSCloudTrail", "AttributeNames": [ "productFamily", "servicecode", "termType", "usagetype", "locationType", "location", "servicename" ] }, { "ServiceCode": "AWSCodeCommit", "AttributeNames": [ "productFamily", "servicecode", "termType", "usagetype", "locationType", "location", "group" ] }, (省略) { "ServiceCode": "AmazonEC2", "AttributeNames": [ "volumeType", "maxIopsvolume", "instanceCapacity10xlarge", "locationType", "instanceFamily", "operatingSystem", "clockSpeed", "LeaseContractLength", "ecu", "networkPerformance", "instanceCapacity8xlarge", "group", "maxThroughputvolume", "ebsOptimized", "maxVolumeSize", "gpu", "processorFeatures", "intelAvxAvailable", "instanceCapacity4xlarge", "servicecode", "groupDescription", "processorArchitecture", "physicalCores", "productFamily", "enhancedNetworkingSupported", "intelTurboAvailable", "memory", "dedicatedEbsThroughput", "vcpu", "OfferingClass", "instanceCapacityLarge", "termType", "storage", "intelAvx2Available", "storageMedia", "physicalProcessor", "provisioned", "servicename", "PurchaseOption", "instanceType", "tenancy", "usagetype", "normalizationSizeFactor", "instanceCapacity16xlarge", "instanceCapacity2xlarge", "maxIopsBurstPerformance", "instanceCapacity32xlarge", "instanceCapacityXlarge", "licenseModel", "currentGeneration", "preInstalledSw", "location", "instanceCapacityMedium", "operation" ] }, (一部省略) { "ServiceCode": "AmazonRDS", "AttributeNames": [ "productFamily", "volumeType", "engineCode", "enhancedNetworkingSupported", "memory", "dedicatedEbsThroughput", "vcpu", "OfferingClass", "termType", "locationType", "storage", "instanceFamily", "storageMedia", "databaseEdition", "physicalProcessor", "clockSpeed", "LeaseContractLength", "networkPerformance", "deploymentOption", "servicename", "PurchaseOption", "minVolumeSize", "group", "instanceType", "usagetype", "normalizationSizeFactor", "maxVolumeSize", "databaseEngine", "processorFeatures", "servicecode", "groupDescription", "licenseModel", "currentGeneration", "location", "processorArchitecture", "operation" ] }, (一部省略) { "ServiceCode": "awswaf", "AttributeNames": [ "productFamily", "servicecode", "groupDescription", "termType", "usagetype", "locationType", "location", "group" ] }, { "ServiceCode": "datapipeline", "AttributeNames": [ "productFamily", "frequencyMode", "termType", "usagetype", "locationType", "description", "executionFrequency", "servicecode", "location", "group", "executionLocation" ] }, { "ServiceCode": "mobileanalytics", "AttributeNames": [ "productFamily", "servicecode", "includedEvents", "termType", "usagetype", "description", "locationType", "location", "operation" ] } ], "FormatVersion": "aws_v1"} |
EC2、RDSの属性が多いのが印象的です。
get-products
このコマンドでは、サービスごとの価格表を取得できます。
以下のように、--service-codeでサービスを指定します。
--service-codeは、先ほどのdescribe-servicesコマンドで確認可能です。
Amazon EC2の場合は以下の通りです。
1 | aws pricing get-products --service-code AmazonEC2 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | { "FormatVersion": "aws_v1", "NextToken": "iZG0Dvlv1IrU8m4dCig36w==:8eTMe/gs7ztHrPJj1ZCMQnx/Xhlv+LQtXZa42ru4Euky6DaKcm5U8HgiMKFGH2D0HXxpG3OGnGJb7rNtfR91urbwZTxhqvuRNVXlGlP11FjWgvkMBezvxa9qW05Zj4T9LgXMiKa2+F6dEcjd8JRTVlqK/vjVdG3fLdPLPmGPZ8c/HUn4k6F5+zFVQsdlyPgf", "PriceList": [ "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"30.5 GiB\",\"dedicatedEbsThroughput\":\"800 Mbps\",\"vcpu\":\"4\",\"locationType\":\"AWS Region\",\"storage\":\"EBS only\",\"instanceFamily\":\"Memory optimized\",\"operatingSystem\":\"SUSE\",\"physicalProcessor\":\"Intel Xeon E5-2686 v4 (Broadwell)\",\"clockSpeed\":\"2.3 GHz\",\"ecu\":\"Variable\",\"networkPerformance\":\"Up to 10 Gigabit\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"instanceType\":\"r4.xlarge\",\"tenancy\":\"Shared\",\"usagetype\":\"USW2-BoxUsage:r4.xlarge\",\"normalizationSizeFactor\":\"8\",\"processorFeatures\":\"Intel AVX, Intel AVX2, Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"licenseModel\":\"No License required\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"NA\",\"location\":\"US West (Oregon)\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:000g\"},\"sku\":\"223BX6UNNB3JE9ET\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"223BX6UNNB3JE9ET.JRTCKXETXF\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.366 per On Demand SUSE r4.xlarge Instance Hour\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.3660000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}},\"Reserved\":{\"223BX6UNNB3JE9ET.HU7G6KETJZ\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.HU7G6KETJZ.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.HU7G6KETJZ.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"875\"}},\"223BX6UNNB3JE9ET.HU7G6KETJZ.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.HU7G6KETJZ.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0930000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"HU7G6KETJZ\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"Partial Upfront\"}},\"223BX6UNNB3JE9ET.6QCMYABX3D\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.6QCMYABX3D.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.6QCMYABX3D.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"1660\"}},\"223BX6UNNB3JE9ET.6QCMYABX3D.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.6QCMYABX3D.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2016-11-30T23:59:59Z\",\"offerTermCode\":\"6QCMYABX3D\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"All Upfront\"}},\"223BX6UNNB3JE9ET.BPH4J8HBKS\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.BPH4J8HBKS.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.BPH4J8HBKS.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.1475000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"BPH4J8HBKS\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"No Upfront\"}},\"223BX6UNNB3JE9ET.Z2E3P23VKM\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.Z2E3P23VKM.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.Z2E3P23VKM.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.1647000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"Z2E3P23VKM\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"No Upfront\"}},\"223BX6UNNB3JE9ET.MZU6U2429S\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.MZU6U2429S.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.MZU6U2429S.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}},\"223BX6UNNB3JE9ET.MZU6U2429S.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.MZU6U2429S.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"3833\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"MZU6U2429S\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"All Upfront\"}},\"223BX6UNNB3JE9ET.4NA7Y494T4\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.4NA7Y494T4.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.4NA7Y494T4.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.2010000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"4NA7Y494T4\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"No Upfront\"}},\"223BX6UNNB3JE9ET.NQ3QZPMQV9\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.NQ3QZPMQV9.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.NQ3QZPMQV9.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}},\"223BX6UNNB3JE9ET.NQ3QZPMQV9.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.NQ3QZPMQV9.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"3322\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"NQ3QZPMQV9\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"All Upfront\"}},\"223BX6UNNB3JE9ET.R5XV2EPZQZ\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.R5XV2EPZQZ.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.R5XV2EPZQZ.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"1954\"}},\"223BX6UNNB3JE9ET.R5XV2EPZQZ.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.R5XV2EPZQZ.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0739000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"R5XV2EPZQZ\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"Partial Upfront\"}},\"223BX6UNNB3JE9ET.38NPMPTW36\":{\"priceDimensions\":{\"223BX6UNNB3JE9ET.38NPMPTW36.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.38NPMPTW36.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"1750\"}},\"223BX6UNNB3JE9ET.38NPMPTW36.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"SUSE Linux (Amazon VPC), r4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"223BX6UNNB3JE9ET.38NPMPTW36.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0660000000\"}}},\"sku\":\"223BX6UNNB3JE9ET\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"38NPMPTW36\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"Partial Upfront\"}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}", "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"7.5 GiB\",\"dedicatedEbsThroughput\":\"750 Mbps\",\"vcpu\":\"4\",\"locationType\":\"AWS Region\",\"storage\":\"EBS only\",\"instanceFamily\":\"Compute optimized\",\"operatingSystem\":\"Windows\",\"physicalProcessor\":\"Intel Xeon E5-2666 v3 (Haswell)\",\"clockSpeed\":\"2.9 GHz\",\"ecu\":\"16\",\"networkPerformance\":\"High\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"instanceType\":\"c4.xlarge\",\"tenancy\":\"Dedicated\",\"usagetype\":\"EUW2-DedicatedUsage:c4.xlarge\",\"normalizationSizeFactor\":\"8\",\"processorFeatures\":\"Intel AVX; Intel AVX2; Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"licenseModel\":\"No License required\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"NA\",\"location\":\"EU (London)\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:0002\"},\"sku\":\"224367QE5DEDFDMY\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"224367QE5DEDFDMY.JRTCKXETXF\":{\"priceDimensions\":{\"224367QE5DEDFDMY.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.445 per Dedicated Usage Windows c4.xlarge Instance Hour\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.4450000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}},\"Reserved\":{\"224367QE5DEDFDMY.38NPMPTW36\":{\"priceDimensions\":{\"224367QE5DEDFDMY.38NPMPTW36.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.38NPMPTW36.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"4076\"}},\"224367QE5DEDFDMY.38NPMPTW36.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.38NPMPTW36.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.1550000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"38NPMPTW36\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"Partial Upfront\"}},\"224367QE5DEDFDMY.BPH4J8HBKS\":{\"priceDimensions\":{\"224367QE5DEDFDMY.BPH4J8HBKS.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.BPH4J8HBKS.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.3220000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"BPH4J8HBKS\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"No Upfront\"}},\"224367QE5DEDFDMY.R5XV2EPZQZ\":{\"priceDimensions\":{\"224367QE5DEDFDMY.R5XV2EPZQZ.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.R5XV2EPZQZ.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"4346\"}},\"224367QE5DEDFDMY.R5XV2EPZQZ.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.R5XV2EPZQZ.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.1650000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"R5XV2EPZQZ\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"Partial Upfront\"}},\"224367QE5DEDFDMY.NQ3QZPMQV9\":{\"priceDimensions\":{\"224367QE5DEDFDMY.NQ3QZPMQV9.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.NQ3QZPMQV9.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}},\"224367QE5DEDFDMY.NQ3QZPMQV9.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.NQ3QZPMQV9.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"7953\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"NQ3QZPMQV9\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"All Upfront\"}},\"224367QE5DEDFDMY.MZU6U2429S\":{\"priceDimensions\":{\"224367QE5DEDFDMY.MZU6U2429S.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.MZU6U2429S.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"8615\"}},\"224367QE5DEDFDMY.MZU6U2429S.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.MZU6U2429S.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"MZU6U2429S\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"All Upfront\"}},\"224367QE5DEDFDMY.6QCMYABX3D\":{\"priceDimensions\":{\"224367QE5DEDFDMY.6QCMYABX3D.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.6QCMYABX3D.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"3079\"}},\"224367QE5DEDFDMY.6QCMYABX3D.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"USD 0.0 per Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.6QCMYABX3D.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"6QCMYABX3D\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"All Upfront\"}},\"224367QE5DEDFDMY.HU7G6KETJZ\":{\"priceDimensions\":{\"224367QE5DEDFDMY.HU7G6KETJZ.2TG2D8R56U\":{\"unit\":\"Quantity\",\"description\":\"Upfront Fee\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.HU7G6KETJZ.2TG2D8R56U\",\"pricePerUnit\":{\"USD\":\"1555\"}},\"224367QE5DEDFDMY.HU7G6KETJZ.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.HU7G6KETJZ.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.1770000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2016-10-31T23:59:59Z\",\"offerTermCode\":\"HU7G6KETJZ\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"Partial Upfront\"}},\"224367QE5DEDFDMY.4NA7Y494T4\":{\"priceDimensions\":{\"224367QE5DEDFDMY.4NA7Y494T4.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.4NA7Y494T4.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.3640000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"4NA7Y494T4\",\"termAttributes\":{\"LeaseContractLength\":\"1yr\",\"OfferingClass\":\"standard\",\"PurchaseOption\":\"No Upfront\"}},\"224367QE5DEDFDMY.Z2E3P23VKM\":{\"priceDimensions\":{\"224367QE5DEDFDMY.Z2E3P23VKM.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"Windows (Amazon VPC), c4.xlarge reserved instance applied\",\"appliesTo\":[],\"rateCode\":\"224367QE5DEDFDMY.Z2E3P23VKM.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.3420000000\"}}},\"sku\":\"224367QE5DEDFDMY\",\"effectiveDate\":\"2017-04-30T23:59:59Z\",\"offerTermCode\":\"Z2E3P23VKM\",\"termAttributes\":{\"LeaseContractLength\":\"3yr\",\"OfferingClass\":\"convertible\",\"PurchaseOption\":\"No Upfront\"}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}", "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"15 GiB\",\"dedicatedEbsThroughput\":\"1000 Mbps\",\"vcpu\":\"8\",\"locationType\":\"AWS Region\",\"storage\":\"EBS only\",\"instanceFamily\":\"Compute optimized\",\"operatingSystem\":\"Windows\",\"physicalProcessor\":\"Intel Xeon E5-2666 v3 (Haswell)\",\"clockSpeed\":\"2.9 GHz\",\"ecu\":\"31\",\"networkPerformance\":\"High\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"instanceType\":\"c4.2xlarge\",\"tenancy\":\"Host\",\"usagetype\":\"APS2-HostBoxUsage:c4.2xlarge\",\"normalizationSizeFactor\":\"16\",\"processorFeatures\":\"Intel AVX; Intel AVX2; Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"licenseModel\":\"No License required\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"SQL Std\",\"location\":\"Asia Pacific (Sydney)\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:0006\"},\"sku\":\"227XM55V752FNUMS\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"227XM55V752FNUMS.JRTCKXETXF\":{\"priceDimensions\":{\"227XM55V752FNUMS.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.000 per Windows with SQL Std c4.2xlarge Dedicated Host Instance hour\",\"appliesTo\":[],\"rateCode\":\"227XM55V752FNUMS.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"227XM55V752FNUMS\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}", (一部省略) "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"244 GiB\",\"vcpu\":\"36\",\"instanceType\":\"d2.8xlarge\",\"tenancy\":\"Host\",\"usagetype\":\"APS3-HostBoxUsage:d2.8xlarge\",\"locationType\":\"AWS Region\",\"storage\":\"24 x 2000 HDD\",\"normalizationSizeFactor\":\"64\",\"instanceFamily\":\"Storage optimized\",\"operatingSystem\":\"SUSE\",\"processorFeatures\":\"Intel AVX; Intel AVX2; Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"physicalProcessor\":\"Intel Xeon E5-2676v3 (Haswell)\",\"clockSpeed\":\"2.4 GHz\",\"licenseModel\":\"No License required\",\"ecu\":\"116\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"NA\",\"networkPerformance\":\"10 Gigabit\",\"location\":\"Asia Pacific (Mumbai)\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:000g\"},\"sku\":\"27PWGAPHWZRV6WYP\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"27PWGAPHWZRV6WYP.JRTCKXETXF\":{\"priceDimensions\":{\"27PWGAPHWZRV6WYP.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.000 per SUSE d2.8xlarge Dedicated Host Instance hour\",\"appliesTo\":[],\"rateCode\":\"27PWGAPHWZRV6WYP.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"27PWGAPHWZRV6WYP\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}", "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"488 GiB\",\"dedicatedEbsThroughput\":\"14000 Mbps\",\"vcpu\":\"64\",\"locationType\":\"AWS Region\",\"storage\":\"8 x 1.9 NVMe SSD\",\"instanceFamily\":\"Storage optimized\",\"operatingSystem\":\"RHEL\",\"physicalProcessor\":\"Intel Xeon E5-2686 v4 (Broadwell)\",\"clockSpeed\":\"2.3 GHz\",\"ecu\":\"27\",\"networkPerformance\":\"20 Gigabit\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"instanceType\":\"i3.16xlarge\",\"tenancy\":\"Host\",\"usagetype\":\"APS2-HostBoxUsage:i3.16xlarge\",\"normalizationSizeFactor\":\"128\",\"processorFeatures\":\"Intel AVX, Intel AVX2, Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"licenseModel\":\"No License required\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"NA\",\"location\":\"Asia Pacific (Sydney)\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:0010\"},\"sku\":\"27Q3XE5F2PB7P7V2\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"27Q3XE5F2PB7P7V2.JRTCKXETXF\":{\"priceDimensions\":{\"27Q3XE5F2PB7P7V2.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.00 per RHEL i3.16xlarge Dedicated Host Instance hour\",\"appliesTo\":[],\"rateCode\":\"27Q3XE5F2PB7P7V2.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"27Q3XE5F2PB7P7V2\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}", "{\"product\":{\"productFamily\":\"Compute Instance\",\"attributes\":{\"enhancedNetworkingSupported\":\"Yes\",\"memory\":\"15 GiB\",\"vcpu\":\"8\",\"instanceType\":\"c3.2xlarge\",\"tenancy\":\"Host\",\"usagetype\":\"APS1-HostBoxUsage:c3.2xlarge\",\"locationType\":\"AWS Region\",\"storage\":\"2 x 80 SSD\",\"normalizationSizeFactor\":\"16\",\"instanceFamily\":\"Compute optimized\",\"operatingSystem\":\"Windows\",\"processorFeatures\":\"Intel AVX; Intel Turbo\",\"servicecode\":\"AmazonEC2\",\"physicalProcessor\":\"Intel Xeon E5-2680 v2 (Ivy Bridge)\",\"clockSpeed\":\"2.8 GHz\",\"licenseModel\":\"Bring your own license\",\"ecu\":\"28\",\"currentGeneration\":\"Yes\",\"preInstalledSw\":\"NA\",\"networkPerformance\":\"High\",\"location\":\"Asia Pacific (Singapore)\",\"servicename\":\"Amazon Elastic Compute Cloud\",\"processorArchitecture\":\"64-bit\",\"operation\":\"RunInstances:0800\"},\"sku\":\"27QBKMTHWSUPSFJ5\"},\"serviceCode\":\"AmazonEC2\",\"terms\":{\"OnDemand\":{\"27QBKMTHWSUPSFJ5.JRTCKXETXF\":{\"priceDimensions\":{\"27QBKMTHWSUPSFJ5.JRTCKXETXF.6YS6EN2CT7\":{\"unit\":\"Hrs\",\"endRange\":\"Inf\",\"description\":\"$0.000 per Windows BYOL c3.2xlarge Dedicated Host Instance hour\",\"appliesTo\":[],\"rateCode\":\"27QBKMTHWSUPSFJ5.JRTCKXETXF.6YS6EN2CT7\",\"beginRange\":\"0\",\"pricePerUnit\":{\"USD\":\"0.0000000000\"}}},\"sku\":\"27QBKMTHWSUPSFJ5\",\"effectiveDate\":\"2017-10-01T00:00:00Z\",\"offerTermCode\":\"JRTCKXETXF\",\"termAttributes\":{}}}},\"version\":\"20171026015458\",\"publicationDate\":\"2017-10-26T01:54:58Z\"}" ]} |
・・・結果の通り、非常に巨大な配列が返ってきます。
また、1度に取得できる情報は100件までで、これ以降の情報を取得したい場合にはNextTokenを指定して同じコマンドを実行してください。
get-attribute-values
サービス名と属性名を指定し、存在する属性値を出力することができるコマンドです。
例えば、EC2で利用されているプロセッサーを確認することが可能です。
1 | aws pricing get-attribute-values --service-code AmazonEC2 --attribute-name physicalProcessor |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | { "AttributeValues": [ { "Value": "High Frequency Intel Xeon E7-8880 v3 (Haswell)" }, { "Value": "Intel Xeon E5-2650" }, { "Value": "Intel Xeon E5-2666 v3 (Haswell)" }, { "Value": "Intel Xeon E5-2670 (Sandy Bridge)" }, { "Value": "Intel Xeon E5-2670 v2 (Ivy Bridge)" }, { "Value": "Intel Xeon E5-2670 v2 (Ivy Bridge/Sandy Bridge)" }, { "Value": "Intel Xeon E5-2670" }, { "Value": "Intel Xeon E5-2676 v3 (Haswell)" }, { "Value": "Intel Xeon E5-2676v3 (Haswell)" }, { "Value": "Intel Xeon E5-2680 v2 (Ivy Bridge)" }, { "Value": "Intel Xeon E5-2686 v4 (Broadwell)" }, { "Value": "Intel Xeon Family" }, { "Value": "Intel Xeon x5570" }, { "Value": "Variable" } ]} |
まとめ
使いこなすには少し慣れが必要そうですが、使いこなすことができればホームページで一つずつ確認するよりすばやく価格を確認できるようになるかもしれませんね!