@@ -22,20 +22,38 @@ type iAllocateCostCenterResourceRequest interface {
2222}
2323
2424type AllocateCostCenterResourceRequest struct {
25+ // The ID of the source cost center. This parameter is required.
26+ //
27+ // - 0 indicates that the cost center is unallocated.
28+ //
29+ // - A value greater than 0 indicates an allocated cost center ID.
30+ //
2531 // example:
2632 //
2733 // 637180
2834 FromCostCenterId * int64 `json:"FromCostCenterId,omitempty" xml:"FromCostCenterId,omitempty"`
35+ // The ID of the owner of the source cost center.
36+ //
2937 // example:
3038 //
3139 // 1529600453335198
3240 FromOwnerAccountId * int64 `json:"FromOwnerAccountId,omitempty" xml:"FromOwnerAccountId,omitempty"`
41+ // The primary sales channel ID. If this parameter is left empty, the sales channel ID of the current user is used by default.
42+ //
3343 // example:
3444 //
3545 // 2684201000001
3646 Nbid * string `json:"Nbid,omitempty" xml:"Nbid,omitempty"`
47+ // The list of resource instances.
48+ //
3749 // This parameter is required.
3850 ResourceInstanceList []* AllocateCostCenterResourceRequestResourceInstanceList `json:"ResourceInstanceList,omitempty" xml:"ResourceInstanceList,omitempty" type:"Repeated"`
51+ // The ID of the destination cost center. Valid values:
52+ //
53+ // - -1: moves the allocated resource to the unallocated state.
54+ //
55+ // - A value greater than 0: allocates the resource to the specified cost center.
56+ //
3957 // example:
4058 //
4159 // 638288
@@ -109,63 +127,106 @@ func (s *AllocateCostCenterResourceRequest) Validate() error {
109127}
110128
111129type AllocateCostCenterResourceRequestResourceInstanceList struct {
130+ // The attached resource type of the attached-resource instance. This parameter is required only for attached-resource product instances.
131+ //
132+ // - Currently, eight commodities support attached resources. The commodity codes are oss, dcdn, snapshot, vod, cdn, live, and cbwp.
133+ //
134+ // - You can call the QueryCostUnitResource operation to obtain all billing instances (including attached-resource instances with their attached resources) under a specific cost center (including the unallocated cost center) of a user.
135+ //
112136 // example:
113137 //
114138 // qwer1-cn-beijing
115139 ApportionCode * string `json:"ApportionCode,omitempty" xml:"ApportionCode,omitempty"`
140+ // The attached resource name.
141+ //
116142 // example:
117143 //
118144 // split-item-test1
119145 ApportionName * string `json:"ApportionName,omitempty" xml:"ApportionName,omitempty"`
146+ // The commodity code of the billing instance. This parameter is required.
147+ //
120148 // example:
121149 //
122150 // oss
123151 CommodityCode * string `json:"CommodityCode,omitempty" xml:"CommodityCode,omitempty"`
152+ // The commodity name of the resource.
153+ //
124154 // example:
125155 //
126156 // RESOURCE_UDR
127157 CommodityName * string `json:"CommodityName,omitempty" xml:"CommodityName,omitempty"`
128- InstanceId * string `json:"InstanceId,omitempty" xml:"InstanceId,omitempty"`
158+ // The billing granularity ID. This parameter is required.
159+ //
160+ // example:
161+ //
162+ // cn-hangzhou;standard
163+ InstanceId * string `json:"InstanceId,omitempty" xml:"InstanceId,omitempty"`
164+ // The product code, which is the same as the product code in User Center bills.
165+ //
129166 // example:
130167 //
131168 // ecs
132169 PipCode * string `json:"PipCode,omitempty" xml:"PipCode,omitempty"`
170+ // The resources related to the resource instance.
171+ //
133172 // example:
134173 //
135174 // related-resource
136175 RelatedResources * string `json:"RelatedResources,omitempty" xml:"RelatedResources,omitempty"`
176+ // The resource group.
177+ //
137178 // example:
138179 //
139180 // xihe_mpp
140181 ResourceGroup * string `json:"ResourceGroup,omitempty" xml:"ResourceGroup,omitempty"`
182+ // The resource ID.
183+ //
141184 // example:
142185 //
143- // cn-hangzhou;standard
186+ // cn-hangzhou;standard:app
144187 ResourceId * string `json:"ResourceId,omitempty" xml:"ResourceId,omitempty"`
188+ // The custom nickname of the resource.
189+ //
145190 // example:
146191 //
147192 // ecs-test-1
148193 ResourceNick * string `json:"ResourceNick,omitempty" xml:"ResourceNick,omitempty"`
194+ // The resource source. Valid values:
195+ //
196+ // - AUTO_ALLOCATE: automatic allocation.
197+ //
198+ // - MANUAL_ALLOCATE: manual allocation.
199+ //
149200 // example:
150201 //
151202 // AUTO_ALLOCATE
152203 ResourceSource * string `json:"ResourceSource,omitempty" xml:"ResourceSource,omitempty"`
204+ // The resource status.
205+ //
153206 // example:
154207 //
155208 // 0
156209 ResourceStatus * string `json:"ResourceStatus,omitempty" xml:"ResourceStatus,omitempty"`
210+ // The tag of the resource.
211+ //
157212 // example:
158213 //
159214 // tag-test1
160215 ResourceTag * string `json:"ResourceTag,omitempty" xml:"ResourceTag,omitempty"`
216+ // The resource type.
217+ //
161218 // example:
162219 //
163220 // SCU
164221 ResourceType * string `json:"ResourceType,omitempty" xml:"ResourceType,omitempty"`
222+ // The ID of the owner of the billing instance. This parameter is required.
223+ //
165224 // example:
166225 //
167226 // 273394581313325532
168227 ResourceUserId * int64 `json:"ResourceUserId,omitempty" xml:"ResourceUserId,omitempty"`
228+ // The resource ownership username.
229+ //
169230 // example:
170231 //
171232 // test
0 commit comments