-
Notifications
You must be signed in to change notification settings - Fork 8
System Profile
TakayukiHoshi1984 edited this page Mar 27, 2017
·
3 revisions
| API | 機能概要 |
|---|---|
| System API | スマートフォンのシステム情報を提供するAPI Device Connect ManagerのバージョンやサポートするAPI一覧、インストールされているデバイスプラグイン一覧などのアプリケーション情報を取得する。 |
| Device System Wakeup API | デバイスプラグインの機能を有効にする。デバイスプラグインによっては、設定画面が起動してデバイスとの接続を行う。 |
| System Events Unregister API | 指定されたセッションキーに紐づくイベントを一挙に解除する。 |
| System Show Keyword API | Device Connect Managerに対し、ユーザーが登録したキーワードの表示要求をする。 |
スマートフォンまたは周辺機器(デバイスプラグイン)のシステム情報を提供するAPI。
なし
| インターフェース名称 | Version | 種別 |
|---|---|---|
| System API | 2.0.0 | 同期I/F |
スマートフォンのシステム情報を提供するAPI Device Connect ManagerのバージョンやサポートするAPI一覧、インストールされているデバイスプラグイン一覧などのアプリケーション情報を取得する。
| HTTPメソッド | URI |
|---|---|
| GET | /gotapi/system |
| Content-Type | 形式 | HTTPステータス |
|---|---|---|
| application/json | JSON | 200 |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 | |
| 処理結果 | result | number | - | 0:正常応答 0以外:異常応答 |
|
| バージョン | version | string | - | Device Connect Manager バージョンの文字列。 | |
| サポートプロファイルリスト | supports | string[] | - | サポートしているI/Fのプロファイル名一覧を格納する。 | |
| プラグイン一覧 | plugins | object[] | - | サポートしているプラグインの一覧を格納する。 | |
| 属性値 | id | string | - | デバイスプラグインを識別するID。 | |
| 属性値 | name | string | - | デバイスプラグイン名 | |
| 属性値 | version | string | - | デバイスプラグインのバージョン名 | |
| 属性値 | supports | string[] | - | デバイスプラグインのサポートするプロファイル名の配列。 | |
| 属性値 | packageName | string | ○ | デバイスプラグインのパッケージ名。 | |
GET http://localhost:4035/gotapi/system?accessToken=yyyyy
{
"product":"Device Connect Manager",
"version":"x.x",
"result":0,
"version":"1.0",
"supports":[
"authorization",
"availability",
"servicediscovery",
"serviceinfomation",
"system"
],
"plugins": [
{
"id": "xxx1.localhost.deviceconnect.org",
"name": "Exampleデバイスプラグイン",
"version": "1.0.0",
"supports": [
"authorization",
"battery",
"servicediscovery",
"serviceinfomation",
"system"
],
"packageName": "com.example.deviceplugin"
},
{
"id": "xxx2.localhost.deviceconnect.org",
"name": "Sampleデバイスプラグイン",
"version": "1.0.0",
"supports": [
"authorization",
"light",
"servicediscovery",
"serviceinfomation",
"system"
],
"packageName": "com.sample.deviceplugin"
}
]
}
| インターフェース名称 | Version | 種別 |
|---|---|---|
| Device System WakeUp API | 2.0.0 | 同期I/F |
デバイスプラグインの機能を有効にする。 デバイスプラグインによっては、設定画面が起動してデバイスとの接続を行う。
| HTTPメソッド | URI |
|---|---|
| PUT | /gotapi/system/device/wakeup |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 |
|---|---|---|---|---|
| プラグインID | pluginId | string | - | 取得対象デバイスプラグイン |
| Content-Type | 形式 | HTTPステータス |
|---|---|---|
| application/json | JSON | 200 |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 |
|---|---|---|---|---|
| 処理結果 | result | number | - | 0:正常応答 0以外:異常応答 |
PUT http://localhost:4035/gotapi/system/device/wakeup ```
| PUTデータ |
|---|
| pluginId=xxxxx.localhost.deviceconnect.org&accessToken=yyyy |
{
"product":"Device Connect Manager",
"version":"x.x",
"result":0
}
| インターフェース名称 | Version | 種別 |
|---|---|---|
| System Event Unregister API | 2.0.0 | 同期I/F |
指定されたセッションキーに紐づくイベントを一挙に解除する。
| HTTPメソッド | URI |
|---|---|
| DELETE | /gotapi/system/events |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 |
|---|---|---|---|---|
| セッションID | sessionKey | string | - | イベントセッションID |
| Content-Type | 形式 | HTTPステータス |
|---|---|---|
| application/json | JSON | 200 |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 |
|---|---|---|---|---|
| 処理結果 | result | number | - | 0:正常応答 0以外:異常応答 |
DELETE http://localhost:4035/gotapi/system/events?sessionKey=xxx&accessToken=xxxxx
{
"product":"Device Connect Manager",
"version":"x.x",
"result":0
}
| インターフェース名称 | Version | 種別 |
|---|---|---|
| System Show Keyword API | 2.0.0 | 同期I/F |
Device Connect Managerに対し、ユーザーが登録したキーワードの表示要求をする。
| HTTPメソッド | URI |
|---|---|
| PUT | /gotapi/system/keyword |
| Content-Type | 形式 | HTTPステータス |
|---|---|---|
| application/json | JSON | 200 |
| 論理名 | 物理名 | データ型 | 省略 | 設定値 |
|---|---|---|---|---|
| 処理結果 | result | number | - | 0:正常応答 0以外:異常応答 |
PUT http://localhost:4035/gotapi/system/keyword
{
"product":"Device Connect Manager",
"version":"x.x",
"result":0
}