Interface LinkCheckerResource
@Path("/linkChecker")
public interface LinkCheckerResource
Resource for the link checker
-
Method Summary
Modifier and TypeMethodDescriptioncheckLink
(CheckExternalLinkRequest request) Check an external link for validityLoad a single link.Get the external links contained in a single pagegetPages
(com.gentics.contentnode.rest.resource.parameter.FilterParameterBean filter, com.gentics.contentnode.rest.resource.parameter.SortParameterBean sorting, com.gentics.contentnode.rest.resource.parameter.PagingParameterBean paging, LinkCheckerFilterParameterBean linkFilter, com.gentics.contentnode.rest.resource.parameter.PermsParameterBean perms) Get list of pages containing external linksGet link checker statisticscom.gentics.contentnode.rest.model.response.GenericResponse
updateLink
(String pageId, int linkId, long waitMs, ReplaceExternalLinkRequest request) Update a link (optionally together with other occurrences) by replacing the URL with the given URL.com.gentics.contentnode.rest.model.response.GenericResponse
updateLinkStatus
(String pageId, UpdateExternalLinkStatusRequest request) Update the validity status for external links contained in the page.
-
Method Details
-
getStats
@GET @Path("/stats") ExternalLinkStatistics getStats(@QueryParam("nodeId") Integer nodeId, @QueryParam("online") Boolean online) throws Exception Get link checker statistics- Parameters:
nodeId
- optional node ID for getting node specific statisticsonline
- (optional) true to restrict to online pages, false to restrict to offline pages- Returns:
- statistics response
- Throws:
Exception
-
getPages
@GET @Path("/pages") PageList getPages(@BeanParam com.gentics.contentnode.rest.resource.parameter.FilterParameterBean filter, @BeanParam com.gentics.contentnode.rest.resource.parameter.SortParameterBean sorting, @BeanParam com.gentics.contentnode.rest.resource.parameter.PagingParameterBean paging, @BeanParam LinkCheckerFilterParameterBean linkFilter, @BeanParam com.gentics.contentnode.rest.resource.parameter.PermsParameterBean perms) throws Exception Get list of pages containing external links- Parameters:
filter
- general filter parameterssorting
- sorting parameterspaging
- paging parameterslinkFilter
- link filter parametersperms
- permissions parameters- Returns:
- response containing a list of pages with external links
- Throws:
Exception
-
getLinks
@GET @Path("/pages/{id}") ExternalLinkList getLinks(@PathParam("id") String pageId) throws Exception Get the external links contained in a single page- Parameters:
pageId
- page ID- Returns:
- response containing the external links of the page
- Throws:
Exception
-
updateLinkStatus
@POST @Path("/pages/{id}") com.gentics.contentnode.rest.model.response.GenericResponse updateLinkStatus(@PathParam("id") String pageId, UpdateExternalLinkStatusRequest request) throws Exception Update the validity status for external links contained in the page. Update permissions on the page are required.- Parameters:
pageId
- page IDrequest
- request containing external links with updated status- Returns:
- generic response
- Throws:
Exception
-
checkLink
Check an external link for validity- Parameters:
request
- request containing the link to check- Returns:
- check response
- Throws:
Exception
-
getLink
@GET @Path("/pages/{pageId}/links/{id}") ExternalLinkResponse getLink(@PathParam("pageId") String pageId, @PathParam("id") int linkId) throws Exception Load a single link. Response contains additional information about occurrence of URL in the system- Parameters:
pageId
- page IDlinkId
- link ID- Returns:
- link response
- Throws:
Exception
-
updateLink
@POST @Path("/pages/{pageId}/links/{id}") com.gentics.contentnode.rest.model.response.GenericResponse updateLink(@PathParam("pageId") String pageId, @PathParam("id") int linkId, @QueryParam("wait") @DefaultValue("0") long waitMs, ReplaceExternalLinkRequest request) throws Exception Update a link (optionally together with other occurrences) by replacing the URL with the given URL.- Parameters:
pageId
- page IDlinkId
- link IDwaitMs
- time in ms for the request to be done in foregroundrequest
- request containing the new URL and the replace scope- Returns:
- response
- Throws:
Exception
-