Learn how to get the file type of a URL in Python using mimetypes, response headers, and practical checks for scraping workflows.