Ajax icon

Ajax

Consume Ajax API (v.0.1.2)

Actions242

Overview

This node, named "Ajax," is designed to interact with a specific Ajax API (version indicated in the code). It supports multiple resources and operations, including the "Installation" resource with the operation "Get Hubs On Installation For Company." The node fetches data from the Ajax backend system, allowing users to retrieve information such as hubs associated with an installation for a given company.

A common use case is when a user wants to programmatically obtain details about hubs installed for a particular company within the Ajax system. For example, a facilities manager could automate the retrieval of hub data to monitor installations across multiple company sites.

Properties

Name Meaning
Company Id The unique identifier of the company for which to get hubs on installation. (Required)
Additional Fields Optional parameters to control pagination:
- Offset: Number of items to skip before starting to collect the result set (default 0)
- Limit: Maximum number of items to return (default 10)

Output

The node outputs JSON data representing the hubs associated with the specified company's installation. The exact structure depends on the Ajax API response but typically includes details about each hub such as its ID, status, location, and other relevant metadata.

If the node supports binary data output, it would represent any non-JSON content returned by the API; however, based on the provided code and context, the primary output is JSON data.

Dependencies

  • Requires an API key credential for authenticating with the Ajax API.
  • Depends on the @digital-boss/n8n-designpatterns package for response-operation resolution and execution logic.
  • Uses internal backend modules for state management, HTTP client communication, and operation handling.
  • The node expects proper configuration of the Ajax API credentials within n8n.

Troubleshooting

  • Authentication errors: Ensure that the API key credential is correctly configured and has sufficient permissions.
  • Invalid Company Id: If the company ID is incorrect or does not exist, the API may return an error or empty results.
  • Pagination issues: When using offset and limit, verify that values are within acceptable ranges to avoid empty responses.
  • Network or API downtime: Connectivity problems or Ajax API outages will cause request failures; check network status and retry later.
  • Unexpected response format: If the API changes, the node might fail to parse the response correctly; updating the node or checking API documentation is advised.

Links and References

Discussion