{"id":15022470,"url":"https://github.com/dropoutlab-dev/user-agents-generator","last_synced_at":"2025-04-10T18:44:01.907Z","repository":{"id":70523069,"uuid":"604516789","full_name":"dropoutlab-dev/user-agents-generator","owner":"dropoutlab-dev","description":"This is a Node.js module that provides a simple way to generate user agent strings for various web browsers and mobile devices. The generated user agents can be used in web scraping or automation scripts to mimic the behavior of real users.","archived":false,"fork":false,"pushed_at":"2023-02-21T08:52:49.000Z","size":5,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-30T13:02:30.891Z","etag":null,"topics":["automation","javascript","puppeteer","user-agent"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dropoutlab-dev.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-21T08:19:22.000Z","updated_at":"2024-06-11T04:34:56.000Z","dependencies_parsed_at":null,"dependency_job_id":"09be460c-f1c0-4fb6-b410-01a5d96b6f96","html_url":"https://github.com/dropoutlab-dev/user-agents-generator","commit_stats":{"total_commits":2,"total_committers":2,"mean_commits":1.0,"dds":0.5,"last_synced_commit":"4a1dc4b1c6e5aa10403a9c0828a9154bb55c2cf4"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dropoutlab-dev%2Fuser-agents-generator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dropoutlab-dev%2Fuser-agents-generator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dropoutlab-dev%2Fuser-agents-generator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dropoutlab-dev%2Fuser-agents-generator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dropoutlab-dev","download_url":"https://codeload.github.com/dropoutlab-dev/user-agents-generator/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248173810,"owners_count":21059594,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","javascript","puppeteer","user-agent"],"created_at":"2024-09-24T19:58:00.067Z","updated_at":"2025-04-10T18:44:01.889Z","avatar_url":"https://github.com/dropoutlab-dev.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# User Agents Generator\n\n\u003e This is a Node.js module that provides a simple way to generate user agent strings for various web browsers and mobile devices. The generated user agents can be used in web scraping or automation scripts to mimic the behavior of real users.\n\n## Usage\n\n1.  Install the module in your project:\n\n```bash\nnpm install user-agent-generator\n```\n\n2.  Import the module in your script:\n\n```javascript\nconst userAgentGenerator = require('user-agent-generator');\n```\n\n3.  Use the module's methods to generate user agents for different browsers and devices:\n\n```javascript\n`const chromeUserAgent = userAgentGenerator.chrome();\nconst firefoxUserAgent = userAgentGenerator.firefox();\nconst safariUserAgent = userAgentGenerator.safari();\nconst androidUserAgent = userAgentGenerator.android();\nconst iosUserAgent = userAgentGenerator.ios();` \n```\n4.  Pass the generated user agent string to your Puppeteer automation scripts:\n\n```javascript\n\nconst puppeteer = require('puppeteer');\nconst chromeUserAgent = userAgentGenerator.chrome();\n(async () =\u003e {\n  const browser = await puppeteer.launch({\n    headless: true,\n    args: [`--user-agent=${chromeUserAgent}`]\n  });\n  const page = await browser.newPage();\n  await page.goto('https://www.example.com');\n  // your automation code here\n  await browser.close();\n})();\n```\n\n## API\n\n### `userAgentGenerator.chrome()`\n\nGenerates a user agent string for the Google Chrome browser.\n\n### `userAgentGenerator.firefox()`\n\nGenerates a user agent string for the Mozilla Firefox browser.\n\n### `userAgentGenerator.safari()`\n\nGenerates a user agent string for the Apple Safari browser.\n\n### `userAgentGenerator.android()`\n\nGenerates a user agent string for an Android device.\n\n### `userAgentGenerator.ios()`\n\nGenerates a user agent string for an iOS device.\n\n## License\n\nThis module is released under the MIT License.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdropoutlab-dev%2Fuser-agents-generator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdropoutlab-dev%2Fuser-agents-generator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdropoutlab-dev%2Fuser-agents-generator/lists"}