仮想デバイス の大量作成
    • PDF

    仮想デバイス の大量作成

    • PDF

    Article Summary

    概要

    仮想デバイスを一度に大量作成します。

    リクエスト

    リクエストURL

    POST {CLOUD_IOT_CORE_API_URL}/devices/bulk
    
    Content-Type: application/json; charset=utf-8
    x-ncp-apigw-timestamp: {Timestamp}
    x-ncp-iam-access-key: {Sub Account Access Key}
    x-ncp-apigw-signature-v2: {API Gateway Signature}
    

    リクエストボディー

    {
       "devices":[
          {
             "device":{
                "name":"string",
                "description":"string"
             },
             "deviceProperties":{
                "createUpdateList":[
                   {
                      "key":"string",
                      "value":"string"
                   }
                ]
             }
          }
       ]
    }
    
    項目必須の有無タイプ制約事項説明
    devices[].device.nameYesstring128字以内のアルファベットの大文字小文字、数字、-、_のみ許可仮想デバイス名
    devices[].device.descriptionYesstring128文字以内のみ許可
    &、<、>、"、' は非許可
    仮想デバイスの説明
    devices[].deviceProperties.createUpdateList[].keyYesstring128字以内のアルファベットの大文字小文字、数字、-、_のみ許可仮想デバイス属性 Key。 同一のキーを探して情報を修正します。 既存の保存されているキーが要求ボディにない場合は削除されます。
    devices[].deviceProperties.createUpdateList[].valueNostring512字以内のアルファベットの大文字小文字、数字、-、_のみ許可仮想デバイス属性 Value

    レスポンス

    レスポンスボディ

    {
        "status": "string",
        "body": {
            "devices":[
                {
                    "device":{
                        "name":"string",
                        "description":"string",
                        "modifyTime": "localDateTime",
                        "registerTime": "localDateTime"
                    },
                    "deviceProperties":{
                        "createUpdateList":[
                            {
                                "key":"string",
                                "value":"string",
                                "modifyTime": "localDateTime",
                                "registerTime": "localDateTime"
                            }
                        ]
                    }
                }
            ]
        }
    }
    
    項目タイプ説明
    statusstringレスポンスの成否
    body.devices[].device.namestring仮想デバイス名
    body.devices[].device.descriptionstring仮想デバイス説明
    body.devices[].device.modifyTimelocalDateTime仮想デバイスの最終修正日
    body.devices[].device.registerTimelocalDateTime仮想デバイスの作成日
    body.devices[].deviceProperties.createUpdateList[].keystring仮想デバイス属性 Key
    body.devices[].deviceProperties.createUpdateList[].valuestring仮想デバイス属性 Value
    body.devices[].deviceProperties.createUpdateList[].modifyTimelocalDateTime仮想デバイス属性の最終修正日
    body.devices[].deviceProperties.createUpdateList[].registerTimelocalDateTime仮想デバイス属性の作成日

    {
        "status": "SUCCESS",
        "body": {
            "devices": [
                {
                    "device": {
                        "name": "bulb",
                        "description": "bulb in living room",
                        "modifyTime": "2022-04-18 14:15:50",
                        "registerTime": "2022-04-18 14:15:50"
                    },
                    "deviceProperties": {
                        "createUpdateList": [
                            {
                                "key": "lux",
                                "value": "2000",
                                "modifyTime": "2022-04-18 14:15:51",
                                "registerTime": "2022-04-18 14:15:51"
                            },
                            {
                                "key": "ampere",
                                "value": "5",
                                "modifyTime": "2022-04-18 14:15:51",
                                "registerTime": "2022-04-18 14:15:51"
                            }
                        ]
                    }
                }
            ]
        }
    }
    

    この記事は役に立ちましたか?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.