繁体   English   中英

通过移动应用程序 Thingworx 的 Things Service 使用用户名密码登录实现

[英]Login Implementation with username password via Things Service for mobile application Thingworx

我正在开发一个通过 REST API 与 TWX 通信的移动应用程序。 我创建了 MobileConnector_TH,它具有提取数据并通过 HTTP Rest API 将其恢复到移动设备的服务。

问题陈述:-

我有一项用 MobileConnector_TH 编写的服务 - validateUser(Username, Password)

其中包含以下代码

var params = {

            url: me.IPUrl+"/Thingworx/action-login?OrganizationName="+organization+"&thingworx-form-userid="+username+"&thingworx-form-password="+password+"&x-thingworx-session=true" /* STRING */,

            contentType: "text/html" /* STRING */

        };



        // result: STRING

        var result = Resources["ContentLoaderFunctions"].GetText(params);

这会将 HTML 网页数据返回到字符串中。 我无法找到任何特定方案来通过服务验证用户名和密码。 它使用错误的密码/用户名显示相同的结果。

https://community.ptc.com/t5/ThingWorx-Developers/Authentication-with-User-Credentials-via-Rest-Api/td-p/585890

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM