All you had to do was filling a form with the personal details at the arrival airport (and of course, a valid passport).