From fac0d087f7565437731c6466a5dff79a29b70bba Mon Sep 17 00:00:00 2001 From: Charles Iliya Krempeaux Date: Tue, 26 Sep 2023 13:51:37 +0900 Subject: [PATCH] initial commits --- role.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 role.go diff --git a/role.go b/role.go new file mode 100644 index 0000000..990b7fb --- /dev/null +++ b/role.go @@ -0,0 +1,18 @@ +package mstdn + +import ( + "sourcecode.social/reiver/go-opt" + "sourcecode.social/reiver/go-jsonint" +) + +// Role represents a Mastodon API "Role". +// +// See: +// https://docs.joinmastodon.org/entities/Role/ +type Role struct { + ID opt.Optional[jsonint.Int] `json:"id"` + Name opt.Optional[string] `json:"name"` + Color opt.Optional[string] `json:"color"` + Permissions opt.Optional[jsonint.Int] `json:"permissions"` + Highlighted opt.Optional[bool] `json:"color"` +}