【问题标题】:"Unsupported protocol element" when creating Interactions programmatically以编程方式创建交互时出现“不支持的协议元素”
【发布时间】:2015-05-20 12:11:25
【问题描述】:

我正在尝试在 Genesys Platform SDK 8.5 for Java 上以编程方式创建新的交互。

我用API reference上的例子

public void createInteraction(String ixnType, String ixnSubtype, String queue) throws Exception
{
    RequestSubmit req = RequestSubmit.create();
    req.setInteractionType(ixnType);
    req.setInteractionSubtype(ixnSubtype);
    req.setQueue(queue);
    req.setMediaType("email");

    Message response = mPMService.getProtocol("IxnSrv").request(req);
    if(response == null || response.messageId() != EventAck.ID) {
          // For this sample, no error handling is implemented
          return;
    }

    EventAck event = (EventAck)response;
    mInteractionId = event.getExtension().getString("InteractionId");
}

但是,这给了我一个不支持的协议元素错误。

'EventError' (126) attributes:
    attr_error_desc [str] = "Unsupported protocol element"
    attr_ref_id [int] = 2
    attr_error_code [int] = 4

如何以编程方式创建新的交互?

【问题讨论】:

    标签: java genesys


    【解决方案1】:

    对于此请求(RequestSubmit),交互服务器应以 MediaServer 或 AgentApplication 的形式与 ClientType 连接。

    【讨论】:

      【解决方案2】:

      首先,您必须将协议作为媒体服务器打开。之后,您必须将交互提交到交互服务器。

      首先你的协议配置必须是这样的;

                  interactionServerConfiguration.ClientName = "TestClient";
                  interactionServerConfiguration.ClientType = InteractionClient.MediaServer;
      
                  // Register this connection configuration with Protocol Manager
                  protocolManagementService.Register(interactionServerConfiguration);
      

      注意:您的配置环境中必须有 MediaServer 类型的应用程序定义,您必须在 CME 中看到它。 打开后连接到 ixn 服务器。您可以提交您喜欢的互动。甚至你也可以像我一样创建新类型的交互。我为我们的合作短信系统做过。它的名字并不重要。我们在我们的业务属性中定义了它,因此我们的代理可以从他们的代理桌面发送 coopate 3rd 方短信系统。没有新的扩展或新的许可证:) 只是欺骗了它系统。也genesys允许它。我知道,因为我们是我们国家的genesys官方支持团队:)(但可能需要代理席位许可证,具体取决于代理人数)。

          RequestSubmit request = RequestSubmit.Create();
          request.TenantId = 1;
          request.MediaType = "email";
          request.Queue = c_inboundQueue;
          request.InteractionType = "Inbound";
          request.InteractionSubtype = "InboundNew";
      
          // Prepare the message to send. It is inserted in the request as UserData
          KeyValueCollection userData =
              new KeyValueCollection();
      
          // Prepare the message to send
          userData.Add("Subject", "subject goes here");
          request.UserData = userData;   protocolManagementService[c_interactionServerConfigurationIdentifier].Send(request);            
      

      【讨论】:

        【解决方案3】:

        原来我需要将 ClientType 设置为 InteractionClient.ReportingEngine。

        【讨论】:

          猜你喜欢
          • 2012-06-01
          • 1970-01-01
          • 1970-01-01
          • 2020-11-07
          • 1970-01-01
          • 1970-01-01
          • 1970-01-01
          • 2019-12-16
          • 1970-01-01
          相关资源
          最近更新 更多