# `PhoenixKit.Modules.Storage.LibraryMember`
[🔗](https://github.com/BeamLabEU/phoenix_kit/blob/v2.40.1/lib/modules/storage/schemas/library_member.ex#L1)

Someone other than its owner who may use a user library (V203), and as
what:

  * `manager` — everything the owner does to the library's files, and
    managing its members; not trashing the library, nor handing it on
  * `contributor` — upload, and change the files they uploaded; folder
    names and looks are shared. The media browser (`own_files_only`)
    refuses a contributor's change to anyone else's file, a folder write
    (trash, delete, move) whose subtree holds one, and emptying the trash
    or clearing orphans
  * `viewer` — see the files

The owner is the library's `owner_uuid`, never a member row. A member row
goes with its library and with its user.

Go through `PhoenixKit.Modules.Storage.Libraries` rather than this schema.

# `t`

```elixir
@type t() :: %PhoenixKit.Modules.Storage.LibraryMember{
  __meta__: term(),
  inserted_at: DateTime.t() | nil,
  library: term(),
  library_uuid: UUIDv7.t() | nil,
  role: String.t(),
  updated_at: DateTime.t() | nil,
  user: term(),
  user_uuid: UUIDv7.t() | nil
}
```

# `roles`

```elixir
@spec roles() :: [String.t()]
```

The roles a member can have, most to least.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
