How to get the media title and url to the media entity
Got it figured out. Steps:

In Structure &gt; Media Types &gt; File &gt; Manage Display, set the format as Generic File, click the gear icon, and turn on Use description as link text.

Next, inside of Structure &gt; Media Types &gt; File &gt; Manage Fields, edit the field_media_file field and make sure the checkbox for Enable description field is checked. Now, when creating a media file entity, there is a description field that can be filled and will display as the link text.