Documentation ¶
Index ¶
- Constants
- func HashValue(value []byte) string
- func NewDna(signature string) (string, error)
- func NewId(Dna string) (string, error)
- type AccountGet
- type AccountGetCreator
- type AccountGetExtra
- type AccountPost
- type AccountPostCreator
- type AccountPostExtra
- type AccountPut
- type AccountPutCreator
- type AccountPutExtra
- type ContentCommentGet
- type ContentCommentGetCreator
- type ContentCommentGetExtra
- type ContentCommentPost
- type ContentCommentPostCreator
- type ContentCommentPostExtra
- type ContentCommentPut
- type ContentCommentPutCreator
- type ContentCommentPutExtra
- type ContentGet
- type ContentGetCreator
- type ContentGetExtra
- type ContentGetExtraObject
- type ContentGetExtraObjects
- type ContentLikeDelete
- type ContentLikeGet
- type ContentLikeGetCreator
- type ContentLikePost
- type ContentLikePostCreator
- type ContentPost
- type ContentPostCreator
- type ContentPut
- type ContentReportGet
- type ContentReportGetCreator
- type ContentReportGetExtra
- type ContentReportPost
- type ContentReportPostCreator
- type ContentReportPostExtra
- type GroupGet
- type GroupGetCreator
- type GroupGetExtra
- type GroupMemberAppPostCreator
- type GroupMemberAppPostExtra
- type GroupMemberAppPutCreator
- type GroupMemberAppPutExtra
- type GroupMemberApplicationPost
- type GroupMemberApplicationPut
- type GroupMemberDelete
- type GroupMemberDeleteCreator
- type GroupMemberGet
- type GroupMemberGetCreator
- type GroupMemberGetExtra
- type GroupMemberPost
- type GroupMemberPostCreator
- type GroupMemberPostExtra
- type GroupMemberPut
- type GroupMemberPutCreator
- type GroupMemberPutExtra
- type GroupMemberWhiteGetCreator
- type GroupMemberWhiteGetExtra
- type GroupMemberWhitePostCreator
- type GroupMemberWhitePostExtra
- type GroupMemberWhitePutCreator
- type GroupMemberWhitePutExtra
- type GroupMemberWhitelistDelete
- type GroupMemberWhitelistDeleteCreator
- type GroupMemberWhitelistGet
- type GroupMemberWhitelistPost
- type GroupMemberWhitelistPut
- type GroupPost
- type GroupPostCreator
- type GroupPostExtra
- type GroupPut
- type GroupPutExtra
- type GroupShareAppPut
- type GroupShareAppPutCreator
- type GroupShareAppPutExtra
- type GroupShareDelete
- type GroupShareDeleteCreator
- type GroupSharePost
- type GroupSharePostCreator
- type GroupSharePostExtra
- type License
- type LicensePrice
- type LicenseSubject
- func NewLicenseCommercial(value string) *LicenseSubject
- func NewLicenseCommercial_n(value string) *LicenseSubject
- func NewLicenseCommercial_y() *LicenseSubject
- func NewLicenseDerivative(value string) *LicenseSubject
- func NewLicenseDerivative_n() *LicenseSubject
- func NewLicenseDerivative_sa() *LicenseSubject
- func NewLicenseDerivative_y() *LicenseSubject
- type Share
- type ShareCreator
- type ShareExtra
- type SystemParametersGet
Constants ¶
View Source
const ( CONST_DTCP_Version_v1 = "1.0" CONST_DTCP_Type_Object = "object" CONST_DTCP_Type_Relation = "relation" CONST_DTCP_Status_Created = "created" CONST_DTCP_Status_Updated = "updated" CONST_DTCP_Status_Deleted = "deleted" CONST_DTCP_Tag_Account = "account" CONST_DTCP_Tag_Group = "group" CONST_DTCP_Tag_Group_member = "group_member" CONST_DTCP_Tag_Group_member_whitelist = "group_member_whitelist" CONST_DTCP_Tag_Article = "article" CONST_DTCP_Tag_Image = "image" CONST_DTCP_ApplicationStatus_Pending = "pending" CONST_DTCP_ApplicationStatus_Approved = "approved" CONST_DTCP_ApplicationStatus_Declined = "declined" CONST_DTCP_Group_AllowJoin_Type_all = "all" CONST_DTCP_Group_AllowJoin_Type_application = "application" CONST_DTCP_Group_AllowPost_Type_all = "all" CONST_DTCP_Group_AllowPost_Type_none = "none" CONST_DTCP_Group_AllowPost_Type_application = "application" CONST_DTCP_Group_AccountRole_Type_Owner = "owner" CONST_DTCP_Group_AccountRole_Type_Member = "member" CONST_DTCP_Group_AccountRole_Type_Applicant = "applicant" CONST_DTCP_Group_AccountRole_Type_None = "none" CONST_DTCP_Image_Type_Image = "image" CONST_DTCP_Image_Type_Audio = "audio" CONST_DTCP_Image_Type_Video = "video" )
View Source
const ( // License_Fields_Derivation = "derivation" License_Fields_Commercial = "commercial" // Whether Derivation is allowed. License_Derivative_y = "y" License_Derivative_n = "n" License_Derivative_sa = "sa" // for share-alike // Whether commercial usage is allowed License_Commercial_y = "y" License_Commercial_n = "n" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AccountGet ¶
type AccountGet 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 *AccountGetCreator `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 *AccountGetExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature"` // Metadata signature. Dna string `json:"dna"` // DNA of the account. Credits int `json:"credits"` // Current credits. TransactionId string `json:"transaction_id"` // Latest transaction id. }
get
type AccountGetCreator ¶
type AccountGetExtra ¶
type AccountGetExtra struct {
Hash string `json:"hash"` // In the case of proof of existence of secret data. The hash can be filled in this field.
}
type AccountPost ¶
type AccountPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Fixed to "account". Name string `json:"name"` // Name. Address string `json:"address"` Abstract string `json:"abstract,omitempty"` // Description. Avatar string `json:"avatar,omitempty"` // An image id used for avatar. Creator *AccountPostCreator `json:"creator,omitempty"` // Creator. Required when creating sub account. Created int `json:"created"` // Account creation time. Unix timestamp. Extra *AccountPostExtra `json:"extra,omitempty"` // Extra metadata. Status string `json:"status"` // Fixed to "created". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewAccountPost ¶
func NewAccountPost() *AccountPost
type AccountPostCreator ¶
type AccountPostExtra ¶
type AccountPostExtra struct {
Hash string `json:"hash"`
}
type AccountPut ¶
type AccountPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Fixed to "account". ParentDna string `json:"parent_dna"` // The latest DNA of the account Updated int `json:"creaupdatedted"` // Updating time. Unix timestamp. Name string `json:"name"` // Name. Abstract string `json:"abstract,omitempty"` // Description. Avatar string `json:"avatar,omitempty"` // An image id used for avatar. Creator *AccountPutCreator `json:"creator,omitempty"` // Creator. Required when creating sub account. Extra *AccountPutExtra `json:"extra,omitempty"` // Extra metadata. Status string `json:"status"` // Fixed to "updated". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewAccountPut ¶
func NewAccountPut() *AccountPut
type AccountPutCreator ¶
type AccountPutExtra ¶
type AccountPutExtra struct {
Hash string `json:"hash"`
}
type ContentCommentGet ¶
type ContentCommentGet struct { Id string `json:"id"` // Comment id. SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Hp int `json:"hp"` // hp value Creator *ContentCommentGetCreator `json:"creator"` // Creator. Created int `json:"created"` // Comment created time. Unix timestamp. Updated int `json:"updated"` // Comment created time. Unix timestamp. Extra *ContentCommentGetExtra `json:"extra"` // Extra metadata. Signature string `json:"signature"` // Metadata signature. TransactionId string `json:"transaction_id"` // Latest transaction id. }
Get
type ContentCommentGetCreator ¶
type ContentCommentGetCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. AccountName string `json:"account_name"` // Account name. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. }
type ContentCommentGetExtra ¶
type ContentCommentGetExtra struct { Content string `json:"content"` // Comment content. Comments []ContentCommentGet `json:"comments"` // Replying comments overview. }
type ContentCommentPost ¶
type ContentCommentPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0" Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_comment". SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Hp int `json:"hp"` // hp value Creator *ContentCommentPostCreator `json:"creator"` // Creator. Created int `json:"created"` // Comment created time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Extra *ContentCommentPostExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentCommentPost ¶
func NewContentCommentPost() *ContentCommentPost
type ContentCommentPostCreator ¶
type ContentCommentPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type ContentCommentPostExtra ¶
type ContentCommentPut ¶
type ContentCommentPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_comment". ParentDna string `json:"parent_dna"` // Latest comment DNA. Creator *ContentCommentPutCreator `json:"creator"` // Creator. Updated int `json:"updated"` // Comment updated time. Unix timestamp. Status string `json:"status"` // Fixed to "updated". Extra *ContentCommentPutExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentCommentPut ¶
func NewContentCommentPut() *ContentCommentPut
type ContentCommentPutExtra ¶
type ContentGet ¶
type ContentGet struct { Id string `json:"id"` // Content id. Tag string `json:"tag"` // Content tag. Currently "article", "image" are supported. Title string `json:"title"` // Content title. Creator *ContentGetCreator `json:"creator"` // Creator of the content. Abstract string `json:"abstract"` // Content abstract. Language string `json:"language"` // Content language. RFC4646 defined locales such as "en-US" Category string `json:"category"` // Content categories. Comma separated words list. Created int `json:"created"` // Content creation time. Unix timestamp. Updated int `json:"updated"` // Content last updating time. Unix timestamp. Content string `json:"content"` // Content URI. In the case of IPFS, a link starts with "ipfs://" ContentHash string `json:"content_hash"` // Lowercase hex string of the SHA256 hash of the raw content. License *License `json:"license,omitempty"` // Content authorization license. Signature string `json:"signature"` // Metadata signature. Dna string `json:"dna"` // Content DNA. Extra *ContentGetExtra `json:"extra"` // Extra content metadata. TransactionId string `json:"transaction_id"` // Transaction id. }
Get
type ContentGetCreator ¶
type ContentGetCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. AccountName string `json:"account_name"` // Account name. Root account name in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. }
type ContentGetExtra ¶
type ContentGetExtra struct { Ext string `json:"ext,omitempty"` // Image format, such as 'png', 'jpg'. Image only. Width int `json:"width,omitempty"` // Image width in pixels. Image only. Height int `json:"height,omitempty"` // Image height in pixels. Image only. Size int `json:"size,omitempty"` // Image size in bytes. Image only. PstTotal decimal.Decimal `json:"pst_total"` // Total PST earned. PstUpdated int `json:"pst_updated"` // Last PST updated time. Unix timestamp. Objects []ContentGetExtraObjects `json:"objects,omitempty"` // A list of images, videos, audios contained in the content. Article only. }
type ContentGetExtraObject ¶
type ContentGetExtraObject struct { Ext string `json:"ext,omitempty"` // Image format, such as 'png', 'jpg'. Image only. Width int `json:"width,omitempty"` // Image width in pixels. Image only. Height int `json:"height,omitempty"` // Image height in pixels. Image only. Size int `json:"size,omitempty"` // Image size in bytes. Image only. }
type ContentGetExtraObjects ¶
type ContentGetExtraObjects struct { Id string `json:"id"` // Object id. Atype string `json:"type"` // "image", "audio" or "video". Extra *ContentGetExtraObject `json:"extra"` // Extra metadata. }
type ContentLikeDelete ¶
type ContentLikeDelete struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_like". ParentDna string `json:"parent_dna"` // Latest DNA of the like. Updated int `json:"updated"` // Like updated time. Unix timestamp. Status string `json:"status"` // Fixed to "deleted". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentLikeDelete ¶
func NewContentLikeDelete() *ContentLikeDelete
type ContentLikeGet ¶
type ContentLikeGet struct { Id string `json:"id"` // Like id. SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Hp int `json:"hp"` // hp value. Creator *ContentLikeGetCreator `json:"creator"` // Creator. Created int `json:"created"` // Like created time. Unix timestamp. Updated int `json:"updated"` // Like updated time. Unix timestamp. Dna string `json:"dna"` // Like DNA. Signature string `json:"signature"` // Metadata signature. TransactionId string `json:"transaction_id"` // Latest transaction id. }
Get
type ContentLikeGetCreator ¶
type ContentLikeGetCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. AccountName string `json:"account_name"` // Account name. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. }
type ContentLikePost ¶
type ContentLikePost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_like". SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Hp int `json:"hp"` // hp value. Greater than or equal to zero. Creator *ContentLikePostCreator `json:"creator"` // Creator. Created int `json:"created"` // Like created time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentLikePost ¶
func NewContentLikePost() *ContentLikePost
type ContentLikePostCreator ¶
type ContentLikePostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type ContentPost ¶
type ContentPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Content type. Currently "article", "image" are supported. Title string `json:"title"` // Content title. Creator *ContentPostCreator `json:"creator"` // Creator. Abstract string `json:"abstract"` // Content abstract. Language string `json:"language"` // Content language. RFC4646 defined locales such as "en-US" Category string `json:"category"` // Content categories. Comma separated words list. Created int `json:"created"` // Content creation time. Unix timestamp. Content string `json:"content"` // Raw content in base64 encoded format. ContentHash string `json:"content_hash"` // Lowercase hex string of the SHA256 hash of the raw content. License *License `json:"license,omitempty"` // Content authorization license. "none" is used if empty. Status string `json:"status"` // Fixed to "created". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentPost_Aritcle ¶
func NewContentPost_Aritcle() *ContentPost
func NewContentPost_Image ¶
func NewContentPost_Image() *ContentPost
type ContentPostCreator ¶
type ContentPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type ContentPut ¶
type ContentPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Content type. Currently "article", "image" are supported. ParentDna string `json:"parent_dna"` // Latest DNA of the content. Status string `json:"status"` // Fixed to "updated". Updated int `json:"updated"` // Content updating time. Unix timestamp. Title string `json:"title"` // Content title. Abstract string `json:"abstract"` // Content abstract. Category string `json:"category"` // Content categories. Comma separated words list. Content string `json:"content"` // Raw content in base64 encoded format. ContentHash string `json:"content_hash"` // Lowercase hex string of the SHA256 hash of the raw content. License *License `json:"license"` // Content authorization license. "none" is used if empty. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentPut_Aritcle ¶
func NewContentPut_Aritcle() *ContentPut
func NewContentPut_Iamge ¶
func NewContentPut_Iamge() *ContentPut
type ContentReportGet ¶
type ContentReportGet struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_report". SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Creator *ContentReportGetCreator `json:"creator"` // Creator. Created int `json:"created"` // Report created time. Unix timestamp. Updated int `json:"updated"` //Report updated time. Unix timestamp. Extra *ContentReportGetExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. TransactionId string `json:"transaction_id"` // Latest transaction id. }
Get
type ContentReportGetCreator ¶
type ContentReportGetCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. AccountName string `json:"account_name"` // Account name. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type ContentReportGetExtra ¶
type ContentReportGetExtra struct { Content string `json:"content"` // base64 encoded report content. ContentHash string `json:"content_hash"` // Lowercase hex string of the SHA256 hash of the raw content. ReportType string `json:"report_type"` // Report type. ReportStatus string `json:"report_status"` // Fixed to "pending". }
type ContentReportPost ¶
type ContentReportPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "share_report". SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Share id. Creator *ContentReportPostCreator `json:"creator"` // Creator. Created int `json:"created"` // Report created time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Extra *ContentReportPostExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewContentReportPost ¶
func NewContentReportPost() *ContentReportPost
type ContentReportPostCreator ¶
type ContentReportPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type ContentReportPostExtra ¶
type ContentReportPostExtra struct { Content string `json:"content"` // base64 encoded report content. ContentHash string `json:"content_hash"` // Lowercase hex string of the SHA256 hash of the raw content. ReportType string `json:"report_type"` // Report type. ReportStatus string `json:"report_status"` // Fixed to "pending". }
type GroupGet ¶
type GroupGet struct { Id string `json:"id"` // Group id. Title string `json:"title"` // Group title. Creator *GroupGetCreator `json:"creator"` // Creator. Avatar string `json:"avatar"` // An image id used for avatar. Abstract string `json:"abstract"` // Group introduction. Language string `json:"language"` // Group language. RFC4646 defined locales such as "en-US" Category string `json:"category"` // Group categories. Comma separated words list. Created int `json:"created"` // Group creation time. Unix timestamp. Updated int `json:"updated"` // Group last updating time. Unix timestamp. Extra *GroupGetExtra `json:"extra"` // Extra metadata. Signature string `json:"signature"` // Metadata signature. Dna string `json:"dna"` // Group DNA. TransactionId string `json:"transaction_id"` // Latest transaction id. }
Get
type GroupGetCreator ¶
type GroupGetCreator struct { AccountId string `json:"account_id"` // Root account id. AccountName string `json:"account_name"` // Root account name. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. }
type GroupGetExtra ¶
type GroupGetExtra struct { AllowJoin string `json:"allow_join"` // Joining group control. "all" or "application". AllowPost string `json:"allow_post"` // Posting control. "all", "none", "application". MembersTotal int `json:"members_total"` // Total members number. AccountRole string `json:"account_role,omitempty"` // Member status of current account. "owner", "member", "applicant" or "none". Members []AccountGet `json:"members"` // Members overview. An array of account id. }
type GroupMemberAppPostCreator ¶
type GroupMemberAppPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type GroupMemberAppPostExtra ¶
type GroupMemberAppPutExtra ¶
type GroupMemberAppPutExtra struct {
ApplicationStatus string `json:"application_status"` // "approved" or "declined".
}
type GroupMemberApplicationPost ¶
type GroupMemberApplicationPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member". SrcId string `json:"src_id"` // Account id. Root account id in the case of Sub account. DestId string `json:"dest_id"` // Group id. Created int `json:"created"` // Member joining time. Unix timestamp. Creator *GroupMemberAppPostCreator `json:"creator"` // Creator. Group owner. Status string `json:"status"` // Fixed to "created". Extra *GroupMemberAppPostExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
created
func NewGroupMemberApplicationPost ¶
func NewGroupMemberApplicationPost() *GroupMemberApplicationPost
type GroupMemberApplicationPut ¶
type GroupMemberApplicationPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member". ParentDna string `json:"parent_dna"` // Latest group member DNA. Status string `json:"status"` // Fixed to "updated". Updated int `json:"updated"` // Member updating time. Unix timestamp. Creator *GroupMemberAppPutCreator `json:"creator"` // Creator. Group owner. Extra *GroupMemberAppPutExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
updated
func NewGroupMemberApplicationPut ¶
func NewGroupMemberApplicationPut() *GroupMemberApplicationPut
type GroupMemberDelete ¶
type GroupMemberDelete struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member". ParentDna string `json:"parent_dna"` // Latest group member DNA. Status string `json:"status"` // "deleted". Updated int `json:"updated"` // Member quiting time. Unix timestamp. Creator *GroupMemberDeleteCreator `json:"creator"` // Creator. Signature string `json:"signature"` // Metadata signature. }
Delete
func NewGroupMemberDelete ¶
func NewGroupMemberDelete() *GroupMemberDelete
type GroupMemberGet ¶
type GroupMemberGet struct { Id string `json:"id"` // Group member id. SrcId string `json:"src_id"` // Account id. Root account id in the case of Sub account. DestId string `json:"dest_id"` // Group id. Creator *GroupMemberGetCreator `json:"creator"` // Creator. Created int `json:"created"` // Member joining time. Unix timestamp. Updated int `json:"updated"` // Member updating time. Unix timestamp. Extra *GroupMemberGetExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature"` // Metadata signature. Dna string `json:"dna"` // Group member DNA. TransactionId string `json:"transaction_id"` // Latest transaction id. Account *AccountGet `json:"account"` // Related member account. }
Get
type GroupMemberGetCreator ¶
type GroupMemberGetCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. AccountName string `json:"account_name"` // Account name. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type GroupMemberGetExtra ¶
type GroupMemberGetExtra struct {
ApplicationStatus string `json:"application_status"` // "pending", "approved" or "declined".
}
type GroupMemberPost ¶
type GroupMemberPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member". SrcId string `json:"src_id"` // Account id. Root account id in the case of Sub account. DestId string `json:"dest_id"` // Group id. Creator *GroupMemberPostCreator `json:"creator"` // Creator. Created int `json:"created"` // Member joining time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Extra *GroupMemberPostExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewGroupMemberPost ¶
func NewGroupMemberPost() *GroupMemberPost
type GroupMemberPostCreator ¶
type GroupMemberPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type GroupMemberPostExtra ¶
type GroupMemberPut ¶
type GroupMemberPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member". ParentDna string `json:"parent_dna"` // Latest group member DNA. Status string `json:"status"` // Fixed to "updated". Updated int `json:"updated"` // Member updating time. Unix timestamp. Creator *GroupMemberPutCreator `json:"creator"` // Creator. Group owner. Extra *GroupMemberPutExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewGroupMemberPut ¶
func NewGroupMemberPut() *GroupMemberPut
type GroupMemberPutCreator ¶
type GroupMemberPutExtra ¶
type GroupMemberPutExtra struct {
ApplicationStatus string `json:"application_status"` // "approved" or "declined".
}
type GroupMemberWhiteGetExtra ¶
type GroupMemberWhiteGetExtra struct {
ApplicationStatus string `json:"application_status"`
}
type GroupMemberWhitePostCreator ¶
type GroupMemberWhitePostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type GroupMemberWhitePostExtra ¶
type GroupMemberWhitePostExtra struct {
ApplicationStatus string `json:"application_status"` // Fixed to "pending".
}
type GroupMemberWhitePutExtra ¶
type GroupMemberWhitePutExtra struct {
ApplicationStatus string `json:"application_status"` // "approved" or "declined".
}
type GroupMemberWhitelistDelete ¶
type GroupMemberWhitelistDelete struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member_whitelist". ParentDna string `json:"parent_dna"` // Latest whitelist DNA. Status string `json:"status"` // Fixed to "deleted". Updated int `json:"updated"` // Whitelist updating time. Unix timestamp. Creator *GroupMemberWhitelistDeleteCreator `json:"creator"` // Creator. Signature string `json:"signature"` // Metadata signature. }
detele
func NewGroupMemberWhitelistDelete ¶
func NewGroupMemberWhitelistDelete() *GroupMemberWhitelistDelete
type GroupMemberWhitelistGet ¶
type GroupMemberWhitelistGet struct { Id string `json:"id"` // Group member id. SrcId string `json:"src_id"` // Account id. Root account id in the case of Sub account. DestId string `json:"dest_id"` // Group id. Creator *GroupMemberWhiteGetCreator `json:"creator"` // Creator. Created int `json:"created"` // Member joining time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Extra *GroupMemberWhiteGetExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. DNA string `json:"dna"` // Group member DNA. Account *AccountGet `json:"account"` // Related member account. }
get
type GroupMemberWhitelistPost ¶
type GroupMemberWhitelistPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member_whitelist". SrcId string `json:"src_id"` // Account id. DestId string `json:"dest_id"` // Group id. Creator *GroupMemberWhitePostCreator `json:"creator"` // Creator. Created int `json:"created"` // Whitelist creating time. Unix timestamp. Status string `json:"status"` // Fixed to "created". Extra *GroupMemberWhitePostExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
created
func NewGroupMemberWhitelistPost ¶
func NewGroupMemberWhitelistPost() *GroupMemberWhitelistPost
type GroupMemberWhitelistPut ¶
type GroupMemberWhitelistPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "relation". Tag string `json:"tag"` // Fixed to "group_member_whitelist". ParentDna string `json:"parent_dna"` // Latest whitelist DNA. Status string `json:"status"` // Fixed to "updated". Updated int `json:"updated"` // Whitelist updating time. Unix timestamp. Creator *GroupMemberWhitePutCreator `json:"creator"` // Creator. Extra *GroupMemberWhitePutExtra `json:"extra"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
updated
func NewGroupMemberWhitelistPut ¶
func NewGroupMemberWhitelistPut() *GroupMemberWhitelistPut
type GroupPost ¶
type GroupPost struct { Version string `json:"version"` // DTCP version. Fixed to "1.0" Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Fixed to "group". Title string `json:"title"` // Group title. Creator *GroupPostCreator `json:"creator"` // Creator. Avatar string `json:"avatar"` // An image id used for avatar. Abstract string `json:"abstract"` // Group introduction. Language string `json:"language"` // Group language. RFC4646 defined locales such as "en-US" Category string `json:"category"` // Group categories. Comma separated words list. Created int `json:"created"` // Group creation time. Unix timestamp. Extra *GroupPostExtra `json:"extra"` // Extra metadata. Status string `json:"status"` // Fixed to "created". Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewGroupPost ¶
func NewGroupPost() *GroupPost
type GroupPostCreator ¶
type GroupPostCreator struct { AccountId string `json:"account_id"` // Account id. Root account id in the case of Sub account posting. SubAccountId string `json:"sub_account_id,omitempty"` // Sub account id. Refer to Sub account for details. SubAccountName string `json:"sub_account_name,omitempty"` // Sub account name. For fast creation of new sub accounts. }
type GroupPostExtra ¶
type GroupPostExtra struct { AllowJoin string `json:"allow_join"` // Joining group control. "all" or "application". AllowPost string `json:"allow_post"` // Posting control. "all", "none", "application". AllowPostWhitelist []string `json:"allow_post_whitelist,omitempty"` //An array containing account_ids that can always post in the group. }
type GroupPut ¶
type GroupPut struct { Version string `json:"version"` // DTCP version. Fixed to "1.0". Atype string `json:"type"` // Fixed to "object". Tag string `json:"tag"` // Fixed to "group". ParentDna string `json:"parent_dna"` // The latest DNA of the group. Status string `json:"status"` // Fixed to "updated". Updated int `json:"updated"` // Group update time. Unix timestamp. Title string `json:"title,omitempty"` // Group title. Avatar string `json:"avatar,omitempty"` // An image id used for avatar. Abstract string `json:"abstract,omitempty"` // Group introduction. Language string `json:"language,omitempty"` // Group language. RFC4646 defined locales such as "en-US" Category string `json:"category,omitempty"` // Group categories. Comma separated words list. Extra *GroupPutExtra `json:"extra,omitempty"` // Extra metadata. Signature string `json:"signature,omitempty"` // Metadata signature. }
func NewGroupPut ¶
func NewGroupPut() *GroupPut
type GroupPutExtra ¶
type GroupShareAppPut ¶
type GroupShareAppPut struct {}
func NewGroupShareAppPut ¶
func NewGroupShareAppPut() *GroupShareAppPut
type GroupShareAppPutCreator ¶
type GroupShareAppPutCreator struct {}
type GroupShareAppPutExtra ¶
type GroupShareAppPutExtra struct {
}type GroupShareDelete ¶
type GroupShareDelete struct {}
Delete
func NewGroupShareDelete ¶
func NewGroupShareDelete() *GroupShareDelete
type GroupShareDeleteCreator ¶
type GroupShareDeleteCreator struct {}
type GroupSharePost ¶
type GroupSharePost struct {}
func NewGroupSharePost ¶
func NewGroupSharePost() *GroupSharePost
type GroupSharePostCreator ¶
type GroupSharePostCreator struct {}
type GroupSharePostExtra ¶
type GroupSharePostExtra struct {}
type License ¶
type License struct { Name string `json:"name"` Version string `json:"version"` Parameters []LicenseSubject `json:"parameters"` }
type LicensePrice ¶
func NewLicensePST ¶
func NewLicensePST(value decimal.Decimal) *LicensePrice
func NewLicensePrice ¶
func NewLicensePrice(value decimal.Decimal) *LicensePrice
type LicenseSubject ¶
func NewLicenseCommercial ¶
func NewLicenseCommercial(value string) *LicenseSubject
func NewLicenseCommercial_n ¶
func NewLicenseCommercial_n(value string) *LicenseSubject
func NewLicenseCommercial_y ¶
func NewLicenseCommercial_y() *LicenseSubject
func NewLicenseDerivative ¶
func NewLicenseDerivative(value string) *LicenseSubject
func NewLicenseDerivative_n ¶
func NewLicenseDerivative_n() *LicenseSubject
func NewLicenseDerivative_sa ¶
func NewLicenseDerivative_sa() *LicenseSubject
func NewLicenseDerivative_y ¶
func NewLicenseDerivative_y() *LicenseSubject
type ShareCreator ¶
type ShareCreator struct {}
type ShareExtra ¶
type ShareExtra struct {}
type SystemParametersGet ¶
type SystemParametersGet struct { LockAmountContent decimal.Decimal // Token lock amount for posting content. LockPeriodContent int // Token lock period in seconds for posting content. LockAmountGroupJoin decimal.Decimal // Token lock amount for joining group. LockAmountGroupCreate decimal.Decimal // Token lock amount for creating group. ConsumeAmountReport decimal.Decimal // Token consumed amount for report share. }
Click to show internal directories.
Click to hide internal directories.