mispex v0.1.7 MISP.Tag View Source
A tag attached to an object, usually an event or attribute
Link to this section Summary
Functions
Either create a new tag or retrieve the representation of an already-existing tag
Delete multiple tags
Search for tags. Use % for wildcard
Update the server-side values for a tag
Link to this section Types
Link to this section Functions
Link to this function
create(tag) View Source
Either create a new tag or retrieve the representation of an already-existing tag
iex> {:ok, my_tag} = MISP.Tag.create(%MISP.Tag{name: "my tag"})
Link to this function
decoder() View Source
Link to this function
delete(tags) View Source
Delete multiple tags
Link to this function
delete(struct, key) View Source
Link to this function
get(id) View Source
Link to this function
get(struct, key, default \\ nil) View Source
Link to this function
put(struct, key, val) View Source
Link to this function
search(search_term) View Source
Search for tags. Use % for wildcard
iex> MISP.Tag.search("%tag")
{:ok, [
%MISP.Tag{
colour: "#373f7b",
exportable: true,
hide_tag: false,
id: "3",
name: "my tag"
}
]}
Link to this function
update(tag) View Source
Update the server-side values for a tag
iex> MISP.Tag.get(1) |> Map.put(:name, "my new name") |> MISP.Tag.update()