{"id":16694924,"url":"https://github.com/kei-k23/csharp-social-media-api","last_synced_at":"2025-05-15T23:33:45.645Z","repository":{"id":247380859,"uuid":"825679776","full_name":"Kei-K23/csharp-social-media-api","owner":"Kei-K23","description":"Social media RestFul API like (Twitter or FaceBook) that build with C# + .NET Core","archived":false,"fork":false,"pushed_at":"2024-07-12T14:14:01.000Z","size":34,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-03T17:13:56.285Z","etag":null,"topics":["asp-net-core","backend-api","csharp","dotnet","dotnet-core","restful-api","sql-server"],"latest_commit_sha":null,"homepage":"","language":"C#","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/Kei-K23.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-07-08T09:52:15.000Z","updated_at":"2025-03-24T18:04:13.000Z","dependencies_parsed_at":"2024-11-20T00:00:32.752Z","dependency_job_id":null,"html_url":"https://github.com/Kei-K23/csharp-social-media-api","commit_stats":{"total_commits":20,"total_committers":1,"mean_commits":20.0,"dds":0.0,"last_synced_commit":"afbaa5ab2184283730c7cc842c2deb8cdce8377f"},"previous_names":["kei-k23/csharp-social-media-api"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kei-K23%2Fcsharp-social-media-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kei-K23%2Fcsharp-social-media-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kei-K23%2Fcsharp-social-media-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Kei-K23%2Fcsharp-social-media-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Kei-K23","download_url":"https://codeload.github.com/Kei-K23/csharp-social-media-api/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254442429,"owners_count":22071864,"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":["asp-net-core","backend-api","csharp","dotnet","dotnet-core","restful-api","sql-server"],"created_at":"2024-10-12T17:04:23.770Z","updated_at":"2025-05-15T23:33:40.613Z","avatar_url":"https://github.com/Kei-K23.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Social Media API \n\nSocial media RestFul API like (Twitter or FaceBook) that build with C# + .NET Core\n\n## Tech Stack\n\n- C#\n- .NET Core\n- SQL Server\n\n## Entity and desing of the system\n\n`Note!` Entity and attributes can change overtimes.\n\n## 1. User Entity\nRepresents a user on the platform.\n\n### Attributes:\n- `id` (Primary Key)\n- `username` (Unique)\n- `email` (Unique)\n- `password` (Hashed)\n- `profile_picture` (URL)\n- `bio` (Text)\n- `followers` (Array of User IDs)\n- `following` (Array of User IDs)\n- `created_at` (Timestamp)\n\n### Relationships:\n- **One-to-Many:** A user can have many posts.\n- **Many-to-Many:** Users can follow each other.\n\n## 2. Post Entity\nRepresents a post created by a user.\n\n### Attributes:\n- `id` (Primary Key)\n- `author_id` (Foreign Key to User)\n- `content` (Text)\n- `image` (URL, optional)\n- `likes` (Array of User IDs)\n- `created_at` (Timestamp)\n\n### Relationships:\n- **One-to-Many:** A post can have many comments.\n- **Many-to-Many:** A post can be liked by many users.\n\n## 3. Comment Entity\nRepresents a comment on a post.\n\n### Attributes:\n- `id` (Primary Key)\n- `post_id` (Foreign Key to Post)\n- `author_id` (Foreign Key to User)\n- `content` (Text)\n- `created_at` (Timestamp)\n\n### Relationships:\n- **Many-to-One:** A comment belongs to a post.\n\n## 4. Notification Entity\nRepresents a notification for user actions like likes, comments, and follows.\n\n### Attributes:\n- `id` (Primary Key)\n- `recipient_id` (Foreign Key to User)\n- `sender_id` (Foreign Key to User)\n- `type` (String: 'like', 'comment', 'follow')\n- `post_id` (Foreign Key to Post, optional)\n- `comment_id` (Foreign Key to Comment, optional)\n- `created_at` (Timestamp)\n- `read` (Boolean)\n\n### Relationships:\n- **Many-to-One:** A notification belongs to a recipient user.\n- **Optional relationships** to Post and Comment depending on the notification type.\n\n## 5. Like Entity\nRepresents a like on a post (can be embedded in the Post entity or separate).\n\n### Attributes:\n- `id` (Primary Key)\n- `post_id` (Foreign Key to Post)\n- `user_id` (Foreign Key to User)\n- `created_at` (Timestamp)\n\n### Relationships:\n- **Many-to-One:** A like belongs to a post.\n- **Many-to-One:** A like belongs to a user.\n\n## Relationships Diagram\n1. **User \u003c-\u003e Post:** One-to-Many (One user can create many posts)\n2. **User \u003c-\u003e User:** Many-to-Many (Users can follow each other)\n3. **Post \u003c-\u003e Comment:** One-to-Many (One post can have many comments)\n4. **Post \u003c-\u003e User:** Many-to-Many (Users can like many posts, and posts can have many likes)\n5. **Notification \u003c-\u003e User:** Many-to-One (Notifications are for users)\n6. **Notification \u003c-\u003e Post/Comment:** Optional (Depending on notification type)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkei-k23%2Fcsharp-social-media-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkei-k23%2Fcsharp-social-media-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkei-k23%2Fcsharp-social-media-api/lists"}