models

package
v0.9.5 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package models provides models for the application.

Package models provides models for the application.

Package models provides models for the application.

Package models provides models for the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Claims

type Claims struct {
	Id       primitive.ObjectID `json:"id"`
	Username string             `json:"username"`
	jwt.RegisteredClaims
}

Claims is a JWT claims.

type Filter

type Filter struct {
	Field    string
	Operator string
	Value    interface{}
}

Filter is a filter for a query.

type PriceReport added in v0.9.5

type PriceReport struct {
	Product struct {
		Sku string `json:"sku"`
	} `json:"product"`
	Terms struct {
		OnDemand map[string]struct {
			PriceDimensions map[string]struct {
				PricePerUnit struct {
					USD string `json:"USD"`
				} `json:"pricePerUnit"`
			} `json:"priceDimensions"`
		} `json:"OnDemand"`
	} `json:"terms"`
}

type Resource

type Resource struct {
	Id        primitive.ObjectID `json:"id" bson:"_id,omitempty"`
	TeamId    primitive.ObjectID `json:"teamId" bson:"teamId"`
	Name      string             `json:"name" bson:"name"`
	Type      string             `json:"type" bson:"type"`
	Cost      float64            `json:"cost" bson:"cost"`
	Metadata  map[string]string  `json:"metadata" bson:"metadata"`
	Tags      []Tag              `json:"tags" bson:"tags"`
	Link      string             `json:"link" bson:"link"`
	Provider  string             `json:"provider" bson:"provider"`
	Region    string             `json:"region" bson:"region"`
	Account   string             `json:"account" bson:"account"`
	AccountId string             `json:"accountId" bson:"accountId"`
}

Resource is a resource.

type Tag

type Tag struct {
	Key   string `json:"key" bson:"key"`
	Value string `json:"value" bson:"value"`
}

Tag is a tag.

type Team

type Team struct {
	Id      primitive.ObjectID `json:"id" bson:"_id,omitempty"`
	Name    string             `json:"name" bson:"name"`
	OwnerId primitive.ObjectID `json:"owner" bson:"owner"`
}

Team is a team.

type User

type User struct {
	Id       primitive.ObjectID `json:"id" bson:"_id,omitempty"`
	TeamId   primitive.ObjectID `json:"teamId" bson:"teamId"`
	Username string             `json:"username" bson:"username"`
	Email    string             `json:"email" bson:"email"`
	Password string             `json:"password" bson:"password"`
}

User is a user.

Jump to

Keyboard shortcuts

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