New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

mobile-user-agent

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mobile-user-agent

A Node.js module to generate random mobile user agent strings for Android and iOS.

latest
Source
npmnpm
Version
1.0.3
Version published
Weekly downloads
4
Maintainers
1
Weekly downloads
 
Created
Source

Mobile User Agent

A Node.js module to generate random mobile user agent strings for Android (>= 10) and iOS (>= 17).

Usage

const mobileUserAgent = require('mobile-user-agent');

// Get a random mobile user agent for either Android or iOS
const randomUA = mobileUserAgent(); // or const RandomUA = randomUserAgent('random');
console.log('\nRandom Mobile UserAgent:', RandomUA);

// Get a random Android user agent
const androidUA = mobileUserAgent('android');
console.log('\nAndroid UserAgent:', AndroidUA);

// Get a random iOS user agent
const iosUA = mobileUserAgent('ios');
console.log('\nIos UserAgent:', IosUA);

API

mobileUserAgent(category = 'Random')

  • category (opsional): A string specifying the desired operating system. Can be 'android', 'ios', or 'Random' (default). If set to 'Random' or any other value, it will return a user agent for either Android or iOS randomly.

  • Returns: A string containing a random mobile user agent.

Supported Operating Systems and Browsers

  • Android: Versions >= 10, Chrome, Firefox
  • iOS: Versions >= 17, Safari, Chrome

License

MIT

Keywords

random agent

FAQs

Package last updated on 14 May 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts