Skip to main content

Quotations Module

The quotations module manages quote requests and proposal workflows.

Configuration Options​

export interface QuotationsSettingsOptions {
quotationNumberHashFn?: (quotation: Quotation, index: number) => string;
}

Quotation Number Creation​

The quotationNumberHashFn is used to generate human-readable codes that can be easily spelled out to support staff. The default generates a random alphanumeric uppercase string with length 6 using an unambiguous charset (no O, 0, 1). If the number has already been taken, the function gets iteratively called with an increasing index.

Default Random Hash Generator

Example Custom Configuration​

await startPlatform({
options: {
quotations: {
quotationNumberHashFn: (quotation, index) => `${300000 + index}`,
},
},
});

Events​

EventPayloadDescription
QUOTATION_REQUEST_CREATE{ quotation }Emitted when a quotation request is created
QUOTATION_UPDATE{ quotation, field: 'status' } or { quotation, fields }Emitted when a quotation is updated
QUOTATION_REMOVE{ quotationId }Emitted when a quotation is removed

More Information​

For API usage and detailed documentation, see the core-quotations package on GitHub.