{"id":16881576,"url":"https://github.com/benbjohnson/agency","last_synced_at":"2025-03-22T07:32:13.970Z","repository":{"id":12325738,"uuid":"14963018","full_name":"benbjohnson/agency","owner":"benbjohnson","description":"A fast user agent string parser for Go.","archived":false,"fork":false,"pushed_at":"2017-06-01T16:05:17.000Z","size":447,"stargazers_count":60,"open_issues_count":0,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-15T23:56:14.142Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","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/benbjohnson.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}},"created_at":"2013-12-05T19:08:32.000Z","updated_at":"2023-06-03T04:15:18.000Z","dependencies_parsed_at":"2022-08-02T19:01:07.422Z","dependency_job_id":null,"html_url":"https://github.com/benbjohnson/agency","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benbjohnson%2Fagency","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benbjohnson%2Fagency/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benbjohnson%2Fagency/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benbjohnson%2Fagency/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/benbjohnson","download_url":"https://codeload.github.com/benbjohnson/agency/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244192353,"owners_count":20413508,"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":[],"created_at":"2024-10-13T16:04:03.590Z","updated_at":"2025-03-22T07:32:13.339Z","avatar_url":"https://github.com/benbjohnson.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Agency\n\nAgency is a fast user-agent parser in pure Go. It uses a simple tokenizer and weighted tokens to determine the correct device type, category and browser.\n\n## Usage\n\nTo use Agency, simply import the package and call `Scan()`:\n\n```go\nimport \"github.com/benbjohnson/agency\"\n\nua := agency.Scan(\"Mozilla/5.0 (Windows NT 6.2; Win64; x64) AppleWebKit/537.36 blah blah...\")\n```\n\n\n## User Agent Info\n\nThe `Scan()` function returns a `UserAgent` with the following string properties:\n\n```\nType\n----------\nDesktop\nTablet\nMobile\n\nCategory\n----------\nWindows\nMac\nLinux\niOS\nBlackberry\nAndroid\n\nBrowser\n----------\nChrome\nSafari\nInternet Explorer\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenbjohnson%2Fagency","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbenbjohnson%2Fagency","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenbjohnson%2Fagency/lists"}