{"id":19021428,"url":"https://github.com/sldeaals/address-microservice-api","last_synced_at":"2026-04-13T06:47:14.688Z","repository":{"id":232414461,"uuid":"783951030","full_name":"sldeaals/address-microservice-api","owner":"sldeaals","description":"API microservice to fetch addresses","archived":false,"fork":false,"pushed_at":"2024-04-25T22:36:56.000Z","size":194,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-21T18:30:41.164Z","etag":null,"topics":["mongodb","nestjs","nodejs","redis","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/sldeaals.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2024-04-08T22:33:56.000Z","updated_at":"2024-04-25T22:35:23.000Z","dependencies_parsed_at":"2024-04-22T02:03:24.416Z","dependency_job_id":"f4be432d-d211-458d-b1d1-920872cd85c6","html_url":"https://github.com/sldeaals/address-microservice-api","commit_stats":null,"previous_names":["sldeaals/address-microservice-api"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/sldeaals/address-microservice-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sldeaals%2Faddress-microservice-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sldeaals%2Faddress-microservice-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sldeaals%2Faddress-microservice-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sldeaals%2Faddress-microservice-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sldeaals","download_url":"https://codeload.github.com/sldeaals/address-microservice-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sldeaals%2Faddress-microservice-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31742941,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T06:26:45.479Z","status":"ssl_error","status_checked_at":"2026-04-13T06:26:44.645Z","response_time":93,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["mongodb","nestjs","nodejs","redis","typescript"],"created_at":"2024-11-08T20:21:45.543Z","updated_at":"2026-04-13T06:47:14.653Z","avatar_url":"https://github.com/sldeaals.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Address Microservice API\n\n\u003cdiv align=\"center\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/MongoDB-4EA94B?style=for-the-badge\u0026logo=mongodb\u0026logoColor=white\" alt=\"MongoDB\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/Mongoose-880000?style=for-the-badge\u0026logo=mongoose\u0026logoColor=white\" alt=\"Mongoose\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/Node.js-339933?style=for-the-badge\u0026logo=node.js\u0026logoColor=white\" alt=\"Node.js\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/Nest.js-E0234E?style=for-the-badge\u0026logo=nestjs\u0026logoColor=white\" alt=\"Nest.js\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/Redis-DC382D?style=for-the-badge\u0026logo=redis\u0026logoColor=white\" alt=\"Redis\"\u003e\n  \u003cimg src=\"https://img.shields.io/badge/TypeScript-3178C6?style=for-the-badge\u0026logo=typescript\u0026logoColor=white\" alt=\"TypeScript\"\u003e\n\u003c/div\u003e\n\n## Overview\n\nThe Address Microservice API is designed to provide address-related functionalities through a RESTful API. It is built using Node.js with Nest.js framework, and utilizes Mongoose for MongoDB interaction and Redis for caching. Swagger is implemented for API documentation.\n\n## Description\n\nDeveloped for shipping services, billing services, among others.\n\n## Features\n\n- **Country:** Fetches countries data.\n- **State:** Fetches states data.\n- **City:** Fetches cities data.\n- **District:** Fetches districts data.\n- **CRUDs:** Maintains address data.\n- **Input Validation:** All user inputs are validated and sanitized to prevent SQL injection and other attacks.\n- **Data Sanitization:** User inputs and data are sanitized before processing to prevent XSS attacks.\n- **Authentication and Authorization:** Implements authentication and authorization mechanisms to ensure only authorized users can access API endpoints.\n- **HTTPS:** Enforces HTTPS to encrypt data transmission and prevent man-in-the-middle attacks.\n- **Rate Limiting:** Implements rate limiting to prevent brute force attacks and DDoS attacks.\n- **Error Handling:** Proper error handling is implemented to avoid leaking sensitive information.\n- **Content Security Policy (CSP):** CSP headers are implemented to prevent XSS attacks by controlling which resources are loaded by the browser.\n- **Input and Output Encoding:** Data is encoded to prevent injection attacks.\n- **Session Management:** Secure session management is implemented to prevent session hijacking and fixation.\n- **Security Headers:** Various security headers such as X-Content-Type-Options, X-Frame-Options, and X-XSS-Protection are implemented to enhance security.\n- **Dependency Management:** Regularly updates dependencies to patch security vulnerabilities.\n\nAdditionally, load balancing with cluster, caching, connection pooling, and logging functionalities are implemented.\n\n## Installation\n\n1. Clone the repository:\n```bash\n$ git clone https://github.com/sldeaals/address-microservice-api.git\n```\n\n2. Install dependencies:\n[Node](https://nodejs.org/en/download/package-manager) | \n[Redis](https://redis.io/docs/latest/operate/oss_and_stack/install/install-redis/)\n\n```bash\n$ cd address-microservice-api\n\n$ nvm use\n\n$ npm i\n```\n\n## Configuration\nEnvironment variables can be set in a .env file. Refer to the .env.example for required variables.\n\n## Usage\n\n1. Start the Redis server:\n```bash\n$ npm run start:redis\n```\n\n2. Start the application:\n```bash\n$ npm start:app\n```\n\n3. Access the API at http://localhost:PORT\n\n### Running the app\n\n```bash\n# development\n$ npm run start:app\n\n# watch mode\n$ npm run start:dev:app\n\n# production mode\n$ npm run start:prod\n\n# concurrently redis \u0026 nest\n\n## For development\n$ npm run start\n\n## watch mode\n$ npm run start:dev\n```\n\n## Test\n\n```bash\n# unit tests\n$ npm run test\n\n# e2e tests\n$ npm run test:e2e\n\n# test coverage\n$ npm run test:cov\n```\n\n## Contributing\n\nContributions are welcome! Please open an issue or submit a pull request.\n\n## Stay in touch\n\n- Author - [Daniel Arias](https://discord.gg/6V6G9xaQ)\n\n## License\n\nAddress Microservice API is [MIT licensed](LICENSE).\n\nFeel free to adjust or expand it according to your specific project requirements!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsldeaals%2Faddress-microservice-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsldeaals%2Faddress-microservice-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsldeaals%2Faddress-microservice-api/lists"}