{"id":49396,"library":"socks5-node-fetch","title":"socks5-node-fetch","description":"A thin wrapper around node-fetch that adds SOCKS5 proxy support via a custom agent. Version 0.0.4, last updated in 2018. It provides a drop-in replacement for node-fetch that routes HTTP/HTTPS requests through a SOCKS5 proxy. Key differentiator: automatic protocol detection for http and https. Lightweight with no additional runtime dependencies beyond node-fetch. Limited to Node.js; no browser support. Stable but minimal maintenance.","status":"maintenance","version":"0.0.4","language":"javascript","source_language":"en","source_url":"https://github.com/ciqulover/socks5-node-fetch","tags":["javascript","node-fecth","socks5"],"install":[{"cmd":"npm install socks5-node-fetch","lang":"bash","label":"npm"},{"cmd":"yarn add socks5-node-fetch","lang":"bash","label":"yarn"},{"cmd":"pnpm add socks5-node-fetch","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Required peer dependency; wraps node-fetch's fetch function.","package":"node-fetch","optional":false}],"imports":[{"note":"Package has a default export, not named; CommonJS users can use `const wrappedFetch = require('socks5-node-fetch')`.","wrong":"const { wrappedFetch } = require('socks5-node-fetch')","symbol":"default","correct":"import wrappedFetch from 'socks5-node-fetch'"},{"note":"No TypeScript types bundled; users must install @types/node-fetch separately if using TypeScript.","wrong":"","symbol":"types","correct":""}],"quickstart":{"code":"import wrappedFetch from 'socks5-node-fetch';\n\nconst fetch = wrappedFetch({\n  socksHost: 'localhost',\n  socksPort: '1080'\n});\n\nfetch('https://httpbin.org/ip', { method: 'GET' })\n  .then(res => res.text())\n  .then(body => console.log('Response:', body))\n  .catch(err => console.error('Error:', err));","lang":"javascript","description":"Demonstrates importing socks5-node-fetch, configuring it with a SOCKS5 proxy, and making an HTTPS request."},"warnings":[{"fix":"Run `npm install node-fetch socks5-node-fetch`","message":"Package requires node-fetch as a peer dependency; must be installed separately.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Use a browser-compatible fetch with SOCKS5 proxy support like 'socks-proxy-agent'.","message":"Only supports Node.js; will not work in browser environments.","severity":"gotcha","affected_versions":">=0.0.0"},{"fix":"Consider using 'socks-proxy-agent' directly with node-fetch for up-to-date package.","message":"Last published 7 years ago; no updates or security patches.","severity":"deprecated","affected_versions":">=0.0.0"}],"env_vars":null,"search_vec":"'0.0.4':22 '2018':26 'add':13 'addit':58 'agent':20 'around':8 'automat':48 'beyond':61 'browser':69 'custom':19 'depend':60 'detect':50 'differenti':47 'drop':31 'drop-in':30 'fecth':78 'fetch':4,11,37,64 'http':52 'http/https':40 'https':54 'javascript':75 'key':46 'last':23 'lightweight':55 'limit':65 'mainten':74 'minim':73 'node':3,10,36,63,77 'node-fecth':76 'node-fetch':9,35,62 'node.js':67 'protocol':49 'provid':28 'proxi':15,45 'replac':33 'request':41 'rout':39 'runtim':59 'socks5':2,14,44,79 'socks5-node-fetch':1 'stabl':71 'support':16,70 'thin':6 'updat':24 'version':21 'via':17 'wrapper':7","created_at":"2026-06-07T17:01:34.073821+00:00","updated_at":"2026-06-07T17:01:34.073821+00:00","problems":[{"fix":"Run `npm install socks5-node-fetch`","cause":"Package not installed.","error":"Cannot find module 'socks5-node-fetch'"},{"fix":"Use `const wrappedFetch = require('socks5-node-fetch')` or `import wrappedFetch from 'socks5-node-fetch'`","cause":"Incorrect import (named instead of default).","error":"TypeError: wrappedFetch is not a function"},{"fix":"Ensure a SOCKS5 proxy is running at the specified host and port, or adjust the configuration.","cause":"SOCKS5 proxy not running or incorrect host/port.","error":"Error: connect ECONNREFUSED 127.0.0.1:1080"}],"ecosystem":"npm","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/ciqulover/socks5-node-fetch#readme","github":"https://github.com/ciqulover/socks5-node-fetch","docs":null,"changelog":null,"pypi":null,"npm":"socks5-node-fetch","openapi_spec":null,"status_page":null,"smithery":null,"categories":["security","devops"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-07","next_check":"2026-09-05","install_tag":null}}