# Overview

# Example Stickers

In our example, we create two Stickers. The Stickers have different color (name) - "red" and "yellow" denoting the urgency of the requests. Please note that the "color" of a Sticker must be unique in the context of an account and that it must match the regular expression(opens new window) [0-9A-Za-z\-]{3,48}.

The Stickers have different "validity_ts" values - the "red" Sticker has its validity set to a few days after creation of the Sticker ("created_ts"), the "yellow" Sticker is valid one month from the creation of the Sticker("created_ts").

The Stickers have different UUIDs on the "recipients" lists - the "red" Sticker has the UUID of the account that the Sticker was created in (9891264d-4a77-4fa2-ae7f-84c9af14ae3b), the "yellow" sticker has a list with UUIDs of users belonging to a different account as we are requesting the examination of the device from a vendor.

Attribute Type Description
note string Note for the recipients of the Sticker. The maximum length of a note is 512 characters.
recipients list of strings List of user UUIDs, role UUIDs, and account UUIDs that should be able to access and remove the sticker. The maximum number of items on the list is 100.
validity_ts timestamp Time at which the Sticker expires. Measured in seconds (to three decimal places) that have elapsed since the Unix epoch(opens new window).
created_ts timestamp Time at which the Sticker was created. Measured in seconds (to three decimal places) that have elapsed since the Unix epoch(opens new window).
publish dictionary Events that should trigger a notification message (key) and the name of the subscription topic for this notification message (value). The keys define the event triggering the notification. It can be one of the following:
- "on_put": A notification message is triggered when a Sticker of the given color is put on a given Twin.
- "on_remove": A notification message is triggered when a Sticker of a given color is removed from the given Twin.
- "on_expire": A notification message is triggered when the "validity_ts" of a Sticker is reached and the Sticker expires. The value is the name of the subscription topic. It must match the regular expression(opens new window) ^[0-9A-Za-z\-]{3,48}$. A notification message is triggered up to 60 seconds from the time a Sticker has expired.

Was this article helpful?