I don't see code for opening and closing the file.

With UTL_FILE you write to the database server. With the Forms/Reports Built-in TEXT_IO you can write to your client, but only from Forms or Reports.

If you want a simple report for your developers, spooling from SQL*Plus seems the most appropriate.