reports

package
v0.20240903.1131440 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: MPL-2.0 Imports: 12 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2023-05-01-preview/reports Documentation

The reports SDK allows for interaction with the Azure Resource Manager Service apimanagement (API Version 2023-05-01-preview).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2023-05-01-preview/reports"

Client Initialization

client := reports.NewReportsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ReportsClient.ListByApi

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByApi(ctx, id, reports.DefaultListByApiOperationOptions())` can be used to do batched pagination
items, err := client.ListByApiComplete(ctx, id, reports.DefaultListByApiOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByGeo

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByGeo(ctx, id, reports.DefaultListByGeoOperationOptions())` can be used to do batched pagination
items, err := client.ListByGeoComplete(ctx, id, reports.DefaultListByGeoOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByOperation

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByOperation(ctx, id, reports.DefaultListByOperationOperationOptions())` can be used to do batched pagination
items, err := client.ListByOperationComplete(ctx, id, reports.DefaultListByOperationOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByProduct

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByProduct(ctx, id, reports.DefaultListByProductOperationOptions())` can be used to do batched pagination
items, err := client.ListByProductComplete(ctx, id, reports.DefaultListByProductOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByRequest

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

read, err := client.ListByRequest(ctx, id, reports.DefaultListByRequestOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: ReportsClient.ListBySubscription

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListBySubscription(ctx, id, reports.DefaultListBySubscriptionOperationOptions())` can be used to do batched pagination
items, err := client.ListBySubscriptionComplete(ctx, id, reports.DefaultListBySubscriptionOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByTime

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByTime(ctx, id, reports.DefaultListByTimeOperationOptions())` can be used to do batched pagination
items, err := client.ListByTimeComplete(ctx, id, reports.DefaultListByTimeOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ReportsClient.ListByUser

ctx := context.TODO()
id := reports.NewServiceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue")

// alternatively `client.ListByUser(ctx, id, reports.DefaultListByUserOperationOptions())` can be used to do batched pagination
items, err := client.ListByUserComplete(ctx, id, reports.DefaultListByUserOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateServiceID

func ValidateServiceID(input interface{}, key string) (warnings []string, errors []error)

ValidateServiceID checks that 'input' can be parsed as a Service ID

Types

type ListByApiCompleteResult

type ListByApiCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByApiCustomPager added in v0.20240628.1153531

type ListByApiCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByApiCustomPager) NextPageLink() *odata.Link

type ListByApiOperationOptions

type ListByApiOperationOptions struct {
	Filter  *string
	Orderby *string
	Skip    *int64
	Top     *int64
}

func DefaultListByApiOperationOptions

func DefaultListByApiOperationOptions() ListByApiOperationOptions

func (ListByApiOperationOptions) ToHeaders

func (o ListByApiOperationOptions) ToHeaders() *client.Headers

func (ListByApiOperationOptions) ToOData

func (o ListByApiOperationOptions) ToOData() *odata.Query

func (ListByApiOperationOptions) ToQuery

type ListByApiOperationResponse

type ListByApiOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByGeoCompleteResult

type ListByGeoCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByGeoCustomPager added in v0.20240628.1153531

type ListByGeoCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByGeoCustomPager) NextPageLink() *odata.Link

type ListByGeoOperationOptions

type ListByGeoOperationOptions struct {
	Filter *string
	Skip   *int64
	Top    *int64
}

func DefaultListByGeoOperationOptions

func DefaultListByGeoOperationOptions() ListByGeoOperationOptions

func (ListByGeoOperationOptions) ToHeaders

func (o ListByGeoOperationOptions) ToHeaders() *client.Headers

func (ListByGeoOperationOptions) ToOData

func (o ListByGeoOperationOptions) ToOData() *odata.Query

func (ListByGeoOperationOptions) ToQuery

type ListByGeoOperationResponse

type ListByGeoOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByOperationCompleteResult

type ListByOperationCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByOperationCustomPager added in v0.20240628.1153531

type ListByOperationCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByOperationCustomPager) NextPageLink() *odata.Link

type ListByOperationOperationOptions

type ListByOperationOperationOptions struct {
	Filter  *string
	Orderby *string
	Skip    *int64
	Top     *int64
}

func DefaultListByOperationOperationOptions

func DefaultListByOperationOperationOptions() ListByOperationOperationOptions

func (ListByOperationOperationOptions) ToHeaders

func (ListByOperationOperationOptions) ToOData

func (ListByOperationOperationOptions) ToQuery

type ListByOperationOperationResponse

type ListByOperationOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByProductCompleteResult

type ListByProductCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByProductCustomPager added in v0.20240628.1153531

type ListByProductCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByProductCustomPager) NextPageLink() *odata.Link

type ListByProductOperationOptions

type ListByProductOperationOptions struct {
	Filter  *string
	Orderby *string
	Skip    *int64
	Top     *int64
}

func DefaultListByProductOperationOptions

func DefaultListByProductOperationOptions() ListByProductOperationOptions

func (ListByProductOperationOptions) ToHeaders

func (ListByProductOperationOptions) ToOData

func (ListByProductOperationOptions) ToQuery

type ListByProductOperationResponse

type ListByProductOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByRequestOperationOptions

type ListByRequestOperationOptions struct {
	Filter *string
	Skip   *int64
	Top    *int64
}

func DefaultListByRequestOperationOptions

func DefaultListByRequestOperationOptions() ListByRequestOperationOptions

func (ListByRequestOperationOptions) ToHeaders

func (ListByRequestOperationOptions) ToOData

func (ListByRequestOperationOptions) ToQuery

type ListByRequestOperationResponse

type ListByRequestOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *RequestReportCollection
}

