Contractors.es icon

Contractors.es

Interact with Contractors.es API

Actions995

Inventory Notes Relation Api → Post Api Assets Inventory Inventory Notes

AI-generated

Summary

Creates a new inventory note record for a specified inventory item, optionally including attachments, permissions, and alerts.

Inputs

  • inventory (required) — The ID of the inventory item to attach the note to.
  • title — The title of the note. If set to 'DO_NOT_SET' or 'DO_NOT_UPDATE', the field is omitted from the request.
  • note — The content of the note. If set to 'DO_NOT_SET' or 'DO_NOT_UPDATE', the field is omitted from the request.
  • files — Array of attachments. Each item can be a file upload or a base64 payload string (raw, data URI, or named). If set to 'DO_NOT_SET' or 'DO_NOT_UPDATE', the field is omitted from the request.
  • permission — Visibility level: 1 - public, 2 - public (read-only), 3 - private. Defaults to 'DO_NOT_SET' (omitted).
  • sticky — Whether the note is sticky. Defaults to 'DO_NOT_SET' (omitted).
  • category_id — The category ID for the note. Defaults to 'DO_NOT_SET' (omitted).
  • alert — Alert configuration text. Defaults to 'DO_NOT_SET' (omitted).
  • alert_grid — Grid-specific alert configuration. Defaults to 'DO_NOT_SET' (omitted).
  • alert_to — Recipient for alerts. Defaults to 'DO_NOT_SET' (omitted).
  • alert_type — Type of alert. Defaults to 'DO_NOT_SET' (omitted).
  • external_id — External identifier for the note. Defaults to 'DO_NOT_SET' (omitted).
  • requestOptions — Collection of HTTP options including batching, timeout, proxy, and SSL settings.

Output shape

A single record (the created inventory note) or an array of records if processing multiple items in batches.

The default batching splits items into batches of 50 with a 1000ms interval. If no items are provided (or all are omitted due to 'DO_NOT_SET'), the operation may return an empty response.

Examples

Example 1: Create a simple note for a specific inventory item.

Set 'inventory' to the target ID, and provide 'title' and 'note' values.

Example 2: Create a note with attachments and public visibility.

Provide 'inventory', 'title', 'note', and 'files' (array of base64 strings). Set 'permission' to 1 (public).

Example 3: Process a large list of notes efficiently.

Use 'requestOptions' with 'batching' enabled to process multiple items in batches of 50.

Links

Discussion