Athena::Mercure::Update
Inherits Struct < Value < Object
Represents an update to publish.
AMC::Update.new(
"https://example.com/books/1",
{status: "OutOfStock"}.to_json
)
The topic may be any string, but is recommended it be an IRI (Internationalized Resource Identifier) that uniquely identifies the resource the update related to. The data may also be any string, but will most commonly be JSON.
Private Updates
By default, an update would be sent to all subscribers listening on that topic.
However, if private: true is defined on the update, then it'll only be sent to subscribers who are authorized to receive it.
See Authorization for more information.
Constructors
new(topics : String | Array(String), data : String = "", private __arg0 : Bool = false, id : String | Nil = nil, type : String | Nil = nil, retry : Int32 | Nil = nil)
SourceInstance methods
private?
If true, the update will not be sent to subscribers who are not authorized to receive it.