tag

package
v0.9.187 Latest Latest
Warning

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

Go to latest
Published: Aug 19, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

tag.go - the resmanager APIs definition supported by the resmanager service

Index

Constants

View Source
const (
	URI_PREFIX          = bce.URI_PREFIX
	DEFAULT_ENDPOINT    = "tag.baidubce.com"
	URI_TAG_PREFIX      = "v1/tag"
	URI_RESOURCE_PREFIX = "v1/resource"
	URI_QUERY_FULL_LIST = URI_TAG_PREFIX + "/queryFullList"
	URI_TAG_RESOURCES   = URI_TAG_PREFIX + "/tagResources"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*bce.BceClient
}

Client of Group service is a kind of BceClient, so derived from BceClient

func NewClient

func NewClient(ak, sk, endPoint string) (*Client, error)

func (*Client) CreateAndAssign

func (c *Client) CreateAndAssign(args *CreateAndAssignTagRequest) error

CreateAndAssign https://cloud.baidu.com/doc/TAG/s/Wkm1t1xca

func (*Client) CreateAssociationsByTag

func (c *Client) CreateAssociationsByTag(args *CreateAssociationsByTagRequest) error

CreateAssociationsByTag https://cloud.baidu.com/doc/TAG/s/rkm1yqvhz

func (*Client) CreateTags

func (c *Client) CreateTags(args *TagsRequest) error

CreateTags https://cloud.baidu.com/doc/TAG/s/Okbrb3ral

func (*Client) DeleteAssociationsByTag

func (c *Client) DeleteAssociationsByTag(args *DeleteAssociationsByTagRequest) error

DeleteAssociationsByTag https://cloud.baidu.com/doc/TAG/s/7km1zf2j2

func (*Client) DeleteTagAssociation

func (c *Client) DeleteTagAssociation(args *DeleteTagAssociationRequest) error

DeleteTagAssociation https://cloud.baidu.com/doc/TAG/s/wkm1sfady

func (*Client) DeleteTags

func (c *Client) DeleteTags(args *TagsRequest) error

DeleteTags https://cloud.baidu.com/doc/TAG/s/Xkbrb3rhr

func (*Client) QueryFullList

func (c *Client) QueryFullList(strongAssociation bool, args *FullTagListRequest) (*TagAssociationFulls, error)

QueryFullList https://cloud.baidu.com/doc/TAG/s/Ekm1tunjn

func (*Client) TagsResources

func (c *Client) TagsResources(tagKey string, tagValue string, region string, resourceType string) (*TagsAssociationWithResources, error)

TagsResources https://cloud.baidu.com/doc/TAG/s/Bkbrb3roy

func (*Client) UserTagList

func (c *Client) UserTagList(tagKey, tagValue string) (*TagsResult, error)

UserTagList https://cloud.baidu.com/doc/TAG/s/Ukbrb3r3d

type CreateAndAssignTagRequest

type CreateAndAssignTagRequest struct {
	ResourceWithTag []ResourceWithTag `json:"resources"`
}

type CreateAssociationsByTagRequest

type CreateAssociationsByTagRequest struct {
	TagKey      string     `json:"tagKey"`
	TagValue    string     `json:"tagValue"`
	ServiceType string     `json:"serviceType"`
	Resource    []Resource `json:"resources"`
}

type DeleteAssociationsByTagRequest

type DeleteAssociationsByTagRequest struct {
	TagKey      string     `json:"tagKey"`
	TagValue    string     `json:"tagValue"`
	ServiceType string     `json:"serviceType"`
	Resource    []Resource `json:"resources"`
}

type DeleteTagAssociationRequest

type DeleteTagAssociationRequest struct {
	Resource *Resource `json:"resource"`
}

type FullTagListRequest

type FullTagListRequest struct {
	TagKey       string   `json:"tagKey,omitempty"`
	TagValue     string   `json:"tagValue,omitempty"`
	Regions      []string `json:"regions,omitempty"`
	ServiceTypes []string `json:"serviceTypes,omitempty"`
	ResourceIds  []string `json:"resourceIds,omitempty"`
}

type Resource

type Resource struct {
	ResourceId  string `json:"resourceId"`
	ServiceType string `json:"serviceType"`
	Region      string `json:"region"`
}

type ResourceWithTag

type ResourceWithTag struct {
	ResourceId      string `json:"resourceId"`
	ResourceUuid    string `json:"resourceUuid"`
	ServiceType     string `json:"serviceType"`
	Region          string `json:"region"`
	Tags            []Tag  `json:"tags"`
	AssociationType string `json:"associationType"`
}

type Tag

type Tag struct {
	TagKey   string `json:"tagKey"`
	TagValue string `json:"tagValue"`
}

type TagAssociation

type TagAssociation struct {
	AccountId    string `json:"accountId"`
	ResourceId   string `json:"resourceId"`
	ResourceUuid string `json:"resourceUuid"`
	Region       string `json:"region"`
	ServiceType  string `json:"serviceType"`
	TagId        int64  `json:"tagId"`
}

type TagAssociationFull

type TagAssociationFull struct {
	TagAssociation
	TagKey          string `json:"tagKey"`
	TagValue        string `json:"tagValue"`
	AssociationType int    `json:"associationType"`
}

type TagAssociationFulls

type TagAssociationFulls struct {
	TagAssociationFull []TagAssociationFull `json:"tagAssociationFulls"`
}

type TagAssociationWithResources

type TagAssociationWithResources struct {
	Tag
	Resources []TagResource `json:"resources"`
}

type TagResource

type TagResource struct {
	ResourceType string `json:"resourceType"`
	ResourceId   string `json:"resourceId"`
	Region       string `json:"region"`
}

type TagsAssociationWithResources

type TagsAssociationWithResources struct {
	TagResources []TagAssociationWithResources `json:"tagResources"`
}

type TagsRequest

type TagsRequest struct {
	Tags []Tag `json:"tags"`
}

type TagsResult

type TagsResult struct {
	Tags []Tag `json:"tags"`
}

Jump to

Keyboard shortcuts

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