Supported new features etc.

This commit is contained in:
sdk-team
2021-12-29 06:58:14 +00:00
parent 1f47213704
commit dacf4c261f
21 changed files with 868 additions and 3 deletions

View File

@@ -1,3 +1,6 @@
2021-12-29 Version: 1.36.1003
- Supported new features etc.
2021-12-29 Version: 1.36.1002
- Supported new features for outbound.

View File

@@ -1 +1 @@
1.36.1002
1.36.1003

View File

@@ -73,6 +73,10 @@ set(voicenavigator_public_header_model
include/alibabacloud/voicenavigator/model/ExportConversationDetailsResult.h
include/alibabacloud/voicenavigator/model/ExportStatisticalDataRequest.h
include/alibabacloud/voicenavigator/model/ExportStatisticalDataResult.h
include/alibabacloud/voicenavigator/model/GetInstanceConfigRequest.h
include/alibabacloud/voicenavigator/model/GetInstanceConfigResult.h
include/alibabacloud/voicenavigator/model/GetNewBargeInSwitchRequest.h
include/alibabacloud/voicenavigator/model/GetNewBargeInSwitchResult.h
include/alibabacloud/voicenavigator/model/ListChatbotInstancesRequest.h
include/alibabacloud/voicenavigator/model/ListChatbotInstancesResult.h
include/alibabacloud/voicenavigator/model/ListConversationDetailsRequest.h
@@ -100,7 +104,9 @@ set(voicenavigator_public_header_model
include/alibabacloud/voicenavigator/model/SaveRecordingRequest.h
include/alibabacloud/voicenavigator/model/SaveRecordingResult.h
include/alibabacloud/voicenavigator/model/SilenceTimeoutRequest.h
include/alibabacloud/voicenavigator/model/SilenceTimeoutResult.h )
include/alibabacloud/voicenavigator/model/SilenceTimeoutResult.h
include/alibabacloud/voicenavigator/model/UpdateNewBargeInSwitchRequest.h
include/alibabacloud/voicenavigator/model/UpdateNewBargeInSwitchResult.h )
set(voicenavigator_src
src/VoiceNavigatorClient.cc
@@ -156,6 +162,10 @@ set(voicenavigator_src
src/model/ExportConversationDetailsResult.cc
src/model/ExportStatisticalDataRequest.cc
src/model/ExportStatisticalDataResult.cc
src/model/GetInstanceConfigRequest.cc
src/model/GetInstanceConfigResult.cc
src/model/GetNewBargeInSwitchRequest.cc
src/model/GetNewBargeInSwitchResult.cc
src/model/ListChatbotInstancesRequest.cc
src/model/ListChatbotInstancesResult.cc
src/model/ListConversationDetailsRequest.cc
@@ -183,7 +193,9 @@ set(voicenavigator_src
src/model/SaveRecordingRequest.cc
src/model/SaveRecordingResult.cc
src/model/SilenceTimeoutRequest.cc
src/model/SilenceTimeoutResult.cc )
src/model/SilenceTimeoutResult.cc
src/model/UpdateNewBargeInSwitchRequest.cc
src/model/UpdateNewBargeInSwitchResult.cc )
add_library(voicenavigator ${LIB_TYPE}
${voicenavigator_public_header}

View File

@@ -74,6 +74,10 @@
#include "model/ExportConversationDetailsResult.h"
#include "model/ExportStatisticalDataRequest.h"
#include "model/ExportStatisticalDataResult.h"
#include "model/GetInstanceConfigRequest.h"
#include "model/GetInstanceConfigResult.h"
#include "model/GetNewBargeInSwitchRequest.h"
#include "model/GetNewBargeInSwitchResult.h"
#include "model/ListChatbotInstancesRequest.h"
#include "model/ListChatbotInstancesResult.h"
#include "model/ListConversationDetailsRequest.h"
@@ -102,6 +106,8 @@
#include "model/SaveRecordingResult.h"
#include "model/SilenceTimeoutRequest.h"
#include "model/SilenceTimeoutResult.h"
#include "model/UpdateNewBargeInSwitchRequest.h"
#include "model/UpdateNewBargeInSwitchResult.h"
namespace AlibabaCloud
@@ -189,6 +195,12 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::ExportStatisticalDataResult> ExportStatisticalDataOutcome;
typedef std::future<ExportStatisticalDataOutcome> ExportStatisticalDataOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::ExportStatisticalDataRequest&, const ExportStatisticalDataOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ExportStatisticalDataAsyncHandler;
typedef Outcome<Error, Model::GetInstanceConfigResult> GetInstanceConfigOutcome;
typedef std::future<GetInstanceConfigOutcome> GetInstanceConfigOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::GetInstanceConfigRequest&, const GetInstanceConfigOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetInstanceConfigAsyncHandler;
typedef Outcome<Error, Model::GetNewBargeInSwitchResult> GetNewBargeInSwitchOutcome;
typedef std::future<GetNewBargeInSwitchOutcome> GetNewBargeInSwitchOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::GetNewBargeInSwitchRequest&, const GetNewBargeInSwitchOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetNewBargeInSwitchAsyncHandler;
typedef Outcome<Error, Model::ListChatbotInstancesResult> ListChatbotInstancesOutcome;
typedef std::future<ListChatbotInstancesOutcome> ListChatbotInstancesOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::ListChatbotInstancesRequest&, const ListChatbotInstancesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListChatbotInstancesAsyncHandler;
@@ -231,6 +243,9 @@ namespace AlibabaCloud
typedef Outcome<Error, Model::SilenceTimeoutResult> SilenceTimeoutOutcome;
typedef std::future<SilenceTimeoutOutcome> SilenceTimeoutOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::SilenceTimeoutRequest&, const SilenceTimeoutOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> SilenceTimeoutAsyncHandler;
typedef Outcome<Error, Model::UpdateNewBargeInSwitchResult> UpdateNewBargeInSwitchOutcome;
typedef std::future<UpdateNewBargeInSwitchOutcome> UpdateNewBargeInSwitchOutcomeCallable;
typedef std::function<void(const VoiceNavigatorClient*, const Model::UpdateNewBargeInSwitchRequest&, const UpdateNewBargeInSwitchOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateNewBargeInSwitchAsyncHandler;
VoiceNavigatorClient(const Credentials &credentials, const ClientConfiguration &configuration);
VoiceNavigatorClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
@@ -314,6 +329,12 @@ namespace AlibabaCloud
ExportStatisticalDataOutcome exportStatisticalData(const Model::ExportStatisticalDataRequest &request)const;
void exportStatisticalDataAsync(const Model::ExportStatisticalDataRequest& request, const ExportStatisticalDataAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ExportStatisticalDataOutcomeCallable exportStatisticalDataCallable(const Model::ExportStatisticalDataRequest& request) const;
GetInstanceConfigOutcome getInstanceConfig(const Model::GetInstanceConfigRequest &request)const;
void getInstanceConfigAsync(const Model::GetInstanceConfigRequest& request, const GetInstanceConfigAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
GetInstanceConfigOutcomeCallable getInstanceConfigCallable(const Model::GetInstanceConfigRequest& request) const;
GetNewBargeInSwitchOutcome getNewBargeInSwitch(const Model::GetNewBargeInSwitchRequest &request)const;
void getNewBargeInSwitchAsync(const Model::GetNewBargeInSwitchRequest& request, const GetNewBargeInSwitchAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
GetNewBargeInSwitchOutcomeCallable getNewBargeInSwitchCallable(const Model::GetNewBargeInSwitchRequest& request) const;
ListChatbotInstancesOutcome listChatbotInstances(const Model::ListChatbotInstancesRequest &request)const;
void listChatbotInstancesAsync(const Model::ListChatbotInstancesRequest& request, const ListChatbotInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListChatbotInstancesOutcomeCallable listChatbotInstancesCallable(const Model::ListChatbotInstancesRequest& request) const;
@@ -356,6 +377,9 @@ namespace AlibabaCloud
SilenceTimeoutOutcome silenceTimeout(const Model::SilenceTimeoutRequest &request)const;
void silenceTimeoutAsync(const Model::SilenceTimeoutRequest& request, const SilenceTimeoutAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
SilenceTimeoutOutcomeCallable silenceTimeoutCallable(const Model::SilenceTimeoutRequest& request) const;
UpdateNewBargeInSwitchOutcome updateNewBargeInSwitch(const Model::UpdateNewBargeInSwitchRequest &request)const;
void updateNewBargeInSwitchAsync(const Model::UpdateNewBargeInSwitchRequest& request, const UpdateNewBargeInSwitchAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UpdateNewBargeInSwitchOutcomeCallable updateNewBargeInSwitchCallable(const Model::UpdateNewBargeInSwitchRequest& request) const;
private:
std::shared_ptr<EndpointProvider> endpointProvider_;

View File

@@ -37,6 +37,8 @@ namespace AlibabaCloud
std::string getConversationId()const;
void setConversationId(const std::string& conversationId);
std::string getHangUpParams()const;
void setHangUpParams(const std::string& hangUpParams);
std::string getInstanceId()const;
void setInstanceId(const std::string& instanceId);
long getInstanceOwnerId()const;
@@ -44,6 +46,7 @@ namespace AlibabaCloud
private:
std::string conversationId_;
std::string hangUpParams_;
std::string instanceId_;
long instanceOwnerId_;

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_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGREQUEST_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT GetInstanceConfigRequest : public RpcServiceRequest
{
public:
GetInstanceConfigRequest();
~GetInstanceConfigRequest();
std::string getInstanceId()const;
void setInstanceId(const std::string& instanceId);
private:
std::string instanceId_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGREQUEST_H_

View File

@@ -0,0 +1,68 @@
/*
* 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_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGRESULT_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT GetInstanceConfigResult : public ServiceResult
{
public:
struct Data
{
struct InstanceConfig
{
bool newBargeInSystemSwitch;
bool miniPlaybackSystemSwitch;
};
InstanceConfig instanceConfig;
};
GetInstanceConfigResult();
explicit GetInstanceConfigResult(const std::string &payload);
~GetInstanceConfigResult();
int getHttpStatusCode()const;
std::string getErrorMsg()const;
Data getData()const;
std::string getCode()const;
bool getSuccess()const;
protected:
void parse(const std::string &payload);
private:
int httpStatusCode_;
std::string errorMsg_;
Data data_;
std::string code_;
bool success_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETINSTANCECONFIGRESULT_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_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHREQUEST_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT GetNewBargeInSwitchRequest : public RpcServiceRequest
{
public:
GetNewBargeInSwitchRequest();
~GetNewBargeInSwitchRequest();
std::string getInstanceId()const;
void setInstanceId(const std::string& instanceId);
private:
std::string instanceId_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHREQUEST_H_

View File

@@ -0,0 +1,63 @@
/*
* 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_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHRESULT_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT GetNewBargeInSwitchResult : public ServiceResult
{
public:
struct Data
{
bool enable;
};
GetNewBargeInSwitchResult();
explicit GetNewBargeInSwitchResult(const std::string &payload);
~GetNewBargeInSwitchResult();
int getHttpStatusCode()const;
std::string getErrorMsg()const;
Data getData()const;
std::string getCode()const;
bool getSuccess()const;
protected:
void parse(const std::string &payload);
private:
int httpStatusCode_;
std::string errorMsg_;
Data data_;
std::string code_;
bool success_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_GETNEWBARGEINSWITCHRESULT_H_

View File

@@ -36,6 +36,7 @@ namespace AlibabaCloud
{
std::string skillGroup;
std::string conversationId;
bool hasLastPlaybackCompleted;
int endReason;
long endTime;
int rounds;

View File

@@ -0,0 +1,51 @@
/*
* 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_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHREQUEST_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHREQUEST_H_
#include <string>
#include <vector>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT UpdateNewBargeInSwitchRequest : public RpcServiceRequest
{
public:
UpdateNewBargeInSwitchRequest();
~UpdateNewBargeInSwitchRequest();
std::string getInstanceId()const;
void setInstanceId(const std::string& instanceId);
bool getEnable()const;
void setEnable(bool enable);
private:
std::string instanceId_;
bool enable_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHREQUEST_H_

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_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHRESULT_H_
#define ALIBABACLOUD_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/voicenavigator/VoiceNavigatorExport.h>
namespace AlibabaCloud
{
namespace VoiceNavigator
{
namespace Model
{
class ALIBABACLOUD_VOICENAVIGATOR_EXPORT UpdateNewBargeInSwitchResult : public ServiceResult
{
public:
UpdateNewBargeInSwitchResult();
explicit UpdateNewBargeInSwitchResult(const std::string &payload);
~UpdateNewBargeInSwitchResult();
int getHttpStatusCode()const;
std::string getErrorMsg()const;
std::string getCode()const;
bool getSuccess()const;
protected:
void parse(const std::string &payload);
private:
int httpStatusCode_;
std::string errorMsg_;
std::string code_;
bool success_;
};
}
}
}
#endif // !ALIBABACLOUD_VOICENAVIGATOR_MODEL_UPDATENEWBARGEINSWITCHRESULT_H_

View File

@@ -987,6 +987,78 @@ VoiceNavigatorClient::ExportStatisticalDataOutcomeCallable VoiceNavigatorClient:
return task->get_future();
}
VoiceNavigatorClient::GetInstanceConfigOutcome VoiceNavigatorClient::getInstanceConfig(const GetInstanceConfigRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return GetInstanceConfigOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return GetInstanceConfigOutcome(GetInstanceConfigResult(outcome.result()));
else
return GetInstanceConfigOutcome(outcome.error());
}
void VoiceNavigatorClient::getInstanceConfigAsync(const GetInstanceConfigRequest& request, const GetInstanceConfigAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, getInstanceConfig(request), context);
};
asyncExecute(new Runnable(fn));
}
VoiceNavigatorClient::GetInstanceConfigOutcomeCallable VoiceNavigatorClient::getInstanceConfigCallable(const GetInstanceConfigRequest &request) const
{
auto task = std::make_shared<std::packaged_task<GetInstanceConfigOutcome()>>(
[this, request]()
{
return this->getInstanceConfig(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
VoiceNavigatorClient::GetNewBargeInSwitchOutcome VoiceNavigatorClient::getNewBargeInSwitch(const GetNewBargeInSwitchRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return GetNewBargeInSwitchOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return GetNewBargeInSwitchOutcome(GetNewBargeInSwitchResult(outcome.result()));
else
return GetNewBargeInSwitchOutcome(outcome.error());
}
void VoiceNavigatorClient::getNewBargeInSwitchAsync(const GetNewBargeInSwitchRequest& request, const GetNewBargeInSwitchAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, getNewBargeInSwitch(request), context);
};
asyncExecute(new Runnable(fn));
}
VoiceNavigatorClient::GetNewBargeInSwitchOutcomeCallable VoiceNavigatorClient::getNewBargeInSwitchCallable(const GetNewBargeInSwitchRequest &request) const
{
auto task = std::make_shared<std::packaged_task<GetNewBargeInSwitchOutcome()>>(
[this, request]()
{
return this->getNewBargeInSwitch(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
VoiceNavigatorClient::ListChatbotInstancesOutcome VoiceNavigatorClient::listChatbotInstances(const ListChatbotInstancesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -1491,3 +1563,39 @@ VoiceNavigatorClient::SilenceTimeoutOutcomeCallable VoiceNavigatorClient::silenc
return task->get_future();
}
VoiceNavigatorClient::UpdateNewBargeInSwitchOutcome VoiceNavigatorClient::updateNewBargeInSwitch(const UpdateNewBargeInSwitchRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UpdateNewBargeInSwitchOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UpdateNewBargeInSwitchOutcome(UpdateNewBargeInSwitchResult(outcome.result()));
else
return UpdateNewBargeInSwitchOutcome(outcome.error());
}
void VoiceNavigatorClient::updateNewBargeInSwitchAsync(const UpdateNewBargeInSwitchRequest& request, const UpdateNewBargeInSwitchAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, updateNewBargeInSwitch(request), context);
};
asyncExecute(new Runnable(fn));
}
VoiceNavigatorClient::UpdateNewBargeInSwitchOutcomeCallable VoiceNavigatorClient::updateNewBargeInSwitchCallable(const UpdateNewBargeInSwitchRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UpdateNewBargeInSwitchOutcome()>>(
[this, request]()
{
return this->updateNewBargeInSwitch(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}

View File

@@ -38,6 +38,17 @@ void EndDialogueRequest::setConversationId(const std::string& conversationId)
setParameter("ConversationId", conversationId);
}
std::string EndDialogueRequest::getHangUpParams()const
{
return hangUpParams_;
}
void EndDialogueRequest::setHangUpParams(const std::string& hangUpParams)
{
hangUpParams_ = hangUpParams;
setParameter("HangUpParams", hangUpParams);
}
std::string EndDialogueRequest::getInstanceId()const
{
return instanceId_;

View File

@@ -0,0 +1,40 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/GetInstanceConfigRequest.h>
using AlibabaCloud::VoiceNavigator::Model::GetInstanceConfigRequest;
GetInstanceConfigRequest::GetInstanceConfigRequest() :
RpcServiceRequest("voicenavigator", "2018-06-12", "GetInstanceConfig")
{
setMethod(HttpRequest::Method::Post);
}
GetInstanceConfigRequest::~GetInstanceConfigRequest()
{}
std::string GetInstanceConfigRequest::getInstanceId()const
{
return instanceId_;
}
void GetInstanceConfigRequest::setInstanceId(const std::string& instanceId)
{
instanceId_ = instanceId;
setParameter("InstanceId", instanceId);
}

View File

@@ -0,0 +1,83 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/GetInstanceConfigResult.h>
#include <json/json.h>
using namespace AlibabaCloud::VoiceNavigator;
using namespace AlibabaCloud::VoiceNavigator::Model;
GetInstanceConfigResult::GetInstanceConfigResult() :
ServiceResult()
{}
GetInstanceConfigResult::GetInstanceConfigResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
GetInstanceConfigResult::~GetInstanceConfigResult()
{}
void GetInstanceConfigResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto dataNode = value["Data"];
auto instanceConfigNode = dataNode["InstanceConfig"];
if(!instanceConfigNode["MiniPlaybackSystemSwitch"].isNull())
data_.instanceConfig.miniPlaybackSystemSwitch = instanceConfigNode["MiniPlaybackSystemSwitch"].asString() == "true";
if(!instanceConfigNode["NewBargeInSystemSwitch"].isNull())
data_.instanceConfig.newBargeInSystemSwitch = instanceConfigNode["NewBargeInSystemSwitch"].asString() == "true";
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["HttpStatusCode"].isNull())
httpStatusCode_ = std::stoi(value["HttpStatusCode"].asString());
if(!value["Code"].isNull())
code_ = value["Code"].asString();
if(!value["ErrorMsg"].isNull())
errorMsg_ = value["ErrorMsg"].asString();
}
int GetInstanceConfigResult::getHttpStatusCode()const
{
return httpStatusCode_;
}
std::string GetInstanceConfigResult::getErrorMsg()const
{
return errorMsg_;
}
GetInstanceConfigResult::Data GetInstanceConfigResult::getData()const
{
return data_;
}
std::string GetInstanceConfigResult::getCode()const
{
return code_;
}
bool GetInstanceConfigResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,40 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/GetNewBargeInSwitchRequest.h>
using AlibabaCloud::VoiceNavigator::Model::GetNewBargeInSwitchRequest;
GetNewBargeInSwitchRequest::GetNewBargeInSwitchRequest() :
RpcServiceRequest("voicenavigator", "2018-06-12", "GetNewBargeInSwitch")
{
setMethod(HttpRequest::Method::Post);
}
GetNewBargeInSwitchRequest::~GetNewBargeInSwitchRequest()
{}
std::string GetNewBargeInSwitchRequest::getInstanceId()const
{
return instanceId_;
}
void GetNewBargeInSwitchRequest::setInstanceId(const std::string& instanceId)
{
instanceId_ = instanceId;
setParameter("InstanceId", instanceId);
}

View File

@@ -0,0 +1,80 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/GetNewBargeInSwitchResult.h>
#include <json/json.h>
using namespace AlibabaCloud::VoiceNavigator;
using namespace AlibabaCloud::VoiceNavigator::Model;
GetNewBargeInSwitchResult::GetNewBargeInSwitchResult() :
ServiceResult()
{}
GetNewBargeInSwitchResult::GetNewBargeInSwitchResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
GetNewBargeInSwitchResult::~GetNewBargeInSwitchResult()
{}
void GetNewBargeInSwitchResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto dataNode = value["Data"];
if(!dataNode["Enable"].isNull())
data_.enable = dataNode["Enable"].asString() == "true";
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["HttpStatusCode"].isNull())
httpStatusCode_ = std::stoi(value["HttpStatusCode"].asString());
if(!value["Code"].isNull())
code_ = value["Code"].asString();
if(!value["ErrorMsg"].isNull())
errorMsg_ = value["ErrorMsg"].asString();
}
int GetNewBargeInSwitchResult::getHttpStatusCode()const
{
return httpStatusCode_;
}
std::string GetNewBargeInSwitchResult::getErrorMsg()const
{
return errorMsg_;
}
GetNewBargeInSwitchResult::Data GetNewBargeInSwitchResult::getData()const
{
return data_;
}
std::string GetNewBargeInSwitchResult::getCode()const
{
return code_;
}
bool GetNewBargeInSwitchResult::getSuccess()const
{
return success_;
}

View File

@@ -59,6 +59,8 @@ void ListConversationsResult::parse(const std::string &payload)
conversationsObject.endReason = std::stoi(valueConversationsConversation["EndReason"].asString());
if(!valueConversationsConversation["Rounds"].isNull())
conversationsObject.rounds = std::stoi(valueConversationsConversation["Rounds"].asString());
if(!valueConversationsConversation["HasLastPlaybackCompleted"].isNull())
conversationsObject.hasLastPlaybackCompleted = valueConversationsConversation["HasLastPlaybackCompleted"].asString() == "true";
conversations_.push_back(conversationsObject);
}
if(!value["TotalCount"].isNull())

View File

@@ -0,0 +1,51 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/UpdateNewBargeInSwitchRequest.h>
using AlibabaCloud::VoiceNavigator::Model::UpdateNewBargeInSwitchRequest;
UpdateNewBargeInSwitchRequest::UpdateNewBargeInSwitchRequest() :
RpcServiceRequest("voicenavigator", "2018-06-12", "UpdateNewBargeInSwitch")
{
setMethod(HttpRequest::Method::Post);
}
UpdateNewBargeInSwitchRequest::~UpdateNewBargeInSwitchRequest()
{}
std::string UpdateNewBargeInSwitchRequest::getInstanceId()const
{
return instanceId_;
}
void UpdateNewBargeInSwitchRequest::setInstanceId(const std::string& instanceId)
{
instanceId_ = instanceId;
setParameter("InstanceId", instanceId);
}
bool UpdateNewBargeInSwitchRequest::getEnable()const
{
return enable_;
}
void UpdateNewBargeInSwitchRequest::setEnable(bool enable)
{
enable_ = enable;
setParameter("Enable", enable ? "true" : "false");
}

View File

@@ -0,0 +1,72 @@
/*
* 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.
*/
#include <alibabacloud/voicenavigator/model/UpdateNewBargeInSwitchResult.h>
#include <json/json.h>
using namespace AlibabaCloud::VoiceNavigator;
using namespace AlibabaCloud::VoiceNavigator::Model;
UpdateNewBargeInSwitchResult::UpdateNewBargeInSwitchResult() :
ServiceResult()
{}
UpdateNewBargeInSwitchResult::UpdateNewBargeInSwitchResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
UpdateNewBargeInSwitchResult::~UpdateNewBargeInSwitchResult()
{}
void UpdateNewBargeInSwitchResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["HttpStatusCode"].isNull())
httpStatusCode_ = std::stoi(value["HttpStatusCode"].asString());
if(!value["Code"].isNull())
code_ = value["Code"].asString();
if(!value["ErrorMsg"].isNull())
errorMsg_ = value["ErrorMsg"].asString();
}
int UpdateNewBargeInSwitchResult::getHttpStatusCode()const
{
return httpStatusCode_;
}
std::string UpdateNewBargeInSwitchResult::getErrorMsg()const
{
return errorMsg_;
}
std::string UpdateNewBargeInSwitchResult::getCode()const
{
return code_;
}
bool UpdateNewBargeInSwitchResult::getSuccess()const
{
return success_;
}