type ListBySubscriptionCompleteResult

type ListBySubscriptionCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListBySubscriptionCustomPager added in v0.20240628.1153531

type ListBySubscriptionCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListBySubscriptionCustomPager) NextPageLink() *odata.Link

type ListBySubscriptionOperationOptions

type ListBySubscriptionOperationOptions struct {
	Filter  *string
	Orderby *string
	Skip    *int64
	Top     *int64
}

func DefaultListBySubscriptionOperationOptions

func DefaultListBySubscriptionOperationOptions() ListBySubscriptionOperationOptions

func (ListBySubscriptionOperationOptions) ToHeaders

func (ListBySubscriptionOperationOptions) ToOData

func (ListBySubscriptionOperationOptions) ToQuery

type ListBySubscriptionOperationResponse

type ListBySubscriptionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByTimeCompleteResult

type ListByTimeCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByTimeCustomPager added in v0.20240628.1153531

type ListByTimeCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByTimeCustomPager) NextPageLink() *odata.Link

type ListByTimeOperationOptions

type ListByTimeOperationOptions struct {
	Filter   *string
	Interval *string
	Orderby  *string
	Skip     *int64
	Top      *int64
}

func DefaultListByTimeOperationOptions

func DefaultListByTimeOperationOptions() ListByTimeOperationOptions

func (ListByTimeOperationOptions) ToHeaders

func (o ListByTimeOperationOptions) ToHeaders() *client.Headers

func (ListByTimeOperationOptions) ToOData

func (o ListByTimeOperationOptions) ToOData() *odata.Query

func (ListByTimeOperationOptions) ToQuery

type ListByTimeOperationResponse

type ListByTimeOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ListByUserCompleteResult

type ListByUserCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []ReportRecordContract
}

type ListByUserCustomPager added in v0.20240628.1153531

type ListByUserCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByUserCustomPager) NextPageLink() *odata.Link

type ListByUserOperationOptions

type ListByUserOperationOptions struct {
	Filter  *string
	Orderby *string
	Skip    *int64
	Top     *int64
}

func DefaultListByUserOperationOptions

func DefaultListByUserOperationOptions() ListByUserOperationOptions

func (ListByUserOperationOptions) ToHeaders

func (o ListByUserOperationOptions) ToHeaders() *client.Headers

func (ListByUserOperationOptions) ToOData

func (o ListByUserOperationOptions) ToOData() *odata.Query

func (ListByUserOperationOptions) ToQuery

type ListByUserOperationResponse

type ListByUserOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]ReportRecordContract
}

type ReportRecordContract

