account

package
v0.0.0-...-d4762d9 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2018 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateAccount_SignatureStr

func CreateAccount_SignatureStr(address, name, abstract, avatar, account_id, sub_account_id string, created int,
	extra_hash string) (string, *dtcpv1.AccountPost, error)

CreateAccount Signature string value

func GetAccountAvatarRawImage

func GetAccountAvatarRawImage(account_id string) ([]byte, error)

func GetSubAccountAvatarRawImage

func GetSubAccountAvatarRawImage(account_id, sub_account_id string) ([]byte, error)

Types

type AccountAvatarResponse

type AccountAvatarResponse struct {
	core.Response
	Data *dtcpv1.ContentGet `json:"data"`
}

func GetAccountAvatarMetadata

func GetAccountAvatarMetadata(account_id string) (*AccountAvatarResponse, error)

func GetSubAccountAvatarMetadata

func GetSubAccountAvatarMetadata(account_id, sub_account_id string) (*AccountAvatarResponse, error)

type AccountCommentsResponse

type AccountCommentsResponse struct {
	core.Response
	Data []dtcpv1.ContentCommentGet `json:"data"`
}

func GetAccountComments

func GetAccountComments(account_id string, page, pageSize int) (*AccountCommentsResponse, error)

func GetSubAccountComments

func GetSubAccountComments(account_id, sub_account_id string, page, pageSize int) (*AccountCommentsResponse, error)

type AccountContentList

type AccountContentList struct {
	core.Response
	Data []dtcpv1.ContentGet `json:"data"`
}

func GetAccountContentList

func GetAccountContentList(account_id string, page, pageSize int) (*AccountContentList, error)

func GetSubAccountContentList

func GetSubAccountContentList(account_id, sub_account_id string, page, pageSize int) (*AccountContentList, error)

type AccountCredists

type AccountCredists struct {
	UserAccountId string `json:"user_account_id"`
	Score         int    `json:"score"`
}

type AccountCredistsResponse

type AccountCredistsResponse struct {
	core.Response
	Data *AccountCredists `json:"data"`
}

func GetAccountCreditsList

func GetAccountCreditsList(account_id string) (*AccountCredistsResponse, error)

type AccountGroupAppsResponse

type AccountGroupAppsResponse struct {
	core.Response
	Data []dtcpv1.GroupMemberGet `json:"data"`
}

func GetAccountGroupApplications

func GetAccountGroupApplications(account_id string, page, pageSize int) (*AccountGroupAppsResponse, error)

func GetSubAccountGroupApplications

func GetSubAccountGroupApplications(account_id, sub_account_id string, page, pageSize int) (*AccountGroupAppsResponse, error)

type AccountGroupListResponse

type AccountGroupListResponse struct {
	core.Response
	Data []dtcpv1.GroupGet `json:"data"`
}

func GetAccountGroupsList

func GetAccountGroupsList(account_id string, page, pageSize int) (*AccountGroupListResponse, error)

func GetSubAccountGroupsList

func GetSubAccountGroupsList(account_id, sub_account_id string, page, pageSize int) (*AccountGroupListResponse, error)

type AccountJoinedGroupsResponse

type AccountJoinedGroupsResponse struct {
	core.Response
	Data []dtcpv1.GroupGet `json:"data"`
}

func GetAccountJoinedGroups

func GetAccountJoinedGroups(account_id string, page, pageSize int) (*AccountJoinedGroupsResponse, error)

func GetSubAccountJoinedGroups

func GetSubAccountJoinedGroups(account_id, sub_account_id string, page, pageSize int) (*AccountJoinedGroupsResponse, error)

type AccountLikesResponse

type AccountLikesResponse struct {
	core.Response
	Data []dtcpv1.ContentLikeGet `json:"data"`
}

func GetAccountLikes

func GetAccountLikes(account_id string, page, pageSize int) (*AccountLikesResponse, error)

func GetSubAccountLikes

func GetSubAccountLikes(account_id, sub_account_id string, page, pageSize int) (*AccountLikesResponse, error)

type AccountShareAppsResponse

type AccountShareAppsResponse struct {
	core.Response
	Data []dtcpv1.Share `json:"data"`
}

func GetAccountShareApplications

func GetAccountShareApplications(account_id string, page, pageSize int) (*AccountShareAppsResponse, error)

func GetSubAccountShareApplications

func GetSubAccountShareApplications(account_id, sub_account_id string, page, pageSize int) (*AccountShareAppsResponse, error)

type AccountSharesInSingleGroup

type AccountSharesInSingleGroup struct {
	core.Response
	Data []dtcpv1.Share `json:"data"`
}

func GetAccountSharesInSingleGroup

func GetAccountSharesInSingleGroup(account_id, group_id string, page, pageSize int) (*AccountSharesInSingleGroup, error)

func GetSubAccountSharesInSingleGroup

func GetSubAccountSharesInSingleGroup(account_id, sub_account_id, group_id string, page, pageSize int) (*AccountSharesInSingleGroup, error)

type AccountSharesList

