Skip to content
  • Linkedin
  • Youtube
  • Pinterest
  • Home
  • Privacy Policy
  • About
  • Contact
Programmingoneonone

Programmingoneonone

Programmingoneonone is a website that publishes daily tutorials, methods, guides, and articles on IT, Education, and technology.

  • Home
  • Human Values
  • DSA
  • IoT Tutorials
  • Interview Questions and Answers
  • Toggle search form
iot(Internet of things) communication apis

IoT Communication API

Posted on 9 May 202226 April 2023 By YASH PAL No Comments on IoT Communication API

IoT Communication API is the point of interaction between an IoT device and the internet and/or other elements within the network. Representational State Transfer (REST) is a set of architectural principles where we can design Web services the Web APIS that focus on the system’s resource and how resource states are addressed and transferred.

IoT Communication API

REST APIS follows the request-response, communication model. REST architectural constraints apply to the components, connectors, and data elements, within a distributed hypermedia system. A RESTful web service is a ” Web API ” implemented using HTTP and REST principles. REST is the most popular lol Communication APIS. The rest architectural constraint is as follows:

Client-server

The function of the client-server constraint is the separation of concerns, for example, clients should not be concerned with the storage of data which is a concern of the server. furthermore, the server should not be concerned about the user interface which is a concern of the client. Separation allows the client and server to be independently developed and updated.

Stateless

When a request is sent from a client to the server. It must contain all the necessary information to understand the request and cannot take advantage of any stored context on the server. The session state is kept entirely on the client.

Cache-able

The principle behind the cachable constraint is that the data within a response to a request be implicitly or explicitly leveled as cache-able or non-cache-able. If a response is cacheable, then a client cache is given the right to reuse that response data for later, the same as the request. Caching can partially or completely eliminate some instructions and improve efficiency and scalability.

Layered System

The work of layered system constraint is to necessitate the behavior of components in that each component cannot see beyond the immediate layer with which they are interacting. For example, the client cannot tell whether it is connected directly to the end server or two an intermediary along the way. System scalability can be improved by allowing intermediaries to respond to requests instead of the end server, without the client having to do anything different.

Uniform Interface

The main aim of the uniform interface constraint is that the communication between the client and server must be uniform. Resources are identified in the requests and are themselves separate from the representations of the resource data returned to the client.

When a client holds a representation of resources it has all the information required to update or delete the resource. Each message includes sufficient information to explain how to process the message.

Code on Demand

This constraint is the only one that is optional. Servers can provide executable code for clients to execute in their context.

Web Socket-Based Communication API

Web Socket APIS is a full-duplex communication between clients and servers. It allows bi-directional communication and Web Socket APIS pursues the exclusive pair communication model. Unlike request-response models such as REST, web sockets do not require a new connection to be set up for each message to be sent.

Web Socket communication starts with a connection setup request sent by the client to the server. The request is sent over HTTP and the server interprets it as an upgrade request. If the server supports web socket protocol, the server responds to the Web Socket handshake response. After the connection setup, the client and server can send data/messages to each other in full-duplex mode.

Weh socket API reduces the network traffic and latency as there is no overhead for connection setup and termination requests for each message. Web sockets are suitable for IoT applications that have low latency or high throughput requirements.

Other IoT Tutorials

  • IoT Enabling Technologies
  • Embedded System in IoT
Computer Science Tutorials, Internet of Things Tutorials Tags:computer science, IOT

Post navigation

Previous Post: IoT Levels – Deployment Templates
Next Post: IoT Enabling Technologies

Related Tutorials

Reading input in c programming Reading Input in a C program C Programming Tutorials
The First C Program C Programming Tutorials
Compiling C Programs C Programming Tutorials
History of c programming language HISTORY OF C Programming Language C Programming Tutorials
c character sets C Character Sets C Programming Tutorials
c programming interview questions and answers C Programming Interview Questions and Answers C Programming Tutorials

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Pick your Subject

  • Internet of Things
  • Data Structures/Algorithms
  • Interview Preparation
  • Human Values
  • Java Interview Questions and Answers (2023)
    Thinking of becoming a Java developer? I must say it’s a good choice! Java is continuously named the most popular programming language. And the...

    Learn More “Java Interview Questions and Answers (2023)” »

  • Iot(Internet of things) in healthcare
    IoT in Healthcare
    IoMT (Internet of Medical Things) stands for devices that can collect and exchange data – either with users or other devices via the internet,...

    Learn More “IoT in Healthcare” »

  • four stages of iot solution for industry
    IoT for Industry
    In this post, we are going to learn about use cases of IoT for Industry and four stages for providing IoT solutions. Machine Diagnosis...

    Learn More “IoT for Industry” »

  • Iot for agricultural
    IoT in Agriculture
    IoT technology has realized smart wearables, connected devices, automated machines, and driverless cars. However, in agriculture, the IoT has brought the greatest impact. Amongst the challenges...

    Learn More “IoT in Agriculture” »

  • Iot for logistics
    IoT in Logistics and Supply Chain
    IoT applications for smart logistics and supply chain systems:  Logistics Fleet Tracking  To track the locations of the vehicles in real time, the vehicle...

    Learn More “IoT in Logistics and Supply Chain” »

  • Algorithms Tutorials
  • Basic Programming
  • C Programming Tutorials
  • C++ Tutorials
  • Compiler Design Tutorials
  • Computer Networks Tutorials
  • Computer Organization Tutorials
  • Computer Science Tutorials
  • Data Structures Tutorials
  • DBMS Tutorials
  • Developer Guide
  • Digital Communication
  • Digital Logic Tutorials
  • Internet of Things Tutorials
  • Internet Tutorials
  • Interview questions answers
  • Java Tutorials
  • Javascript Tutorials
  • Machine Learning Tutorials
  • Operating Systems Tutorials
  • Programming Tutorials
  • Projects
  • Tips&Tricks
  • Tools
  • VBScript Tutorials
  • Java Interview Questions and Answers (2023)
    Thinking of becoming a Java developer? I must say it’s a good choice! Java is continuously named the most popular programming language. And the...

    Learn More “Java Interview Questions and Answers (2023)” »

  • Iot(Internet of things) in healthcare
    IoT in Healthcare
    IoMT (Internet of Medical Things) stands for devices that can collect and exchange data – either with users or other devices via the internet,...

    Learn More “IoT in Healthcare” »

  • four stages of iot solution for industry
    IoT for Industry
    In this post, we are going to learn about use cases of IoT for Industry and four stages for providing IoT solutions. Machine Diagnosis...

    Learn More “IoT for Industry” »

  • Iot for agricultural
    IoT in Agriculture
    IoT technology has realized smart wearables, connected devices, automated machines, and driverless cars. However, in agriculture, the IoT has brought the greatest impact. Amongst the challenges...

    Learn More “IoT in Agriculture” »

  • Iot for logistics
    IoT in Logistics and Supply Chain
    IoT applications for smart logistics and supply chain systems:  Logistics Fleet Tracking  To track the locations of the vehicles in real time, the vehicle...

    Learn More “IoT in Logistics and Supply Chain” »

Copyright © 2023 Programmingoneonone.

Powered by PressBook Blog WordPress theme