Add CreateSshKey OpenAPI.

This commit is contained in:
sdk-team
2021-06-11 02:11:54 +00:00
parent 5599b4ad14
commit ac11b7e23d
9 changed files with 290 additions and 1 deletions

View File

@@ -46,6 +46,8 @@
#include "model/CreateRepositoryGroupResult.h"
#include "model/CreateRepositoryProtectedBranchRequest.h"
#include "model/CreateRepositoryProtectedBranchResult.h"
#include "model/CreateSshKeyRequest.h"
#include "model/CreateSshKeyResult.h"
#include "model/CreateTagRequest.h"
#include "model/CreateTagResult.h"
#include "model/DeleteBranchRequest.h"
@@ -193,6 +195,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::CreateRepositoryProtectedBranchResult> CreateRepositoryProtectedBranchOutcome;
typedef std::future<CreateRepositoryProtectedBranchOutcome> CreateRepositoryProtectedBranchOutcomeCallable;
typedef std::function<void(const CodeupClient*, const Model::CreateRepositoryProtectedBranchRequest&, const CreateRepositoryProtectedBranchOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateRepositoryProtectedBranchAsyncHandler;
typedef Outcome<Error, Model::CreateSshKeyResult> CreateSshKeyOutcome;
typedef std::future<CreateSshKeyOutcome> CreateSshKeyOutcomeCallable;
typedef std::function<void(const CodeupClient*, const Model::CreateSshKeyRequest&, const CreateSshKeyOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateSshKeyAsyncHandler;
typedef Outcome<Error, Model::CreateTagResult> CreateTagOutcome;
typedef std::future<CreateTagOutcome> CreateTagOutcomeCallable;
typedef std::function<void(const CodeupClient*, const Model::CreateTagRequest&, const CreateTagOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateTagAsyncHandler;
@@ -387,6 +392,9 @@ namespace AlibabaCloud
CreateRepositoryProtectedBranchOutcome createRepositoryProtectedBranch(const Model::CreateRepositoryProtectedBranchRequest &request)const;
void createRepositoryProtectedBranchAsync(const Model::CreateRepositoryProtectedBranchRequest& request, const CreateRepositoryProtectedBranchAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateRepositoryProtectedBranchOutcomeCallable createRepositoryProtectedBranchCallable(const Model::CreateRepositoryProtectedBranchRequest& request) const;
CreateSshKeyOutcome createSshKey(const Model::CreateSshKeyRequest &request)const;
void createSshKeyAsync(const Model::CreateSshKeyRequest& request, const CreateSshKeyAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateSshKeyOutcomeCallable createSshKeyCallable(const Model::CreateSshKeyRequest& request) const;
CreateTagOutcome createTag(const Model::CreateTagRequest &request)const;
void createTagAsync(const Model::CreateTagRequest& request, const CreateTagAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateTagOutcomeCallable createTagCallable(const Model::CreateTagRequest& request) const;

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_CODEUP_MODEL_CREATESSHKEYREQUEST_H_
#define ALIBABACLOUD_CODEUP_MODEL_CREATESSHKEYREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RoaServiceRequest.h>
#include <alibabacloud/codeup/CodeupExport.h>
namespace AlibabaCloud
{
namespace Codeup
{
namespace Model
{
class ALIBABACLOUD_CODEUP_EXPORT CreateSshKeyRequest : public RoaServiceRequest
{
public:
CreateSshKeyRequest();
~CreateSshKeyRequest();
std::string getAccessToken()const;
void setAccessToken(const std::string& accessToken);
private:
std::string accessToken_;
};
}
}
}
#endif // !ALIBABACLOUD_CODEUP_MODEL_CREATESSHKEYREQUEST_H_

View File

@@ -0,0 +1,66 @@
/*
* 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_CODEUP_MODEL_CREATESSHKEYRESULT_H_
#define ALIBABACLOUD_CODEUP_MODEL_CREATESSHKEYRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/codeup/CodeupExport.h>
namespace AlibabaCloud
{
namespace Codeup
{
namespace Model
{
class ALIBABACLOUD_CODEUP_EXPORT CreateSshKeyResult : public ServiceResult
{
public:
struct Result
{
std::string createdAt;
std::string fingerPrint;
std::string title;
long id;
std::string keyScope;
std::string key;
};
CreateSshKeyResult();
explicit CreateSshKeyResult(const std::string &payload);
~CreateSshKeyResult();
std::string getErrorCode()const;
std::string getErrorMessage()const;
bool getSuccess()const;
Result getResult()const;
protected:
void parse(const std::string &payload);
private:
std::string errorCode_;
std::string errorMessage_;
bool success_;
Result result_;
};
}
}
}
#endif // !ALIBABACLOUD_CODEUP_MODEL_CREATESSHKEYRESULT_H_