reports

package
v0.0.0-...-ff628f3 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	ClientId string `json:"client_id,omitempty"`
	EntityId string `json:"entity_id,omitempty"`
}

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(configuration *configuration.Configuration, apiClient client.HttpClient) *Client

func (*Client) GetAllReports

func (c *Client) GetAllReports(query QueryFilter) (*QueryResponse, error)

func (*Client) GetReportDetails

func (c *Client) GetReportDetails(reportId string) (*ReportResponse, error)

func (*Client) GetReportFile

func (c *Client) GetReportFile(reportId, fileId string) (*common.ContentResponse, error)

type File

type File struct {
	Id       string                 `json:"id,omitempty"`
	Filename string                 `json:"filename,omitempty"`
	Format   string                 `json:"format,omitempty"`
	Links    map[string]common.Link `json:"_links"`
}

type QueryFilter

type QueryFilter struct {
	CreatedAfter    *time.Time `url:"created_after,omitempty" layout:"2006-01-02"`
	CreatedBefore   *time.Time `url:"created_before,omitempty" layout:"2006-01-02"`
	EntityId        string     `url:"entity_id,omitempty"`
	Limit           int        `url:"limit,omitempty"`
	PaginationToken string     `url:"pagination_token,omitempty"`
}

type QueryResponse

type QueryResponse struct {
	HttpMetadata common.HttpMetadata
	Count        int                    `json:"count,omitempty"`
	Limit        uint8                  `json:"limit,omitempty"`
	Data         []ReportResponse       `json:"data,omitempty"`
	Links        map[string]common.Link `json:"_links"`
}

type ReportResponse

type ReportResponse struct {
	HttpMetadata   common.HttpMetadata
	Id             string                 `json:"id,omitempty"`
	CreatedOn      string                 `json:"created_on,omitempty"`
	LastModifiedOn string                 `json:"last_modified_on,omitempty"`
	Type           string                 `json:"type,omitempty"`
	Description    string                 `json:"description,omitempty"`
	Account        *Account               `json:"account,omitempty"`
	Tags           []string               `json:"tags,omitempty"`
	From           *time.Time             `json:"from,omitempty"`
	To             *time.Time             `json:"to,omitempty"`
	Files          []File                 `json:"files,omitempty"`
	Links          map[string]common.Link `json:"_links"`
}

Jump to

Keyboard shortcuts

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