type ReportRecordContract struct {
	ApiId            *string  `json:"apiId,omitempty"`
	ApiRegion        *string  `json:"apiRegion,omitempty"`
	ApiTimeAvg       *float64 `json:"apiTimeAvg,omitempty"`
	ApiTimeMax       *float64 `json:"apiTimeMax,omitempty"`
	ApiTimeMin       *float64 `json:"apiTimeMin,omitempty"`
	Bandwidth        *int64   `json:"bandwidth,omitempty"`
	CacheHitCount    *int64   `json:"cacheHitCount,omitempty"`
	CacheMissCount   *int64   `json:"cacheMissCount,omitempty"`
	CallCountBlocked *int64   `json:"callCountBlocked,omitempty"`
	CallCountFailed  *int64   `json:"callCountFailed,omitempty"`
	CallCountOther   *int64   `json:"callCountOther,omitempty"`
	CallCountSuccess *int64   `json:"callCountSuccess,omitempty"`
	CallCountTotal   *int64   `json:"callCountTotal,omitempty"`
	Country          *string  `json:"country,omitempty"`
	Interval         *string  `json:"interval,omitempty"`
	Name             *string  `json:"name,omitempty"`
	OperationId      *string  `json:"operationId,omitempty"`
	ProductId        *string  `json:"productId,omitempty"`
	Region           *string  `json:"region,omitempty"`
	ServiceTimeAvg   *float64 `json:"serviceTimeAvg,omitempty"`
	ServiceTimeMax   *float64 `json:"serviceTimeMax,omitempty"`
	ServiceTimeMin   *float64 `json:"serviceTimeMin,omitempty"`
	SubscriptionId   *string  `json:"subscriptionId,omitempty"`
	Timestamp        *string  `json:"timestamp,omitempty"`
	UserId           *string  `json:"userId,omitempty"`
	Zip              *string  `json:"zip,omitempty"`
}

func (*ReportRecordContract) GetTimestampAsTime

func (o *ReportRecordContract) GetTimestampAsTime() (*time.Time, error)

func (*ReportRecordContract) SetTimestampAsTime

func (o *ReportRecordContract) SetTimestampAsTime(input time.Time)

type ReportRecordContractOperationPredicate

type ReportRecordContractOperationPredicate struct {
	ApiId            *string
	ApiRegion        *string
	ApiTimeAvg       *float64
	ApiTimeMax       *float64
	ApiTimeMin       *float64
	Bandwidth        *int64
	CacheHitCount    *int64
	CacheMissCount   *int64
	CallCountBlocked *int64
	CallCountFailed  *int64
	CallCountOther   *int64
	CallCountSuccess *int64
	CallCountTotal   *int64
	Country          *string
	Interval         *string
	Name             *string
	OperationId      *string
	ProductId        *string
	Region           *string
	ServiceTimeAvg   *float64
	ServiceTimeMax   *float64
	ServiceTimeMin   *float64
	SubscriptionId   *string
	Timestamp        *string
	UserId           *string
	Zip              *string
}

func (ReportRecordContractOperationPredicate) Matches

type ReportsClient

type ReportsClient struct {
	Client *resourcemanager.Client
}

func NewReportsClientWithBaseURI

func NewReportsClientWithBaseURI(sdkApi sdkEnv.Api) (*ReportsClient, error)

func (ReportsClient) ListByApi

ListByApi ...

func (ReportsClient) ListByApiComplete

ListByApiComplete retrieves all the results into a single object

func (ReportsClient) ListByApiCompleteMatchingPredicate

func (c ReportsClient) ListByApiCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByApiOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByApiCompleteResult, err error)

ListByApiCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByGeo

ListByGeo ...

func (ReportsClient) ListByGeoComplete

ListByGeoComplete retrieves all the results into a single object

func (ReportsClient) ListByGeoCompleteMatchingPredicate

func (c ReportsClient) ListByGeoCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByGeoOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByGeoCompleteResult, err error)

ListByGeoCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByOperation

ListByOperation ...

func (ReportsClient) ListByOperationComplete

ListByOperationComplete retrieves all the results into a single object

func (ReportsClient) ListByOperationCompleteMatchingPredicate

func (c ReportsClient) ListByOperationCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByOperationOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByOperationCompleteResult, err error)

ListByOperationCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByProduct

ListByProduct ...

func (ReportsClient) ListByProductComplete

ListByProductComplete retrieves all the results into a single object

