Contractors.es icon

Contractors.es

Interact with Contractors.es API

Actions995

Inventory Api → Post Api Assets Inventory Batch

AI-generated

Summary

Submits a batch of assets to the Contractors.es Inventory API and returns the server's response.

Inputs

  • resources (required) — JSON array of asset records to post. If the value contains 'DO_NOT_SET', it is sent as undefined.
  • requestOptions — Collection of HTTP options including batching configuration, timeout, proxy settings, and SSL handling.

Output shape

An array of response items (usually the API's batch response).

The exact shape depends on the API's response structure. The node sends a POST request to the Inventory API endpoint with the provided resources.

Examples

Example 1: Post a list of 50 new assets using the default batching settings.

Set resources to a JSON array of 50 items; leave requestOptions with default batching (batchSize: 50, batchInterval: 1000ms).

Example 2: Post a large payload in smaller chunks to avoid throttling.

Set resources to a large array; configure requestOptions.batching.batchSize to a lower number (e.g., 10) and batchInterval to 1000ms.

Links

Discussion