Shopware icon

Shopware

Shopware

Actions778

Document Management → Number Range Reserve

AI-generated

Overview

This node operation reserves a number range for a specific document type within a sales channel in a document management system. It allows users to either preview the next number in the range without incrementing it or actually reserve (increment) the number. This is useful in scenarios where unique document numbers need to be generated and managed, such as invoicing, order processing, or any document tracking system that requires sequential numbering.

Use Case Examples

  1. Reserving an invoice number for a sales channel before creating an invoice document.
  2. Previewing the next available document number without incrementing it to check the upcoming number in the sequence.

Properties

Name Meaning
Type The technical name of the document type for which the number range is reserved (e.g., 'document_invoice'). This identifies the category of document for which the number is being reserved.
Saleschannel The sales channel ID for which the number range is defined. Number ranges can be specific to sales channels, so this property specifies the channel context.
Preview A boolean flag indicating whether to preview the number without incrementing it (true) or to actually reserve (increment) the number (false).

Output

JSON

  • numberRange - The reserved or previewed number in the number range for the specified document type and sales channel.

Dependencies

  • Requires API access to the document management system with appropriate credentials to call the number range reservation endpoint.

Troubleshooting

  • Ensure the 'type' property matches a valid document type technical name available in the system; otherwise, the API call may fail.
  • Verify the 'saleschannel' ID is correct and exists in the system to avoid errors related to invalid sales channel references.
  • If 'preview' is set to false, the number range will be incremented; use caution to avoid unintended increments.
  • Check network connectivity and API credentials if requests fail or time out.
  • If SSL issues occur, consider enabling the 'Ignore SSL Issues' option if appropriate and secure.

Discussion