{"id":21246759,"url":"https://github.com/apfirebolt/banks_api_express","last_synced_at":"2026-04-09T18:39:46.322Z","repository":{"id":240266317,"uuid":"802047088","full_name":"Apfirebolt/banks_api_express","owner":"Apfirebolt","description":"An API written in Express using MongoDB as Database which lists 160K + banks in India. Front-end is written in Svelte","archived":false,"fork":false,"pushed_at":"2025-06-21T09:09:12.000Z","size":310,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-21T09:20:57.453Z","etag":null,"topics":["banking-api","daisyui","daisyui-svelte","express","express-rate-limit","mongodb","mongoose","nginx","nodejs","svelte"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/Apfirebolt.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":"2024-05-17T12:19:18.000Z","updated_at":"2025-06-21T09:09:16.000Z","dependencies_parsed_at":"2024-06-10T15:39:12.463Z","dependency_job_id":"5e39cfa5-2c41-435a-910a-7560532c0e33","html_url":"https://github.com/Apfirebolt/banks_api_express","commit_stats":null,"previous_names":["apfirebolt/banks_api_express"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Apfirebolt/banks_api_express","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Apfirebolt%2Fbanks_api_express","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Apfirebolt%2Fbanks_api_express/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Apfirebolt%2Fbanks_api_express/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Apfirebolt%2Fbanks_api_express/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Apfirebolt","download_url":"https://codeload.github.com/Apfirebolt/banks_api_express/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Apfirebolt%2Fbanks_api_express/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279182480,"owners_count":26121187,"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","status":"online","status_checked_at":"2025-10-16T02:00:06.019Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["banking-api","daisyui","daisyui-svelte","express","express-rate-limit","mongodb","mongoose","nginx","nodejs","svelte"],"created_at":"2024-11-21T02:05:24.670Z","updated_at":"2025-10-16T11:14:12.801Z","avatar_url":"https://github.com/Apfirebolt.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Banks API in Express\r\n\r\n_👀 Banks API having IFSC code of Banks in India\r\n\r\n![NodeJS](https://img.shields.io/badge/node.js-6DA55F?style=for-the-badge\u0026logo=node.js\u0026logoColor=white)\r\n![Express.js](https://img.shields.io/badge/express.js-%23404d59.svg?style=for-the-badge\u0026logo=express\u0026logoColor=%2361DAFB)\r\n![Svelte](https://img.shields.io/badge/svelte-%23ff3e00.svg?style=for-the-badge\u0026logo=svelte\u0026logoColor=white)\r\n![Tailwind CSS](https://img.shields.io/badge/tailwind%20css-%2338B2AC.svg?style=for-the-badge\u0026logo=tailwind-css\u0026logoColor=white)\r\n![DaisyUI](https://img.shields.io/badge/daisyui-%2338B2AC.svg?style=for-the-badge\u0026logo=tailwind-css\u0026logoColor=white)\r\n![MongoDB](https://img.shields.io/badge/MongoDB-%234ea94b.svg?style=for-the-badge\u0026logo=mongodb\u0026logoColor=white)\r\n\r\nThis application contains data of around 160K banks in India with fields such as name, branch, ifsc code, state, contact and district.\r\n\r\nFollowing is the script used to migrate data - bankSeeder.js\r\n\r\n```\r\nimport fs from 'fs';\r\nimport { parse } from 'csv-parse';\r\nimport dotenv from 'dotenv';\r\nimport Bank from \"./models/Bank.js\";\r\nimport connectDB from \"./config/db.js\";\r\n\r\ndotenv.config();\r\n\r\nconnectDB();\r\n\r\nconst filePath = 'data/IFSC.csv';\r\n\r\nawait Bank.deleteMany();\r\n\r\nfs.readFile(filePath, 'utf8', async (err, data) =\u003e {\r\n    if (err) {\r\n        console.error(err);\r\n        return;\r\n    }\r\n\r\n    try {\r\n        const records = await new Promise((resolve, reject) =\u003e {\r\n            parse(data, { columns: true }, (err, records) =\u003e {\r\n                if (err) {\r\n                    reject(err);\r\n                } else {\r\n                    resolve(records);\r\n                }\r\n            });\r\n        });\r\n\r\n        // print only first 5 records\r\n        records.forEach((record) =\u003e {\r\n            Bank.create({\r\n                name: record.BANK,\r\n                ifsc: record.IFSC,\r\n                branch: record.BRANCH,\r\n                centre: record.CENTRE,\r\n                district: record.DISTRICT,\r\n                city: record.CITY,\r\n                state: record.STATE,\r\n                address: record.ADDRESS,\r\n                contact: record.CONTACT,\r\n                upi: record.UPI === 'true' ? true : false,\r\n                rtgs: record.RTGS ? true : false,\r\n                neft: record.NEFT ? true : false,\r\n            }).then((record) =\u003e {\r\n                // console.log(record);\r\n            }).catch((err) =\u003e {\r\n                console.error('failed to create record', err);\r\n            });\r\n        });\r\n        \r\n    } catch (err) {\r\n        console.error(err);\r\n    }\r\n});\r\n\r\n```\r\n\r\nProperties of the bank as given the dataset used to create this API\r\n\r\n```\r\nconst data = {\r\n  BANK: 'Abhyudaya Co-operative Bank',\r\n  IFSC: 'ABHY0065001',\r\n  BRANCH: 'Abhyudaya Co-operative Bank IMPS',\r\n  CENTRE: 'GREATER MUMBAI',\r\n  DISTRICT: 'GREATER MUMBAI',\r\n  STATE: 'MAHARASHTRA',\r\n  ADDRESS: 'ABHYUDAYA BANK BLDG., B.NO.71, NEHRU NAGAR, KURLA (E), MUMBAI-400024',\r\n  CONTACT: '+912225260173',\r\n  IMPS: 'true',\r\n  RTGS: 'true',\r\n  CITY: 'MUMBAI',\r\n  ISO3166: 'IN-MH',\r\n  NEFT: 'true',\r\n  MICR: '400065001',\r\n  UPI: 'true',\r\n  SWIFT: ''\r\n};\r\n```\r\n\r\nReading data using Pandas and Python - read_csv.py\r\n\r\n```\r\nimport pandas as pd\r\n\r\n# import IFSC.csv\r\ndata = pd.read_csv('data/IFSC.csv')\r\n\r\n# get column names\r\nprint(data.columns)\r\n\r\n# get number of entries, 164836 entries in the original database\r\nprint(len(data))\r\n\r\n# group by BANK and get the number of entries for each bank, print the max 5 banks\r\nprint(data.groupby('BANK').size().nlargest(5))\r\n\r\n# group by CITY and get the number of entries for city named LUCKNOW\r\nprint(data.groupby('CITY').size()['NOIDA'])\r\n```\r\n\r\nI was experimenting with advanced filters in the dataset for instance getting all banks in a given city. Grouping the data and more based on column names.\r\n\r\n## Requirements 🏃\r\n\r\n- Node\r\n- MongoDB\r\n- MongoDB Compass (Optional, GUI for MongoDB databases)\r\n- Postman (Optional, for API testing)\r\n\r\n## Install  💥\r\n\r\n```\r\nnpm install\r\nnpm start\r\n```\r\n\r\nThe Express app is configured to run by default on port 3000 but can be easily changed by tweaking server.js file. The front-end Svelte app is configured to run on port 4000 by default\r\n\r\n## Features\r\n\r\n- User authentication 📦\r\n- Search banks by city, branch and state\r\n- Svelte animations and store\r\n\r\n## API Docs\r\n\r\nSwagger docs with decorators are used for generating docs of some of the end-points of the application\r\n\r\n```\r\napp.use('/api/users', userRoutes)\r\napp.use('/api/banks', bankRoutes)\r\n```\r\n\r\n## Deployment\r\n\r\nPlanned to be deployed on Azure using Docker containers.\r\n\r\n## Development\r\n\r\n_Easily set up a local development environment!_\r\n\r\n- clone\r\n- `npm install`\r\n- `npm start`\r\n\r\n**Start coding!** 🎉\r\n\r\nClone this repo on your machine, navigate to its location in the terminal and run:\r\n\r\n## Contributing\r\n\r\nAll contributions are welcome!  \r\nPlease take a moment to review guidelines [PR](.github/pull_request_template.md) | [Issues](https://github.com/Apfirebolt/express-recipe-api/issues/new/choose)\r\n\r\n\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapfirebolt%2Fbanks_api_express","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fapfirebolt%2Fbanks_api_express","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapfirebolt%2Fbanks_api_express/lists"}