{"id":28936270,"url":"https://github.com/ale1x/staystrong","last_synced_at":"2026-05-07T14:42:31.844Z","repository":{"id":300097442,"uuid":"1005199765","full_name":"Ale1x/staystrong","owner":"Ale1x","description":"🌟 Simple API serving motivational reasons to help people through difficult moments. 500+ messages in multiple languages.","archived":false,"fork":false,"pushed_at":"2025-09-04T07:00:52.000Z","size":243,"stargazers_count":51,"open_issues_count":1,"forks_count":8,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-04T23:56:13.251Z","etag":null,"topics":["express","mental-health","mental-health-awareness","nodejs"],"latest_commit_sha":null,"homepage":"https://hope.passarelli.dev/reasons","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/Ale1x.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["Ale1x"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":null,"thanks_dev":null,"custom":null}},"created_at":"2025-06-19T20:53:37.000Z","updated_at":"2025-09-21T05:46:57.000Z","dependencies_parsed_at":"2025-09-04T09:04:26.347Z","dependency_job_id":"ded46406-d7ee-4ef4-88d9-a68633c2a0ff","html_url":"https://github.com/Ale1x/staystrong","commit_stats":null,"previous_names":["ale1x/staystrong"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Ale1x/staystrong","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ale1x%2Fstaystrong","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ale1x%2Fstaystrong/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ale1x%2Fstaystrong/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ale1x%2Fstaystrong/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Ale1x","download_url":"https://codeload.github.com/Ale1x/staystrong/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ale1x%2Fstaystrong/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281086013,"owners_count":26441337,"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-26T02:00:06.575Z","response_time":61,"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":["express","mental-health","mental-health-awareness","nodejs"],"created_at":"2025-06-22T20:08:12.699Z","updated_at":"2025-10-26T09:49:16.724Z","avatar_url":"https://github.com/Ale1x.png","language":"JavaScript","funding_links":["https://github.com/sponsors/Ale1x"],"categories":[],"sub_categories":[],"readme":"# StayStrong 💪\n\nA simple API that provides motivational reasons to help people through difficult moments. When life gets tough, sometimes we just need a gentle reminder of our worth and strength.\n\n## 🌟 What it does\n\nStayStrong serves random motivational messages in multiple languages to remind you that:\n- You are loved and valued\n- You have overcome challenges before\n- Tomorrow can be better than today\n- You deserve happiness and peace\n- You are stronger than you think\n\n## 💭 Why?\n\nThis project was born from personal struggle. I've been going through difficult times, dealing with challenges that sometimes made me forget my own worth and strength. During those dark moments, I realized how powerful a few simple words of encouragement can be.\n\nI created StayStrong not just for myself, but for everyone who, like me, sometimes needs a gentle reminder that they matter, that they're stronger than they think, and that better days are ahead. \n\nSometimes we all need someone to tell us:\n- \"You are not alone\"\n- \"You have value\"\n- \"You can get through this\"\n- \"You are loved\"\n\nIf you're reading this and you're struggling too, know that you're not alone. This little API is my way of sending you a virtual hug and a reminder that you matter. We're in this together. 🤗\n\n## 🚀 Quick Start\n\n### Installation\n\n```bash\n# Clone the repository\ngit clone https://github.com/Ale1x/staystrong.git\ncd staystrong\n\n# Install dependencies\nnpm install\n\n# Compile language files\nnpm run compile-lang\n\n# Start the server\nnpm start\n```\n\nThe server will start on port 3000 (or the port specified in the `PORT` environment variable).\n\n### Docker Deployment\n\nYou can also run StayStrong using Docker for easy deployment:\n\n**Using the pre-built image:**\n\n```bash\n# Pull and run the Docker image\ndocker run -p 3000:3000 ghcr.io/ale1x/staystrong:latest\n```\n\n**Building locally:**\n\n```bash\n# Build the Docker image\ndocker build -t staystrong .\n\n# Run the container\ndocker run -p 3000:3000 staystrong\n```\n\n**Using Docker Compose:**\n\n```bash\n# Start the application with Docker Compose\ndocker compose up -d\n\n# Stop the application\ndocker compose down\n```\n\nThe Docker setup includes:\n- Production-ready Node.js environment\n- Health checks for container monitoring\n- Environment variable support\n- Optimized multi-stage build for smaller image size\n- Pre-built image available at `ghcr.io/ale1x/staystrong`\n\n## 📖 API Usage\n\n### Get a Random Motivational Reason\n\n**Endpoint:** `GET /reasons`\n\n**Query Parameters:**\n- `lang` (optional): Language code (`en` for English, `it` for Italian, `de` for German, `ar` for Arabic (more to come)). Defaults to `en`.\n\n**Example Requests:**\n\n```bash\n# Get a reason in English (default)\ncurl http://localhost:3000/reasons\n\n# Get a reason in Italian\ncurl http://localhost:3000/reasons?lang=it\n\n# Get a reason in German\ncurl http://localhost:3000/reasons?lang=de\n\n# Get a reason in Arabic\ncurl http://localhost:3000/reasons?lang=ar\n\n# Get a reason in English (explicit)\ncurl http://localhost:3000/reasons?lang=en\n```\n\n**Example Response:**\n\n```json\n{\n  \"reason\": \"You are stronger than any storm that may cross you.\",\n  \"lang\": \"en\"\n}\n```\n\n### Rate Limiting\n\nThe API implements rate limiting to ensure fair usage:\n- **Limit:** 100 requests per minute per IP address\n- **Response when exceeded:** HTTP 429 with error message\n\n## 🌍 Supported Languages\n\n- **English** (`en`) - 500 motivational reasons\n- **Germany** (`de`) - 500 motivational reasons\n- **Italian** (`it`) - 500 motivational reasons\n- **Arabic** (`ar`) - 460 motivational reasons\n\n## 🛠️ Technical Details\n\n- **Framework:** Express.js (^5.1.0)\n- **Rate Limiting:** express-rate-limit (^7.5.0)\n- **Response Format:** JSON\n- **Content-Type:** `application/json`\n- **CORS:** Not configured (add if needed for browser clients)\n\n## 📝 Contributing\n\nWant to help make StayStrong better? Here are some ways to contribute:\n\n### Adding New Languages\n\n1. Create a new JSON file in the `reasons/` directory (e.g., `fr.json` for French)\n2. Add an array of motivational reasons in that language\n3. Run `npm run compile-lang` to update the combined language file\n4. Update the `supportedLangs` documentation\n\n### Adding More Reasons\n\n1. Edit the appropriate language file in the `reasons/` directory\n2. Add new motivational messages to the JSON array\n3. Run `npm run compile-lang` to update the combined language file\n4. Ensure all messages are positive, supportive, and appropriate\n\n### Code Improvements\n\n- Submit bug fixes\n- Improve error handling\n- Add new features (while keeping the API simple)\n- Improve documentation\n\n## 🤝 Philosophy\n\nStayStrong believes that sometimes the smallest gestures can make the biggest difference. A few words of encouragement at the right moment can change someone's entire day, or even their life.\n\nThis project aims to be:\n- **Simple:** Easy to use and integrate\n- **Positive:** All content focuses on hope and strength\n- **Accessible:** Available in multiple languages\n- **Free:** Always available for anyone who needs it\n\n## 🆘 Crisis Resources\n\n**If you are in immediate danger or having thoughts of self-harm, please reach out for professional help immediately.**\n\n### International\n- **International Association for Suicide Prevention**: [https://www.iasp.info/resources/Crisis_Centres/](https://www.iasp.info/resources/Crisis_Centres/)\n- **Crisis Text Line**: Text HOME to 741741 (US, UK, Canada)\n\n### United States\n- **988 Suicide \u0026 Crisis Lifeline**: **988** or [https://988lifeline.org/](https://988lifeline.org/)\n- **Crisis Text Line**: Text HOME to **741741**\n\n### United Kingdom\n- **Samaritans**: **116 123** (free) or [https://www.samaritans.org/](https://www.samaritans.org/)\n- **Crisis Text Line UK**: Text SHOUT to **85258**\n\n### Italy\n- **Telefono Amico Italia**: **02 2327 2327** or [https://www.telefonoamico.it/](https://www.telefonoamico.it/)\n- **Samaritans Onlus**: **06 77208977** or [http://www.samaritansonlus.org/](http://www.samaritansonlus.org/)\n\n### Online Resources\n- **7 Cups**: Free emotional support - [https://www.7cups.com/](https://www.7cups.com/)\n- **BetterHelp**: Professional online therapy - [https://www.betterhelp.com/](https://www.betterhelp.com/)\n- **Mental Health America**: [https://www.mhanational.org/](https://www.mhanational.org/)\n\n**Remember: Seeking help is a sign of strength, not weakness. You matter, and there are people who want to help you through this.** 💜\n\n## 🙏 Contributors\n\nThanks to everyone who has contributed to making StayStrong better:\n\n- [@isaac0yen](https://github.com/isaac0yen) - Contributed to architecture improvements and code optimization\n- [@LeCyreaxYT](https://github.com/LeCyreaxYT) - Added German translation\n- [@lock-pay](https://github.com/lock-pay) - Added French translation\n\nWant to join our contributors? Check out the [Contributing](#-contributing) section above!\n\n## 📄 License\n\nThis project is open source. Feel free to use it, modify it, and share it to help spread positivity in the world.\n\n## 💡 Examples\n\n### Integration Examples\n\n**JavaScript/Fetch:**\n```javascript\nfetch('https://your-domain.com/reasons?lang=en')\n  .then(response =\u003e response.json())\n  .then(data =\u003e console.log(data.reason));\n```\n\n**Python:**\n```python\nimport requests\n\nresponse = requests.get('https://your-domain.com/reasons?lang=it')\ndata = response.json()\nprint(data['reason'])\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fale1x%2Fstaystrong","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fale1x%2Fstaystrong","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fale1x%2Fstaystrong/lists"}