Ajax icon

Ajax

Consume Ajax API (v.0.1.2)

Actions242

Overview

This node, named "Ajax," is designed to interact with a broad Ajax API, providing a flexible interface to perform various operations on multiple resources. Specifically, for the Device resource and the Get Device Info operation, it retrieves detailed information about a particular device identified by user ID, hub ID, and device ID.

Common scenarios where this node is beneficial include:

  • Fetching real-time or stored metadata about devices in an IoT or smart home system.
  • Integrating device status or configuration details into workflows for monitoring or automation.
  • Querying device-specific data as part of larger processes involving users and hubs.

For example, a workflow could use this node to get the current state of a security camera device before triggering alerts or recording events.

Properties

Name Meaning
User Id The unique identifier of the user who owns or manages the device.
Hub Id The unique identifier of the hub to which the device is connected or associated.
Device Id The unique identifier of the device whose information is being requested.

These properties are required inputs when performing the "Get Device Info" operation on the "Device" resource.

Output

The node outputs JSON data containing the detailed information of the specified device. This typically includes all relevant device attributes as returned by the Ajax API, such as device status, configuration, metadata, and possibly operational metrics.

If the API supports binary data related to the device (e.g., firmware files, images), the node can also output binary data accordingly, but this is not explicitly shown in the provided code snippet.

Dependencies

  • Requires an API key credential for authenticating with the Ajax API service.
  • Depends on internal modules handling HTTP requests, state management, and operation resolution.
  • The node uses a bundled HTTP client to communicate with the backend Ajax API.
  • No additional external services beyond the Ajax API are indicated.

Troubleshooting

  • Missing or invalid credentials: Ensure that a valid API authentication token is configured in the node's credentials.
  • Incorrect property values: Verify that the User Id, Hub Id, and Device Id are correct and correspond to existing entities in the Ajax system.
  • API errors or timeouts: Network issues or server-side problems may cause failures; check connectivity and API status.
  • Operation or resource mismatch: Confirm that the selected resource is "Device" and operation is "Get Device Info" to avoid unsupported combinations.

Common error messages will likely relate to authentication failures, missing parameters, or resource not found errors. Resolving these involves checking credentials, input correctness, and API availability.

Links and References

Discussion