IPWorks IoT 2020 JavaScript Edition

Questions / Feedback?

RequestReceipts Property

Whether the class should request that the server provide message receipts.


 isRequestReceipts(): boolean;

 setRequestReceipts(requestReceipts: boolean): void;

Default Value



This property is used to specify whether the class should request that the server send back confirmations (known as a "receipts" in STOMP terminology) when it receives messages from the class. This is done by adding a receipt header to the outgoing frame.

When this property is set to True, and a message is sent, the ReceiptOut event will fire immediately after the MessageOut event fires.

Note that, while this property only controls receipt requests for outgoing messages, the class is capable of requesting receipts for any outgoing frame type. Use this table to determine which API members control receipt request for each outgoing frame type (all are False by default):

To Request Receipts For... Set The...
Messages RequestReceipts property
Message acknowledgment frames RequestAckReceipts configuration setting
Subscribe and Unsubscribe frames RequestSubscriptionReceipts configuration setting
Begin, Commit, and Abort transaction framesRequestTransactionReceipts configuration setting

Received Receipt Notes

When a receipt is received, the ReceiptIn event fires.

Note that receipts are cumulative, and a STOMP server is not required to send back discrete receipts for each frame it receives that has a receipt header. For example, if the class has sent four message frames with the following receipt header values (in chronological order):

  1. SEND-3
  2. SEND-4
  3. SEND-5
  4. SEND-6
then the server could, at some point, send back a single receipt with a receipt-id header value of SEND-5 to confirm that it has received the first three frames.

This property is not available at design time.

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks IoT 2020 JavaScript Edition - Version 20.0 [Build 8265]