Hey Carlos,
I don't think so this method will return enrolment id for the user. It will return enrolled users details like firstname, lastname, profile description and many other details related to users. The details return by this method are
[{"id":3,"username":"sooraj","firstname":"Sooraj","lastname":"Singh","fullname":"Sooraj Singh","email":"singhsooraj30zz@gmail.com","department":"","firstaccess":0,"lastaccess":0,"description":"","descriptionformat":1,"country":"IN","profileimageurlsmall":"http:\/\/localhost\/moodle3.6.1\/theme\/image.php\/academic\/core\/1551116448\/u\/f2","profileimageurl":"http:\/\/localhost\/moodle3.6.1\/theme\/image.php\/academic\/core\/1551116448\/u\/f1","groups":[],"roles":[{"roleid":5,"name":"","shortname":"student","sortorder":0}],"enrolledcourses":[{"id":4,"fullname":"dd","shortname":"45"}]}]
All these details are not required for calling core_enrol_edit_user_enrolment.
Thanks and Regards,
Mayank