Skip to main content
JavaScript events are emitted using JavaScript’s Window: postMessage method.

Receiving Events

Available Incoming Events

parcel:viewed

Emitted for any parcel details selected from the Parcels map layer.
Example:

parcel:collection_changed

Emitted for any change in the selected parcels.
Example:

farm_sale:viewed

Emitted for any farm sale selected from the Farm Sales map layer.
Example:

Sending Events

The embedded map will react to events that you post into its contentWindow. Always pass your CamoAg embed origin as the targetOrigin so the message can only be received by the intended iframe.

Available Outgoing Events

parcel:collection_remove_by_id

Removes a single parcel from the selected collection. The id matches the properties.id of a parcel feature previously returned by parcel:collection_changed.
Example:
After the parcel is removed, the embedded map emits an updated parcel:collection_changed event reflecting the new selection.

parcel:collection_remove_all

Clears every parcel from the selected collection.
Example:
After the collection is cleared, the embedded map emits an updated parcel:collection_changed event with an empty features array.
Last modified on May 29, 2026