【问题标题】:401 Unauthorized when getting app list for LG TV Using ConneckSDK使用 ConneckSDK 获取 LG TV 应用列表时出现 401 Unauthorized
【发布时间】:2018-11-01 12:07:09
【问题描述】:

使用ConnectSDK。我可以成功连接到设备并运行 device.launcher().launchNetflix() 实际上会启动 Netflix。但是,大多数应用程序都是使用device.launcher().launchApp(appID: String) 启动的,但我无法找到每个应用程序的 appID 是什么。我最初的想法是使用device.launcher().getAppList() 来获取应用程序列表并将它们加载到表格视图中,但这会引发 401 用户未授权错误。

【问题讨论】:

  • 401 user not authorized 的哪一部分你不明白?
  • 我无权在自己的电视上查看应用程序的部分。

标签: ios swift webos live-connect-sdk


【解决方案1】:

certain features 似乎需要额外的配对步骤,仅连接是不够的。可以在here 找到配对说明。只需向下滚动到显示“配对级别”的位置。基本上你的代码应该是这样的:

discoveryManager = DiscoveryManager.shared()
discoveryManager?.pairingLevel = DeviceServicePairingLevelOn
discoveryManager?.startDiscovery()

这将要求用户将电视中的代码输入到您的应用中。配对后,大多数这些功能的 401 错误应该会消失。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-02-02
    • 1970-01-01
    • 1970-01-01
    • 2017-09-04
    • 1970-01-01
    相关资源
    最近更新 更多