DescribeAccountAmount.go 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. // Copyright 2018 JDCLOUD.COM
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. //
  15. // NOTE: This class is auto generated by the jdcloud code generator program.
  16. package apis
  17. import (
  18. "github.com/jdcloud-api/jdcloud-sdk-go/core"
  19. )
  20. type DescribeAccountAmountRequest struct {
  21. core.JDCloudRequest
  22. /* Region ID */
  23. RegionId string `json:"regionId"`
  24. }
  25. /*
  26. * param regionId: Region ID (Required)
  27. *
  28. * @Deprecated, not compatible when mandatory parameters changed
  29. */
  30. func NewDescribeAccountAmountRequest(
  31. regionId string,
  32. ) *DescribeAccountAmountRequest {
  33. return &DescribeAccountAmountRequest{
  34. JDCloudRequest: core.JDCloudRequest{
  35. URL: "/regions/{regionId}/assets:describeAccountAmount",
  36. Method: "GET",
  37. Header: nil,
  38. Version: "v1",
  39. },
  40. RegionId: regionId,
  41. }
  42. }
  43. /*
  44. * param regionId: Region ID (Required)
  45. */
  46. func NewDescribeAccountAmountRequestWithAllParams(
  47. regionId string,
  48. ) *DescribeAccountAmountRequest {
  49. return &DescribeAccountAmountRequest{
  50. JDCloudRequest: core.JDCloudRequest{
  51. URL: "/regions/{regionId}/assets:describeAccountAmount",
  52. Method: "GET",
  53. Header: nil,
  54. Version: "v1",
  55. },
  56. RegionId: regionId,
  57. }
  58. }
  59. /* This constructor has better compatible ability when API parameters changed */
  60. func NewDescribeAccountAmountRequestWithoutParam() *DescribeAccountAmountRequest {
  61. return &DescribeAccountAmountRequest{
  62. JDCloudRequest: core.JDCloudRequest{
  63. URL: "/regions/{regionId}/assets:describeAccountAmount",
  64. Method: "GET",
  65. Header: nil,
  66. Version: "v1",
  67. },
  68. }
  69. }
  70. /* param regionId: Region ID(Required) */
  71. func (r *DescribeAccountAmountRequest) SetRegionId(regionId string) {
  72. r.RegionId = regionId
  73. }
  74. // GetRegionId returns path parameter 'regionId' if exist,
  75. // otherwise return empty string
  76. func (r DescribeAccountAmountRequest) GetRegionId() string {
  77. return r.RegionId
  78. }
  79. type DescribeAccountAmountResponse struct {
  80. RequestID string `json:"requestId"`
  81. Error core.ErrorResponse `json:"error"`
  82. Result DescribeAccountAmountResult `json:"result"`
  83. }
  84. type DescribeAccountAmountResult struct {
  85. TotalAmount string `json:"totalAmount"`
  86. AvailableAmount string `json:"availableAmount"`
  87. FrozenAmount string `json:"frozenAmount"`
  88. EnableWithdrawAmount string `json:"enableWithdrawAmount"`
  89. WithdrawingAmount string `json:"withdrawingAmount"`
  90. }