Class UserSegmentationRestAPI


  • @Path("/lumis/service/analytics/usersegmentation/{si:[a-fA-F0-9]{32}}/rest")
    public class UserSegmentationRestAPI
    extends AbstractMonitorResource
    User segmentation resource.
    Since:
    11.0.0
    Version:
    $Revision: 24476 $ $Date: 2021-04-28 11:28:23 -0300 (Wed, 28 Apr 2021) $
    • Constructor Detail

      • UserSegmentationRestAPI

        public UserSegmentationRestAPI()
    • Method Detail

      • getNextActivities

        @Path("/user/{visitorId}/activities/{page}")
        @POST
        @Produces("application/json")
        @Consumes("application/json")
        public Response getNextActivities​(@PathParam("visitorId")
                                          String visitorId,
                                          @PathParam("page")
                                          Integer page,
                                          @QueryParam("firstEventDateMilliseconds")
                                          Long firstEventDateMilli,
                                          lumis.service.analytics.usersegmentation.rest.UserSegmentationRestAPI.NextActivitiesRequest bodyRequest)
                                   throws PortalException
        Returns only activities of user for be appended in the activities of user.
        Parameters:
        visitorId - the visitor user identifier.
        page - the page of pagination.
        firstEventDateMilli - the oldest event date time in the top of event activities list. It avoids to newest events mess up the pagination.
        Returns:
        the next block of activities.
        Throws:
        PortalException
        Since:
        12.1.0
      • saveSegmentation

        @Path("/segmentation/{id:[a-fA-F0-9]{32}}")
        @PUT
        @Consumes("application/json")
        @Produces("application/json")
        public Response saveSegmentation​(String body,
                                         @PathParam("id") @NotBlank
                                         String id)
        Quick save operation for segmentation.
        Parameters:
        segmentationFilter - the segmentation filter.
        id - the segmentation identifier.
        Returns:
        the response.
        Throws:
        PortalException
        Since:
        11.1.0
      • getSegmentation

        @Path("/segmentation/{id:[a-fA-F0-9]{32}}")
        @GET
        @Consumes("application/json")
        @Produces("application/json")
        public Response getSegmentation​(@PathParam("id") @NotBlank
                                        String id)
        Return segmentation by id.
        Parameters:
        id - the segmentation identifier.
        Returns:
        the response.
        Since:
        11.1.0
      • parseToJsonObject

        public static org.json.JSONObject parseToJsonObject​(UserSegmentation userSegmentation)
        Receives a entity and returns a json client format.
        Parameters:
        userSegmentation - the entity.
        Returns:
        the json object.
        Since:
        11.1.0
      • deleteMonitorUser

        @Path("/user/{visitorId}")
        @DELETE
        public void deleteMonitorUser​(@NotNull @PathParam("visitorId")
                                      String visitorId)
                               throws Exception
        Delete the monitor user with the given visitorId.
        Parameters:
        visitorId - the visitor identifier of the monitor user.
        Throws:
        Exception
        Since:
        12.3.0
      • anonymizeMonitorUser

        @Path("/user/{visitorId}/anonymize")
        @POST
        public void anonymizeMonitorUser​(@NotNull @PathParam("visitorId")
                                         String visitorId)
                                  throws Exception
        Anonymize the monitor user with the given visitorId.
        Parameters:
        visitorId - the visitor identifier of the monitor user.
        Throws:
        Exception
        Since:
        12.3.0
      • deleteMonitorUserActivities

        @Path("/user/{visitorId}/activities")
        @DELETE
        public void deleteMonitorUserActivities​(@NotNull @PathParam("visitorId")
                                                String visitorId)
                                         throws Exception
        Delete the activities of the monitor user with the given visitorId.
        Parameters:
        visitorId - the visitor identifier of the monitor user.
        Throws:
        Exception
        Since:
        12.3.0