@POST
	@Path(PATH_PATTERN)
	@Consumes(MediaType.APPLICATION_JSON)
	public Response interactDocument(
			String messageBody,
			@PathParam("path") String path,
			@HeaderParam(API_HEADER_ACTION) String action,
			@DefaultValue("") @HeaderParam(API_HEADER_GROUP) String group){
		// handle each action separately
		if(action.equals(API_ACTION_EDIT)){
			Main.log("edit {"+path+"} with group {"+group+"}: " + messageBody);
		} else if(action.equals(API_ACTION_UNDO)){
			Main.log("undo {"+path+"} with group {"+group+"}");
		} else if(action.equals(API_ACTION_REDO)){
			Main.log("redo {"+path+"} with group {"+group+"}");
		} else if(action.equals("")){
			Main.log("Can't do anything with a POST and empty action", true);
		} else{
			Main.log("Unknown editing action: " + action, true);
		}
		return Response.status(Response.Status.OK).build();
	}