# HG changeset patch # User Matthew Wild # Date 1699356396 0 # Node ID aa94d5bb6b10cab200ed9992d421f56f296275f9 # Parent 78f766372e2c498efce3d2b8a801d3651bf36ebe mod_muc_members_json: Expand example config and docs for clarity diff -r 78f766372e2c -r aa94d5bb6b10 mod_muc_members_json/README.md --- a/mod_muc_members_json/README.md Sun Nov 05 21:06:23 2023 +0100 +++ b/mod_muc_members_json/README.md Tue Nov 07 11:26:36 2023 +0000 @@ -40,11 +40,24 @@ ``` muc_members_json_mucs = { +- -- This configures hats for the myroom@ MUC myroom = { + -- The optional field 'member_hat' defines a hat that will be + -- added to any user that is listed in the members JSON + -- (regardless of what roles they have, if any) member_hat = { id = "urn:uuid:6a1b143a-1c5c-11ee-80aa-4ff1ce4867dc"; title = "Cool Member"; }; + -- The optional field 'team_hats' defines one or more hats + -- that will be assigned to users that have the specified + -- roles in the JSON. + team_hats = { + janitor = { + id = "urn:uuid:ec32f550-7d5f-11ee-81ee-6b139cac3bf6"; + title = "Janitor"; + } + } }; } ``` @@ -69,7 +82,10 @@ } ``` -Each member must have a `jids` field, and optionally a `roles` field. +The JSON format must be an object with a `members` array. + +Each member must have a `jids` field, and optionally a `roles` field (both are +arrays of strings). Compatibility =============