pricingutil

package
v0.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 23, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

pricingutil provices some helpers for the AWS Pricing API: https://docs.aws.amazon.com/sdk-for-go/api/service/pricing/

pricingutil provices some helpers for the AWS Pricing API: https://docs.aws.amazon.com/sdk-for-go/api/service/pricing/

Index

Constants

View Source
const (
	ServicesInputFormatVersionAWSV1 = "aws_v1"
	DescribeServicesMaxResults      = 100 // values > 100 will return `InvalidParameterException: 1 validation error detected: Value '10000' at 'maxResults' failed to satisfy constraint: Member must have value less than or equal to 100`
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*pricing.Pricing
}

func NewPricingClient

func NewPricingClient(cfg *config.AWSConfig) (*Client, error)

func (*Client) Products

func (c *Client) Products(svcCode string) (Products, error)

func (*Client) Services

func (c *Client) Services() (Services, error)

type Product

type Product struct {
	Attributes    map[string]string `json:"attributes"`
	ProductFamily string            `json:"productFamily"`
	SKU           string            `json:"sku"`
}

type ProductRDS

type ProductRDS struct {
	Product         Product   `json:"product"`
	PublicationDate time.Time `json:"publicationDate"`
	Version         string    `json:"version"`
}

type Products

type Products []aws.JSONValue

type Services

type Services []pricing.Service

func (Services) ServiceCodes

func (svcs Services) ServiceCodes() ([]string, error)

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL