{"id":24441972,"url":"https://github.com/jpcaparas/laravel-http-socks5","last_synced_at":"2026-02-13T04:34:24.095Z","repository":{"id":270815181,"uuid":"911419053","full_name":"jpcaparas/laravel-http-socks5","owner":"jpcaparas","description":"This package extends the Laravel HTTP service to allow for easy, parameterised SOCKS5 proxying","archived":false,"fork":false,"pushed_at":"2025-01-03T20:21:11.000Z","size":17,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-14T04:19:17.605Z","etag":null,"topics":["laravel","proxy","socks5"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jpcaparas.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2025-01-03T01:20:44.000Z","updated_at":"2025-01-03T20:23:22.000Z","dependencies_parsed_at":"2025-01-03T09:39:19.720Z","dependency_job_id":"7946a193-b119-467b-a44c-18457917e1b6","html_url":"https://github.com/jpcaparas/laravel-http-socks5","commit_stats":null,"previous_names":["jpcaparas/laravel-http-socks5"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpcaparas%2Flaravel-http-socks5","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpcaparas%2Flaravel-http-socks5/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpcaparas%2Flaravel-http-socks5/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jpcaparas%2Flaravel-http-socks5/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jpcaparas","download_url":"https://codeload.github.com/jpcaparas/laravel-http-socks5/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251723136,"owners_count":21633094,"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":["laravel","proxy","socks5"],"created_at":"2025-01-20T21:43:38.253Z","updated_at":"2026-02-13T04:34:19.064Z","avatar_url":"https://github.com/jpcaparas.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Laravel HTTP client macro for SOCKS5 proxying\n\n![Tests](https://github.com/jpcaparas/laravel-http-socks5/actions/workflows/tests.yml/badge.svg)\n\nThis package extends the Laravel HTTP service to allow for easy, parameterised SOCKS5 proxying\n\n## Installation\n\nYou can install the package via composer:\n\n```bash\ncomposer require jpcaparas/laravel-http-socks5\n```\n\n## Usage\n\n### Registering the Service Provider\n\nAdd the service provider to your `config/app.php`:\n\n```php\n'providers' =\u003e [\n    // ...\n    JPCaparas\\Socks5Proxy\\Socks5ProxyServiceProvider::class,\n],\n```\n\n### Setting up the SOCKS5 Proxy\n\nTo use the SOCKS5 proxy, you can utilize the fluent interface:\n\n```php\nuse Illuminate\\Support\\Facades\\Http;\n\n$response = Http::socks5()\n    -\u003esetHost('proxy.example.com')\n    -\u003esetPort(1080)\n    -\u003esetCredentials('username', 'password')\n    -\u003eget('http://example.com');\n```\n\n### Method Chaining\n\nYou can chain multiple configuration methods:\n\n```php\nuse Illuminate\\Support\\Facades\\Http;\n\n$client = Http::socks5()\n    -\u003esetHost('proxy.example.com')\n    -\u003esetCredentials('username', 'password')\n    -\u003ewithOptions([\n        'debug' =\u003e true,\n        'timeout' =\u003e 30\n    ]);\n\n$response = $client-\u003epost('https://api.example.com/data', [\n    'key' =\u003e 'value'\n]);\n```\n\n### Debugging the Response\n\nEnable debugging to see detailed connection information:\n\n```php\nuse Illuminate\\Support\\Facades\\Http;\n\n$response = Http::socks5()\n    -\u003esetHost('proxy.example.com')\n    -\u003esetCredentials('username', 'password')\n    -\u003ewithOptions(['debug' =\u003e true])\n    -\u003eget('http://example.com');\n```\n\n## Tests\n\n```bash\ncomposer test\n```\n\n## Trying it out\n\nYou can experiment with the package using Laravel Tinker. First, run:\n\n```bash\ncomposer tinker\n```\n\nThen try this example (outputs detailed connection info):\n\n```php\n$client = \\Illuminate\\Support\\Facades\\Http::socks5()\n   -\u003esetHost('amsterdam.nl.socks.nordhold.net')\n   -\u003esetCredentials('username', 'password');\n\n$client-\u003ewithOptions(['debug' =\u003e true])-\u003eget('https://www.google.com');\n```\n\nExample output:\n```\n* Host amsterdam.nl.socks.nordhold.net:1080 was resolved.\n* IPv6: (none)\n* IPv4: [REDACTED]\n*   Trying [REDACTED]:1080...\n* Host www.google.com:443 was resolved.\n* IPv6: [REDACTED]\n* IPv4: [REDACTED]\n* SOCKS5 connect to [REDACTED]:443 (locally resolved)\n* SOCKS5 request granted.\n* Connected to amsterdam.nl.socks.nordhold.net port 1080\n[...]\n* SSL connection using TLSv1.3\n* Server certificate verified\n\u003e GET / HTTP/1.1\nHost: www.google.com\n[...]\n\u003c HTTP/1.1 200 OK\n\u003c Date: Fri, 03 Jan 2025 08:14:37 GMT\n[...]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpcaparas%2Flaravel-http-socks5","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjpcaparas%2Flaravel-http-socks5","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjpcaparas%2Flaravel-http-socks5/lists"}