aliyun-iot-sdk
v0.1.1
Published
Aliyun Server Side IoT SDK for Node.js.(阿里云 IoT 服务端 Node.js SDK)
Downloads
12
Readme
aliyun-iot-sdk
♥ 🇹🇸 纯 TypeScript 实现,提供完整声明文件
Aliyun Server Side IoT SDK for Node.js.(阿里云 IoT 服务端 Node.js SDK)
旧版 API
查看旧版 (0.0.5) API 点击此处
使用示例
import { Client } from 'aliyun-iot-sdk'
// 新建客户端
const client = new Client({
accessKeyId: '<xxxxx>',
accessKeySecret: '<xxxxx>',
regionId: 'cn-shanghai'
})
// 调用接口
client.request({
Action: 'GetDeviceShadow',
DeviceName: 'test',
ProductKey: 'test'
})
API
新建客户端
- new Client()
发送请求
Client.request(requestParameters)
- requestParameters 请求参数,目前已经添加类型声明的接口在下面的列表中,对于没有添加类型声明的接口,使用 ts 时用
as any
过度 - 返回值是一个 axios 的请求结果
- requestParameters 请求参数,目前已经添加类型声明的接口在下面的列表中,对于没有添加类型声明的接口,使用 ts 时用
声明文件完成进度
- 产品管理
- [x] createProduct
- [ ] updateProduct
- [ ] queryProductList
- [ ] queryProduct
- [ ] deleteProduct
- [ ] createProductTags
- [ ] updateProductTags
- [ ] deleteProductTags
- [ ] listProductTags
- [ ] listProductByTags
- 设备管理
- [ ] registerDevice
- [ ] queryDeviceDetail
- [ ] queryDevice
- [ ] deleteDevice
- [ ] getDeviceStatus
- [ ] batchGetDeviceState
- [ ] disableThing
- [ ] enableThing
- [ ] batchCheckDeviceNames
- [ ] batchRegisterDeviceWithApplyId
- [ ] batchRegisterDevice
- [ ] queryBatchRegisterDeviceStatus
- [ ] queryPageByApplyId
- [ ] queryDeviceEventData
- [ ] queryDevicePropertyData
- [ ] queryDevicePropertiesData
- [ ] queryDeviceServiceData
- [ ] invokeThingService
- [ ] invokeThingsService
- [ ] queryDevicePropertyStatus
- [ ] setDeviceProperty
- [ ] setDevicesProperty
- [ ] saveDeviceProp
- [ ] queryDeviceProp
- [ ] deleteDeviceProp
- [ ] getThingTopo
- [ ] notifyAddThingTopo
- [ ] removeThingTopo
- [ ] queryDeviceStatistics
- [ ] getGatewayBySubDevice
- [ ] queryDeviceByTags
- [ ] setDeviceDesiredProperty
- [ ] queryDeviceDesiredProperty
- [ ] queryDeviceFileList
- [ ] queryDeviceFile
- [ ] deleteDeviceFile
- [ ] batchUpdateDeviceNickname
- [ ] queryLoRaJoinPermissions
- [ ] createLoRaNodesTask
- [ ] getLoraNodesTask
- 分组管理
- [ ] createDeviceGroup
- [ ] deleteDeviceGroup
- [ ] updateDeviceGroup
- [ ] queryDeviceGroupInfo
- [ ] queryDeviceGroupList
- [ ] batchAddDeviceGroupRelations
- [ ] batchDeleteDeviceGroupRelations
- [ ] setDeviceGroupTags
- [ ] queryDeviceGroupTagList
- [ ] queryDeviceGroupByDevice
- [ ] querySuperDeviceGroup
- [ ] queryDeviceListByDeviceGroup
- [ ] queryDeviceGroupByTags
- 规则引擎
- [ ] listRule
- [ ] createRule
- [ ] getRule
- [ ] updateRule
- [ ] deleteRule
- [ ] listRuleActions
- [ ] getRuleAction
- [ ] createRuleAction
- [ ] updateRuleAction
- [ ] deleteRuleAction
- [ ] startRule
- [ ] stopRule
- Topic 管理
- 消息通信
- [x] pub
- [x] rRpc
- [x] pubBroadcast
- 设备影子