Class RecentlyUpdatedContentResource

java.lang.Object
com.atlassian.confluence.plugins.macros.dashboard.recentupdates.rest.RecentlyUpdatedContentResource

@Path("/") public class RecentlyUpdatedContentResource extends Object
REST service for the RecentlyUpdatedContentMacro
Since:
4.3
  • Constructor Details

  • Method Details

    • getUpdates

      @GET @Path("updates") @Produces("application/json") @XsrfProtectionExcluded public javax.ws.rs.core.Response getUpdates(@QueryParam("tab") String tabKey, @QueryParam("maxResults") int maxResults, @QueryParam("showProfilePic") String showProfilePic, @QueryParam("labels") String labelsFilter, @QueryParam("spaces") String spacesFilter, @QueryParam("users") String usersFilter, @QueryParam("types") String typesFilter, @QueryParam("category") String category, @QueryParam("spaceKey") String spaceKey) throws Exception
      Query a list of recent updates matching the given parameters.
      Parameters:
      tabKey - The value from the tab's getName method
      maxResults - The maximum number of results to return (number of RecentUpdate, not RecentUpdateGroup objects)
      Returns:
      JSON representation of a list of RecentUpdateGroup objects
      Throws:
      InvalidSearchException - If the search failed
      Exception
    • getUpdatesPost

      @POST @Path("updates") @Produces("application/json") @Consumes("application/json") public javax.ws.rs.core.Response getUpdatesPost(RecentlyUpdatedContentResourceRequestDto req) throws Exception
      We support POST in case the query string is too long for GET.
      Parameters:
      req - RecentlyUpdatedContentResourceRequestDto
      Returns:
      JSON representation of a list of RecentUpdateGroup objects
      Throws:
      InvalidSearchException - If the search failed
      Exception
    • getDefault

      @GET @Path("default") @Produces("application/json") @XsrfProtectionExcluded public javax.ws.rs.core.Response getDefault()
      Get the default dashboard tab
      Returns:
      JSON representation of the default dashboard tab
    • setDefault

      @PUT @Path("default") @Produces("application/json") public javax.ws.rs.core.Response setDefault(@QueryParam("tab") String tabKey)
      Set the default dashboard tab
      Parameters:
      tabKey - the value from the tab's getName method
      Returns:
      200 OK on success