Get the capicity which cloud siem user used until yesterday.

This commit is contained in:
sdk-team
2023-03-06 01:44:08 +00:00
parent 766d807fa5
commit 159a3aa236
17 changed files with 1193 additions and 1 deletions

View File

@@ -0,0 +1,70 @@
/*
* 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_CLOUD_SIEM_CLOUD_SIEMCLIENT_H_
#define ALIBABACLOUD_CLOUD_SIEM_CLOUD_SIEMCLIENT_H_
#include <future>
#include <alibabacloud/core/AsyncCallerContext.h>
#include <alibabacloud/core/EndpointProvider.h>
#include <alibabacloud/core/RpcServiceClient.h>
#include "Cloud_siemExport.h"
#include "model/BatchJobCheckRequest.h"
#include "model/BatchJobCheckResult.h"
#include "model/BatchJobSubmitRequest.h"
#include "model/BatchJobSubmitResult.h"
#include "model/SendMessageRequest.h"
#include "model/SendMessageResult.h"
namespace AlibabaCloud
{
namespace Cloud_siem
{
class ALIBABACLOUD_CLOUD_SIEM_EXPORT Cloud_siemClient : public RpcServiceClient
{
public:
typedef Outcome<Error, Model::BatchJobCheckResult> BatchJobCheckOutcome;
typedef std::future<BatchJobCheckOutcome> BatchJobCheckOutcomeCallable;
typedef std::function<void(const Cloud_siemClient*, const Model::BatchJobCheckRequest&, const BatchJobCheckOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> BatchJobCheckAsyncHandler;
typedef Outcome<Error, Model::BatchJobSubmitResult> BatchJobSubmitOutcome;
typedef std::future<BatchJobSubmitOutcome> BatchJobSubmitOutcomeCallable;
typedef std::function<void(const Cloud_siemClient*, const Model::BatchJobSubmitRequest&, const BatchJobSubmitOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> BatchJobSubmitAsyncHandler;
typedef Outcome<Error, Model::SendMessageResult> SendMessageOutcome;
typedef std::future<SendMessageOutcome> SendMessageOutcomeCallable;
typedef std::function<void(const Cloud_siemClient*, const Model::SendMessageRequest&, const SendMessageOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> SendMessageAsyncHandler;
Cloud_siemClient(const Credentials &credentials, const ClientConfiguration &configuration);
Cloud_siemClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
Cloud_siemClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
~Cloud_siemClient();
BatchJobCheckOutcome batchJobCheck(const Model::BatchJobCheckRequest &request)const;
void batchJobCheckAsync(const Model::BatchJobCheckRequest& request, const BatchJobCheckAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
BatchJobCheckOutcomeCallable batchJobCheckCallable(const Model::BatchJobCheckRequest& request) const;
BatchJobSubmitOutcome batchJobSubmit(const Model::BatchJobSubmitRequest &request)const;
void batchJobSubmitAsync(const Model::BatchJobSubmitRequest& request, const BatchJobSubmitAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
BatchJobSubmitOutcomeCallable batchJobSubmitCallable(const Model::BatchJobSubmitRequest& request) const;
SendMessageOutcome sendMessage(const Model::SendMessageRequest &request)const;
void sendMessageAsync(const Model::SendMessageRequest& request, const SendMessageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
SendMessageOutcomeCallable sendMessageCallable(const Model::SendMessageRequest& request) const;
private:
std::shared_ptr<EndpointProvider> endpointProvider_;
};
}
}
#endif // !ALIBABACLOUD_CLOUD_SIEM_CLOUD_SIEMCLIENT_H_

View File

@@ -0,0 +1,32 @@
/*
* 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_CLOUD_SIEM_CLOUD_SIEMEXPORT_H_
#define ALIBABACLOUD_CLOUD_SIEM_CLOUD_SIEMEXPORT_H_
#include <alibabacloud/core/Global.h>
#if defined(ALIBABACLOUD_SHARED)
# if defined(ALIBABACLOUD_CLOUD_SIEM_LIBRARY)
# define ALIBABACLOUD_CLOUD_SIEM_EXPORT ALIBABACLOUD_DECL_EXPORT
# else
# define ALIBABACLOUD_CLOUD_SIEM_EXPORT ALIBABACLOUD_DECL_IMPORT
# endif
#else
# define ALIBABACLOUD_CLOUD_SIEM_EXPORT
#endif
#endif // !ALIBABACLOUD_CLOUD_SIEM_CLOUD_SIEMEXPORT_H_

View File

@@ -0,0 +1,45 @@
/*
* 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_CLOUD_SIEM_MODEL_BATCHJOBCHECKREQUEST_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBCHECKREQUEST_H_
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Cloud_siem {
namespace Model {
class ALIBABACLOUD_CLOUD_SIEM_EXPORT BatchJobCheckRequest : public RpcServiceRequest {
public:
BatchJobCheckRequest();
~BatchJobCheckRequest();
std::string getRegionId() const;
void setRegionId(const std::string &regionId);
std::string getSubmitId() const;
void setSubmitId(const std::string &submitId);
private:
std::string regionId_;
std::string submitId_;
};
} // namespace Model
} // namespace Cloud_siem
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBCHECKREQUEST_H_

View File

@@ -0,0 +1,88 @@
/*
* 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_CLOUD_SIEM_MODEL_BATCHJOBCHECKRESULT_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBCHECKRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
namespace AlibabaCloud
{
namespace Cloud_siem
{
namespace Model
{
class ALIBABACLOUD_CLOUD_SIEM_EXPORT BatchJobCheckResult : public ServiceResult
{
public:
struct Data
{
struct ErrTaskListItem
{
struct ProductListItem
{
struct LogListItem
{
std::string projectNamePattern;
std::string regionCode;
std::string logStoreNamePattern;
std::string productCode;
std::string errorCode;
std::string logCode;
};
std::vector<ProductListItem::LogListItem> logList;
std::string productCode;
};
std::vector<ErrTaskListItem::ProductListItem> productList;
long userId;
};
int taskCount;
int finishCount;
int failedCount;
std::string configId;
std::string folderId;
std::string taskStatus;
std::vector<ErrTaskListItem> errTaskList;
};
BatchJobCheckResult();
explicit BatchJobCheckResult(const std::string &payload);
~BatchJobCheckResult();
std::string getMessage()const;
Data getData()const;
int getCode()const;
bool getSuccess()const;
std::string getErrCode()const;
protected:
void parse(const std::string &payload);
private:
std::string message_;
Data data_;
int code_;
bool success_;
std::string errCode_;
};
}
}
}
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBCHECKRESULT_H_

View File

@@ -0,0 +1,45 @@
/*
* 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_CLOUD_SIEM_MODEL_BATCHJOBSUBMITREQUEST_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBSUBMITREQUEST_H_
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Cloud_siem {
namespace Model {
class ALIBABACLOUD_CLOUD_SIEM_EXPORT BatchJobSubmitRequest : public RpcServiceRequest {
public:
BatchJobSubmitRequest();
~BatchJobSubmitRequest();
std::string getRegionId() const;
void setRegionId(const std::string &regionId);
std::string getJsonConfig() const;
void setJsonConfig(const std::string &jsonConfig);
private:
std::string regionId_;
std::string jsonConfig_;
};
} // namespace Model
} // namespace Cloud_siem
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBSUBMITREQUEST_H_

View File

@@ -0,0 +1,85 @@
/*
* 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_CLOUD_SIEM_MODEL_BATCHJOBSUBMITRESULT_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBSUBMITRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
namespace AlibabaCloud
{
namespace Cloud_siem
{
namespace Model
{
class ALIBABACLOUD_CLOUD_SIEM_EXPORT BatchJobSubmitResult : public ServiceResult
{
public:
struct Data
{
struct ConfigListItem
{
struct ProductListItem
{
struct LogListItem
{
std::string projectNamePattern;
std::string regionCode;
std::string logStoreNamePattern;
std::string productCode;
std::string errorCode;
std::string logCode;
};
std::vector<ProductListItem::LogListItem> logList;
std::string productCode;
};
std::vector<ConfigListItem::ProductListItem> productList;
long userId;
};
std::string submitId;
int taskCount;
std::string configId;
std::vector<ConfigListItem> configList;
};
BatchJobSubmitResult();
explicit BatchJobSubmitResult(const std::string &payload);
~BatchJobSubmitResult();
std::string getMessage()const;
Data getData()const;
int getCode()const;
bool getSuccess()const;
std::string getErrCode()const;
protected:
void parse(const std::string &payload);
private:
std::string message_;
Data data_;
int code_;
bool success_;
std::string errCode_;
};
}
}
}
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_BATCHJOBSUBMITRESULT_H_

View File

@@ -0,0 +1,48 @@
/*
* 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_CLOUD_SIEM_MODEL_SENDMESSAGEREQUEST_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_SENDMESSAGEREQUEST_H_
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Cloud_siem {
namespace Model {
class ALIBABACLOUD_CLOUD_SIEM_EXPORT SendMessageRequest : public RpcServiceRequest {
public:
SendMessageRequest();
~SendMessageRequest();
std::string getRegionId() const;
void setRegionId(const std::string &regionId);
int getChannelType() const;
void setChannelType(int channelType);
long getReceiveUid() const;
void setReceiveUid(long receiveUid);
private:
std::string regionId_;
int channelType_;
long receiveUid_;
};
} // namespace Model
} // namespace Cloud_siem
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_SENDMESSAGEREQUEST_H_

View File

@@ -0,0 +1,59 @@
/*
* 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_CLOUD_SIEM_MODEL_SENDMESSAGERESULT_H_
#define ALIBABACLOUD_CLOUD_SIEM_MODEL_SENDMESSAGERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/cloud-siem/Cloud_siemExport.h>
namespace AlibabaCloud
{
namespace Cloud_siem
{
namespace Model
{
class ALIBABACLOUD_CLOUD_SIEM_EXPORT SendMessageResult : public ServiceResult
{
public:
SendMessageResult();
explicit SendMessageResult(const std::string &payload);
~SendMessageResult();
std::string getMessage()const;
bool getData()const;
int getCode()const;
bool getSuccess()const;
std::string getErrCode()const;
protected:
void parse(const std::string &payload);
private:
std::string message_;
bool data_;
int code_;
bool success_;
std::string errCode_;
};
}
}
}
#endif // !ALIBABACLOUD_CLOUD_SIEM_MODEL_SENDMESSAGERESULT_H_