Hi Alissonsalin,
You can use saveUserScore method to save the leaderboard. Use currentTimeMills to find the current time during the beginning and end of the game. The result will be time in milliseconds. If you want you can further convert it into seconds or minutes and save that using saveUserScore.
You can use the following code snippet for saving your user's score:
App42API.initialize("API_KEY","SECRET_KEY");
ScoreBoardService scoreBoardService = App42API.buildScoreBoardService();
GameService gameService = App42API.buildGameService();
gameService.createGame("Your Game Name", "Your Game Descrption");
long startTime = System.currentTimeMillis();
long endTime = System.currentTimeMillis();
long timeDiff = (endTime-startTime);
Game game = scoreBoardService.saveUserScore("Your Game Name", "Alissonsalin", new BigDecimal(timeDiff));
System.out.println("Game Response is :"+ game);
// Naresh