# What is an agent?
An agent is a standalone application that can interact with multiple devices by implementing one or more communication protocols, where each of these devices is represented by a thing in the IoTHub. Agents communicate with the IoTHub via its Gateway module with a dedicated port number for data exchange.
Each time you create a new agent, the IoTHub will automatically generate new unique identifiers (id
and token
) for it. Then, you can use these identifiers for executing a particular agent as described in the following sections.