SearchMediaTool
Searches the MediaStore for images and/or videos by DISPLAY_NAME substring (%, _, \ match literally) and/or DATE_TAKEN range (strict yyyy-MM-dd, device timezone), newest-first, with limit/offset paging. The media_type param selects images, videos, or all (default); all runs one MediaStore.Files query filtered to image and video rows, so both kinds are merged by date and offset pages consistently across them. Requires READ_MEDIA_IMAGES/READ_MEDIA_VIDEO on API 33+, else READ_EXTERNAL_STORAGE. Output: results (each {id, name, path, date_taken, size_bytes, mime_type, width, height, media_type}), count, and media_type.