Detailed Explanation 3 of Edge Computing Framework EdgeX Foundry (Introduction and Use of RESTful API Interface)

edge computing



Introduction and use of RESTful API

Introduction and use of RESTful API

1. Interface introduction

EdgeX Foundry 各个微服务都提供了相应的 RESTful API 接口供我们调用,我们可以通过这些接口进行设备注册、推送客户端注册、数据(日志、事件、配置...)查看等等操作。具体的接口介绍可以查看官方在线文档:

API interface description: https://docs.edgexfoundry.org/Ch-APIReference.html

2. Interface call

平时开发测试时,我们可以使用 Postman 工具发送请求调用接口。比如下面我们查看当前 EdgeX Foundry 这边注册的所有输出客户端:

Original text: Detailed Explanation 3 of Edge Computing Framework EdgeX Foundry (Introduction and Use of RESTful API Interface)

3. Import the interface file

(1) The EdgeX Foundry interface is very rich, and it will be very troublesome to manually input one by one on the Postman side. Fortunately, the official has prepared the raml interface description document for us, we can directly import it into Post and use it.

(2) First go to its GitHub homepage (click to jump), and download the source code to the local, where the raml interface description document is in the api/raml folder: Original: Edge Computing Framework EdgeX Foundry Use Detailed Explanation 3 (RESTful API Interface Introduction
and use)

(3) Open Postman and click the Import button on the upper left.
Original text: Detailed Explanation 3 of Edge Computing Framework EdgeX Foundry (Introduction and Use of RESTful API Interface)

(4) Drag the previously downloaded raml file into the pop-up box to complete the import.
Original text: Detailed Explanation 3 of Edge Computing Framework EdgeX Foundry (Introduction and Use of RESTful API Interface)

(5) After importing, we switch to the Collections tab, and we can see that there are all interfaces here. We double-click any interface, and the right side will automatically fill in the relevant content for us to call.

Guess you like

Origin blog.csdn.net/zyq880625/article/details/131342674