Determine the content type of a request using HTTP headers. type-is checks if the incoming request's Content-Type matches any valid MIME type or extension you provide. It leverages mime-db for accurate type matching and offers flexible content negotiation. Essential for building robust and secure APIs and web servers, filtering requests based on expected input formats, and ensuring data integrity. Simplifies handling multipart, JSON, and other content types.
The type-is package had frequent releases in 2014 and 2015, with a peak of 5 versions in June 2014. Release frequency slowed significantly after 2015, with only occasional releases until 2019. There was a long pause until August 2024, when version 2.0.0 was released, followed by version 2.0.1 in March 2025. No releases have occurred in the months since.
npm package type-is downloads show a generally increasing trend from March 2024 to August 2025, peaking at 204 million downloads in July 2025. September 2025 is incomplete, showing significantly lower downloads compared to recent months. The package consistently maintained over 100 million downloads each month since April 2024.