<?xml version="1.0" encoding="UTF-8" ?>
    <prefix>
      <prefix>announcement</prefix>
      <describeURL>/direct/announcement/describe</describeURL>
      <summary>Represents announcements for a given site (including merged announcements) or all announcements for a user. Also includes Message Of The Day and public announcements. There are three optional URL parameters available: 'n' to set the total number of announcements returned, 'd' to set the number of days in the past to retrieve announcements for, and 'a' to set an ascending sort order of true or false. If the system is configured with the (default) 'Announcement Reorder' property, announcements will be additionally sorted by the message_order. If these parameters are not set, they are retrieved from the tool configuration, or the standard defaults of n=3, d=10, a=0 are used. For example /announcements/site/mercury.json?n=20&amp;d=100&amp;a=1 will retrieve up to 20 total announcements for up to 100 days ago with an ascending order.</summary>
      <showURL>/announcement/:ID:</showURL>
      <customActions>
        <customAction>
          <action>msg</action>
          <url>/direct/announcement/msg</url>
          <method>GET</method>
          <viewKey>list</viewKey>
          <description>Retrieve an announcement based on the path used by the announcements service internally, ie /announcement/msg/{siteId}/{channelId}/{announcementId}. Context is normally the site ID and the channelId is normally "main" unless there are multiple channels in a site. For example /announcement/msg/21b1984d-af58-43da-8583-f4adee769aa2/main/5641323b-761a-4a4d-8761-688f4928141b</description>
        </customAction>
      </customActions>
      <customActions>
        <customAction>
          <action>motd</action>
          <url>/direct/announcement/motd</url>
          <method>GET</method>
          <viewKey>list</viewKey>
          <description>Retrieve only the MOTD announcements.</description>
        </customAction>
      </customActions>
      <customActions>
        <customAction>
          <action>site</action>
          <url>/direct/announcement/site</url>
          <method>GET</method>
          <viewKey>list</viewKey>
          <description>Retrieve the announcements for a site. If you are not logged in, you will only receive the public announcements for this site.</description>
        </customAction>
      </customActions>
      <customActions>
        <customAction>
          <action>message</action>
          <url>/direct/announcement/message</url>
          <method>GET</method>
          <viewKey>list</viewKey>
          <description>Retrieve an announcement based on the given siteId and messageId. eg /announcement/message/{siteId}/{msgId}</description>
        </customAction>
      </customActions>
      <customActions>
        <customAction>
          <action>user</action>
          <url>/direct/announcement/user</url>
          <method>GET</method>
          <viewKey>list</viewKey>
          <description>Retrieve the announcements for the current user. If you are not logged in, you will only receive the MOTD announcements. Announcements will be sorted by date and ignore the system's 'Announcement Reorder' configuration.</description>
        </customAction>
      </customActions>
      <outputFormats>
        <format>xml</format>
        <format>json</format>
       </outputFormats>
      <inputFormats>
       </inputFormats>
      <entityClass>
        <class>org.sakaiproject.announcement.entityprovider.AnnouncementEntityProviderImpl$DecoratedAnnouncement</class>
        <type>bean</type>
        <fields>
          <field>
            <name>announcementId</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>attachments</name>
            <type>java.util.List</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>body</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>channel</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>createdByDisplayName</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>createdOn</name>
            <type>java.util.Date</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>id</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>false</writeable>
          </field>
          <field>
            <name>siteId</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>siteTitle</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
          <field>
            <name>title</name>
            <type>java.lang.String</type>
            <readable>true</readable>
            <writeable>true</writeable>
          </field>
        </fields>
      </entityClass>
      <capabilities>
        <capability>
          <name>EntityProvider</name>
          <type>org.sakaiproject.entitybroker.entityprovider.EntityProvider</type>
        </capability>
        <capability>
          <name>ActionsExecutable</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.ActionsExecutable</type>
        </capability>
        <capability>
          <name>AutoRegisterEntityProvider</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.AutoRegisterEntityProvider</type>
        </capability>
        <capability>
          <name>Describeable</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.Describeable</type>
        </capability>
        <capability>
          <name>Outputable</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.Outputable</type>
        </capability>
        <capability>
          <name>Resolvable</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.Resolvable</type>
        </capability>
        <capability>
          <name>Sampleable</name>
          <type>org.sakaiproject.entitybroker.entityprovider.capabilities.Sampleable</type>
        </capability>
      </capabilities>
    </prefix>
