Add a new Alibaba Cloud Bill API named QueryAccountBill.

This commit is contained in:
sdk-team
2019-10-29 14:57:42 +08:00
parent 58ae8a9ac1
commit 0d843e2d71
63 changed files with 542 additions and 58 deletions

View File

@@ -68,6 +68,8 @@
#include "model/ModifyInstanceResult.h"
#include "model/QueryAccountBalanceRequest.h"
#include "model/QueryAccountBalanceResult.h"
#include "model/QueryAccountBillRequest.h"
#include "model/QueryAccountBillResult.h"
#include "model/QueryAccountTransactionsRequest.h"
#include "model/QueryAccountTransactionsResult.h"
#include "model/QueryAvailableInstancesRequest.h"
@@ -208,6 +210,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::QueryAccountBalanceResult> QueryAccountBalanceOutcome;
typedef std::future<QueryAccountBalanceOutcome> QueryAccountBalanceOutcomeCallable;
typedef std::function<void(const BssOpenApiClient*, const Model::QueryAccountBalanceRequest&, const QueryAccountBalanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryAccountBalanceAsyncHandler;
typedef Outcome<Error, Model::QueryAccountBillResult> QueryAccountBillOutcome;
typedef std::future<QueryAccountBillOutcome> QueryAccountBillOutcomeCallable;
typedef std::function<void(const BssOpenApiClient*, const Model::QueryAccountBillRequest&, const QueryAccountBillOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryAccountBillAsyncHandler;
typedef Outcome<Error, Model::QueryAccountTransactionsResult> QueryAccountTransactionsOutcome;
typedef std::future<QueryAccountTransactionsOutcome> QueryAccountTransactionsOutcomeCallable;
typedef std::function<void(const BssOpenApiClient*, const Model::QueryAccountTransactionsRequest&, const QueryAccountTransactionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryAccountTransactionsAsyncHandler;
@@ -375,6 +380,9 @@ namespace AlibabaCloud
QueryAccountBalanceOutcome queryAccountBalance(const Model::QueryAccountBalanceRequest &request)const;
void queryAccountBalanceAsync(const Model::QueryAccountBalanceRequest& request, const QueryAccountBalanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
QueryAccountBalanceOutcomeCallable queryAccountBalanceCallable(const Model::QueryAccountBalanceRequest& request) const;
QueryAccountBillOutcome queryAccountBill(const Model::QueryAccountBillRequest &request)const;
void queryAccountBillAsync(const Model::QueryAccountBillRequest& request, const QueryAccountBillAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
QueryAccountBillOutcomeCallable queryAccountBillCallable(const Model::QueryAccountBillRequest& request) const;
QueryAccountTransactionsOutcome queryAccountTransactions(const Model::QueryAccountTransactionsRequest &request)const;
void queryAccountTransactionsAsync(const Model::QueryAccountTransactionsRequest& request, const QueryAccountTransactionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
QueryAccountTransactionsOutcomeCallable queryAccountTransactionsCallable(const Model::QueryAccountTransactionsRequest& request) const;

View File

@@ -0,0 +1,57 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLREQUEST_H_
#define ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/bssopenapi/BssOpenApiExport.h>
namespace AlibabaCloud
{
namespace BssOpenApi
{
namespace Model
{
class ALIBABACLOUD_BSSOPENAPI_EXPORT QueryAccountBillRequest : public RpcServiceRequest
{
public:
QueryAccountBillRequest();
~QueryAccountBillRequest();
std::string getBillingCycle()const;
void setBillingCycle(const std::string& billingCycle);
int getPageNum()const;
void setPageNum(int pageNum);
long getOwnerID()const;
void setOwnerID(long ownerID);
int getPageSize()const;
void setPageSize(int pageSize);
private:
std::string billingCycle_;
int pageNum_;
long ownerID_;
int pageSize_;
};
}
}
}
#endif // !ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLREQUEST_H_

View File

@@ -0,0 +1,82 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLRESULT_H_
#define ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/bssopenapi/BssOpenApiExport.h>
namespace AlibabaCloud
{
namespace BssOpenApi
{
namespace Model
{
class ALIBABACLOUD_BSSOPENAPI_EXPORT QueryAccountBillResult : public ServiceResult
{
public:
struct Data
{
struct Item
{
float pretaxGrossAmount;
float deductedByCoupons;
std::string ownerName;
std::string ownerID;
float pretaxAmount;
std::string currency;
float deductedByCashCoupons;
float outstandingAmount;
std::string costUnit;
float paymentAmount;
float deductedByPrepaidCard;
float invoiceDiscount;
};
std::string billingCycle;
int totalCount;
std::string accountID;
int pageNum;
int pageSize;
std::vector<Item> items;
std::string accountName;
};
QueryAccountBillResult();
explicit QueryAccountBillResult(const std::string &payload);
~QueryAccountBillResult();
std::string getMessage()const;
Data getData()const;
std::string getCode()const;
bool getSuccess()const;
protected:
void parse(const std::string &payload);
private:
std::string message_;
Data data_;
std::string code_;
bool success_;
};
}
}
}
#endif // !ALIBABACLOUD_BSSOPENAPI_MODEL_QUERYACCOUNTBILLRESULT_H_