type AccountSharesList struct {
	core.Response
	Data []dtcpv1.Share `json:"data"`
}

func GetAccountSharesList

func GetAccountSharesList(account_id string, page, pageSize int) (*AccountSharesList, error)

func GetSubAccountSharesList

func GetSubAccountSharesList(account_id, sub_account_id string, page, pageSize int) (*AccountSharesList, error)

type AddressMetadata

type AddressMetadata struct {
	Id            string                  `json:"id"`                 // Account id.
	Address       string                  `json:"address"`            // Account address.
	Title         string                  `json:"title"`              // Account name.
	Abstract      string                  `json:"abstract,omitempty"` // Description.
	Avatar        string                  `json:"avatar,omitempty"`   // An image id used for avatar.
	Creator       *AddressMetadataCreator `json:"creator"`            // Creator of the sub account.
	Created       int                     `json:"created"`            // Account creation time. Unix timestamp.
	Updated       int                     `json:"updated"`            // Account last updating time. Unix timestamp.
	Extra         *AddressMetadataExtra   `json:"extra,omitempty"`    // Extra metadata.
	Signature     string                  `json:"signature"`          // Metadata signature.
	Dna           string                  `json:"dna"`                // DNA of the account.
	Hp            int                     `json:"hp"`                 // available hp value
	TotalHp       int                     `json:"total_hp"`           // total hp value
	Credits       int                     `json:"credits"`            // Current credits.
	TransactionId string                  `json:"transaction_id"`     // Latest transaction id.
}

type AddressMetadataCreator

type AddressMetadataCreator struct {
	AccountId   string `json:"account_id"`   // Root account id.
	AccountName string `json:"account_name"` // Root account name.
}

type AddressMetadataExtra

type AddressMetadataExtra struct {
	Hash string `json:"hash"` // In the case of proof of existence of secret data. The hash can be filled in this field.
}

type AddressMetadataResponse

type AddressMetadataResponse struct {
	core.Response
	Data *AddressMetadata `json:"data"`
}

func GetAddressMetadata

func GetAddressMetadata(address string) (*AddressMetadataResponse, error)

type CreateAccountResponse

type CreateAccountResponse struct {
	core.Response
	Data *CreateAccountResult `json:"data"`
}

func CreateAccount

func CreateAccount(signature string, preObj *dtcpv1.AccountPost) (*CreateAccountResponse, error)

type CreateAccountResult

type CreateAccountResult struct {
	Id  string `json:"id,omitempty"` // The id of the account. No id is returned for sub accounts.
	Dna string `json:"dna"`          // The DNA of the account.
}

type GetAccountMetadata

type GetAccountMetadata struct {
	Id            string                     `json:"id"`                 // Account id.
	Address       string                     `json:"address"`            // Account address.
	Title         string                     `json:"title"`              // Account name.
	Abstract      string                     `json:"abstract,omitempty"` // Description.
	Avatar        string                     `json:"avatar,omitempty"`   // An image id used for avatar.
	Creator       *GetAccountMetadataCreator `json:"creator"`            // Creator of the sub account.
	Created       int                        `json:"created"`            // Account creation time. Unix timestamp.
	Updated       int                        `json:"updated"`            // Account last updating time. Unix timestamp.
	Extra         *GetAccountMetadataExtra   `json:"extra,omitempty"`    // Extra metadata.
	Signature     string                     `json:"signature"`          // Metadata signature.
	Dna           string                     `json:"dna"`                // DNA of the account.
	Hp            int                        `json:"hp"`                 // available hp value
	TotalHp       int                        `json:"total_hp"`           // total hp value
	Credits       int                        `json:"credits"`            // Current credits.
	TransactionId string                     `json:"transaction_id"`     // Latest transaction id.
}

type GetAccountMetadataCreator

type GetAccountMetadataCreator struct {
	AccountId   string `json:"account_id"`   // Root account id.
	AccountName string `json:"account_name"` // Root account name.
}

type GetAccountMetadataExtra

type GetAccountMetadataExtra struct {
	Hash string `json:"hash"` // In the case of proof of existence of secret data. The hash can be filled in this field.
}

type GetAccountMetadataResponse

type GetAccountMetadataResponse struct {
	core.Response
	Data *GetAccountMetadata `json:"data"`
}

func GetAccountTokenMetadata

func GetAccountTokenMetadata(account_id string) (*GetAccountMetadataResponse, error)

func GetSubAccountTokenMetadata

func GetSubAccountTokenMetadata(account_id, sub_account_id string) (*GetAccountMetadataResponse, error)

type SubAccountCredists

type SubAccountCredists struct {
	UserAccountId string `json:"user_account_id"`
	SubAccountId  string `json:"sub_account_id"`
	Score         int    `json:"score"`
}

type SubAccountCredistsResponse

type SubAccountCredistsResponse struct {
	core.Response
	Data *SubAccountCredists `json:"data"`
}

func GetSubAccountCreditsList

func GetSubAccountCreditsList(account_id, sub_account_id string) (*SubAccountCredistsResponse, error)

Jump to

Keyboard shortcuts

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