func (ReportsClient) ListByProductCompleteMatchingPredicate

func (c ReportsClient) ListByProductCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByProductOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByProductCompleteResult, err error)

ListByProductCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByRequest

ListByRequest ...

func (ReportsClient) ListBySubscription

ListBySubscription ...

func (ReportsClient) ListBySubscriptionComplete

ListBySubscriptionComplete retrieves all the results into a single object

func (ReportsClient) ListBySubscriptionCompleteMatchingPredicate

func (c ReportsClient) ListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListBySubscriptionOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListBySubscriptionCompleteResult, err error)

ListBySubscriptionCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByTime

ListByTime ...

func (ReportsClient) ListByTimeComplete

ListByTimeComplete retrieves all the results into a single object

func (ReportsClient) ListByTimeCompleteMatchingPredicate

func (c ReportsClient) ListByTimeCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByTimeOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByTimeCompleteResult, err error)

ListByTimeCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (ReportsClient) ListByUser

ListByUser ...

func (ReportsClient) ListByUserComplete

ListByUserComplete retrieves all the results into a single object

func (ReportsClient) ListByUserCompleteMatchingPredicate

func (c ReportsClient) ListByUserCompleteMatchingPredicate(ctx context.Context, id ServiceId, options ListByUserOperationOptions, predicate ReportRecordContractOperationPredicate) (result ListByUserCompleteResult, err error)

ListByUserCompleteMatchingPredicate retrieves all the results and then applies the predicate

type RequestReportCollection

type RequestReportCollection struct {
	Count *int64                         `json:"count,omitempty"`
	Value *[]RequestReportRecordContract `json:"value,omitempty"`
}

type RequestReportRecordContract

type RequestReportRecordContract struct {
	ApiId               *string  `json:"apiId,omitempty"`
	ApiRegion           *string  `json:"apiRegion,omitempty"`
	ApiTime             *float64 `json:"apiTime,omitempty"`
	BackendResponseCode *string  `json:"backendResponseCode,omitempty"`
	Cache               *string  `json:"cache,omitempty"`
	IPAddress           *string  `json:"ipAddress,omitempty"`
	Method              *string  `json:"method,omitempty"`
	OperationId         *string  `json:"operationId,omitempty"`
	ProductId           *string  `json:"productId,omitempty"`
	RequestId           *string  `json:"requestId,omitempty"`
	RequestSize         *int64   `json:"requestSize,omitempty"`
	ResponseCode        *int64   `json:"responseCode,omitempty"`
	ResponseSize        *int64   `json:"responseSize,omitempty"`
	ServiceTime         *float64 `json:"serviceTime,omitempty"`
	SubscriptionId      *string  `json:"subscriptionId,omitempty"`
	Timestamp           *string  `json:"timestamp,omitempty"`
	Url                 *string  `json:"url,omitempty"`
	UserId              *string  `json:"userId,omitempty"`
}

func (*RequestReportRecordContract) GetTimestampAsTime

func (o *RequestReportRecordContract) GetTimestampAsTime() (*time.Time, error)

func (*RequestReportRecordContract) SetTimestampAsTime

func (o *RequestReportRecordContract) SetTimestampAsTime(input time.Time)

type ServiceId

type ServiceId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
}

ServiceId is a struct representing the Resource ID for a Service

func NewServiceID

func NewServiceID(subscriptionId string, resourceGroupName string, serviceName string) ServiceId

NewServiceID returns a new ServiceId struct

func ParseServiceID

func ParseServiceID(input string) (*ServiceId, error)

ParseServiceID parses 'input' into a ServiceId

func ParseServiceIDInsensitively

func ParseServiceIDInsensitively(input string) (*ServiceId, error)

ParseServiceIDInsensitively parses 'input' case-insensitively into a ServiceId note: this method should only be used for API response data and not user input

func (*ServiceId) FromParseResult

func (id *ServiceId) FromParseResult(input resourceids.ParseResult) error

func (ServiceId) ID

func (id ServiceId) ID() string

ID returns the formatted Service ID

func (ServiceId) Segments

func (id ServiceId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Service ID

func (ServiceId) String

func (id ServiceId) String() string

String returns a human-readable description of this Service ID

Jump to

Keyboard shortcuts

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