AWS boto3 定价的可用过滤器 API - get_products
Available filter for AWS boto3 Pricing API - get_products
我正在尝试获取不同 EC2 实例的定价。我必须指定不同的过滤器才能获得最准确的价格。例如,
import boto3
client = boto3.client('pricing')
response = client.get_products(
ServiceCode='string',
Filters=[
{
'Type': 'TERM_MATCH',
'Field': 'string',
'Value': 'string'
},
],
FormatVersion='string',
NextToken='string',
MaxResults=123
)
我想知道 EC2 实例的所有可用字段和值。我无法找到任何关于此的信息,因此我们将不胜感激。
谢谢大家!
使用方法 describe_services() 和服务代码来获取所有可用的属性。
使用方法get_attribute_values()获取某个属性的所有属性值的列表。
来自同一 API 文档的更多信息,其中描述了 get_products():
https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/pricing.html#pricing
我正在尝试获取不同 EC2 实例的定价。我必须指定不同的过滤器才能获得最准确的价格。例如,
import boto3
client = boto3.client('pricing')
response = client.get_products(
ServiceCode='string',
Filters=[
{
'Type': 'TERM_MATCH',
'Field': 'string',
'Value': 'string'
},
],
FormatVersion='string',
NextToken='string',
MaxResults=123
)
我想知道 EC2 实例的所有可用字段和值。我无法找到任何关于此的信息,因此我们将不胜感激。
谢谢大家!
使用方法 describe_services() 和服务代码来获取所有可用的属性。
使用方法get_attribute_values()获取某个属性的所有属性值的列表。
来自同一 API 文档的更多信息,其中描述了 get_products(): https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/pricing.html#pricing