diff --git a/api/Insomnia_2023-11-08.json b/api/Insomnia_2023-11-08.json new file mode 100644 index 0000000..ece72ef --- /dev/null +++ b/api/Insomnia_2023-11-08.json @@ -0,0 +1 @@ +{"_type":"export","__export_format":4,"__export_date":"2023-11-08T10:44:11.509Z","__export_source":"insomnia.desktop.app:v8.3.0","resources":[{"_id":"req_d416d9fd06d1410daf72df8e31de5f53","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699298103836,"created":1698421686527,"url":"http://localhost:9091/login","name":"Login","description":"","method":"GET","body":{},"parameters":[{"name":"username","value":"Laila","id":"pair_4771135f759d4caf91827229b429d06e"},{"name":"password","value":"12345","id":"pair_590ada80a34047cc8ec83739f46b82d0"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"}],"authentication":{},"metaSortKey":-1698421686527,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","parentId":null,"modified":1698955638349,"created":1698955638349,"name":"My Collection","description":"","scope":"collection","_type":"workspace"},{"_id":"req_5dac4160688e49578343943e25a7d38d","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699124464083,"created":1698421681950,"url":"http://localhost:9091/register","name":"Register","description":"","method":"POST","body":{},"parameters":[{"name":"UserName","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'firstName', '', '', '', '', '', '', 'en' %}"},{"name":"PersonId","value":"{% uuid 'v4' %}"},{"name":"Password","value":"12345"},{"name":"Email","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'firstName', '', '', '', '', '', '', 'en' %}@example.com"},{"name":"ProfilePicUrl","value":"{% faker 'image', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"AccountTime","value":"{% now 'unix', '' %}"},{"name":"BirthDate","value":"{% faker 'date', '', '', '', '', '', '', '', 'birthdate', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Gender","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'sex', '', '', '', '', '', '', 'en' %}"},{"name":"LastEdit","value":"{% now 'unix', '' %}"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"}],"authentication":{},"metaSortKey":-1698421681950,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_4ac6b5b5ebe2407d9dc73a7da18e5d5f","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698218958045,"created":1698218933637,"url":"http://localhost:8081/post","name":"test","description":"","method":"POST","body":{},"parameters":[{"name":"Name","value":"Jony","disabled":false},{"name":"Age","value":"25","disabled":false},{"name":"Tag","value":"coder","disabled":false},{"name":"Tag","value":"perfumer","disabled":false},{"name":"Tag","value":"researcher","disabled":false}],"headers":[],"authentication":{},"metaSortKey":-1698218933637,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_a0c4f12c360f4825b5d3bcbe5470587b","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699044142053,"created":1699044071408,"url":"http://localhost:9091/post","name":"POST","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"6c3c8515-6614-4cde-83dd-c269220850e6","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"5306d885385a04ea829b2988297593ec212432ceb1f75de4e9039ad76ec6c9e55510549b9e2a2f34e3e81db948658398"}],"authentication":{},"metaSortKey":-1698186775318.5,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_d67633903ee343be897e38000d9c24d4","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699125190487,"created":1699089288044,"url":"http://localhost:9091/posts_n","name":"Multi POSTs","description":"","method":"GET","body":{},"parameters":[{"id":"pair_8ca24860b8e24bccb680f809f0b56750","name":"num_posts","value":"15","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"5306d885385a04ea829b2988297593ec212432ceb1f75de4e9039ad76ec6c9e55510549b9e2a2f34e3e81db948658398"}],"authentication":{},"metaSortKey":-1698170696159.25,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_27c3383dbe3b461ab24a4031e4508768","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699044161934,"created":1698007819857,"url":"http://localhost:9091/post","name":"POST","description":"","method":"POST","body":{},"parameters":[{"name":"Id","value":"{% uuid 'v4' %}","id":"pair_18055d14384649cc83c2f7405d162620"},{"name":"Community","value":"Gamer","id":"pair_c8595271704f4396851a7b50dc1685e7"},{"name":"Content","value":"{% faker 'lorem', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'text', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_83dd98a45195456da7cb10eaea1a291a"},{"name":"Author","value":"{% faker 'internet', '', '', '', '', '', '', '', '', '', '', '', '', 'userName', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_b1b009bc64b1467f93dffe225a4a0407"},{"name":"Parent","value":"{% uuid 'v4' %}","id":"pair_7114bfdc11a448a8a1e65ffe8db847ae"},{"name":"CreatedAt","value":"{% now 'unix', '' %}","id":"pair_2a692d4c8f8a4db690c7d1f262e245aa"},{"name":"UpdatedAt","value":"0","id":"pair_ffa74a25eb9f43a8ae07aced6a89f335"},{"name":"DeletedAt","value":"0","id":"pair_7bb09170ea434c5092bf6a3d836c4e91"},{"name":"Likes","value":"0","id":"pair_d4e1a2efdf954b678dca201ac5c05cab"},{"name":"Shares","value":"0","id":"pair_f1fb433554224489b5b957497c9b7b3f"},{"name":"Comments","value":"0","id":"pair_5b2c717a576b436bbf1a0974d01e996b"},{"name":"Children","value":"{% uuid 'v4' %}","id":"pair_2e652b2926fc42f9829f0e7ff305cbec"},{"name":"Children","value":"{% uuid 'v4' %}","id":"pair_268154cd1b0a4d5fa6082570a555e230"},{"name":"Children","value":"{% uuid 'v4' %}","id":"pair_a96f59cc388a42ca902f2ba4a47c7946"},{"name":"Tags","value":"{% faker 'hacker', '', '', '', 'department', '', '', '', '', '', '', 'noun', '', '', '', '', '', '', '', '', 'unit', '', 'commonFileName', '', '', 'en' %}","id":"pair_a224ff0b43654c89b29c1c22137bc337"},{"name":"Tags","value":"{% faker 'hacker', '', '', '', 'department', '', '', '', '', '', '', 'noun', '', '', '', '', '', '', '', '', 'unit', '', 'commonFileName', '', '', 'en' %}","id":"pair_ce8a1b85de2e49b8b9e25f23b7e14e8a"},{"name":"Tags","value":"{% faker 'hacker', '', '', '', 'department', '', '', '', '', '', '', 'noun', '', '', '', '', '', '', '', '', 'unit', '', 'commonFileName', '', '', 'en' %}","id":"pair_2df8c039934c4c8699c266fcbc3eae0d"},{"name":"Mentions","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'jobArea', '', '', '', '', '', '', 'en' %}","id":"pair_55e18887c1544622910c1a39a0b99b1f"},{"name":"Mentions","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'jobArea', '', '', '', '', '', '', 'en' %}","id":"pair_f44a8e8aa4a145acae388f968b5d23d9"},{"name":"Mentions","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'jobArea', '', '', '', '', '', '', 'en' %}","id":"pair_779caff0e9d44acca75d2bd45a23aede"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"5306d885385a04ea829b2988297593ec212432ceb1f75de4e9039ad76ec6c9e55510549b9e2a2f34e3e81db948658398"}],"authentication":{},"metaSortKey":-1698154617000,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_7bc09d3f2a714186bda2ae8f37665a12","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699133973851,"created":1699042571110,"url":"http://localhost:9091/person","name":"PERSON","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"bc4d36e5-01fd-4915-8be5-db0c2f1143a1","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698138537840.75,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_7fbf2f1ad1a5446984ce4cfc3988e3de","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698967589628,"created":1698953857002,"url":"http://localhost:9091/person","name":"PERSON","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"3b52426f-9333-4096-8ca5-f4ea75f83575","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"ceb783ce96069b08c6d3bc168a4b4df38438e3b3518596591761959e5c277a17a2ec3f7fd8b5c4b0d8892ebc3da473ed"}],"authentication":{},"metaSortKey":-1698122458681.5,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_b1a04c137bbd47bc8d111d14177bcc40","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699192016082,"created":1698090300363,"url":"http://localhost:9091/person","name":"PERSON","description":"","method":"POST","body":{},"parameters":[{"name":"Id","value":"{% uuid 'v4' %}"},{"name":"Attachment","value":"https://example.com/attachment"},{"name":"AttributedTo","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'firstName', '', '', '', '', '', '', 'en' %}"},{"name":"Context","value":"https://example.com/context"},{"name":"MediaType","value":"image/jpeg"},{"name":"EndTime","value":"{% now 'unix', '' %}"},{"name":"Generator","value":"{% faker 'system', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Icon","value":"https://example.com/icon"},{"name":"Image","value":"https://example.com/image"},{"name":"InReplyTo","value":"{% faker 'number', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Location","value":"Qatar"},{"name":"Preview","value":"https://example.com/preview"},{"name":"PublishedTime","value":"{% now 'unix', '' %}"},{"name":"Replies","value":"{% uuid 'v4' %}"},{"name":"Replies","value":"{% uuid 'v4' %}"},{"name":"Replies","value":"{% uuid 'v4' %}"},{"name":"StartTime","value":"{% now 'unix', '' %}"},{"name":"Summary","value":"This is a summary"},{"name":"Tag","value":"coder"},{"name":"Tag","value":"perfumer"},{"name":"Tag","value":"researcher"},{"name":"UpdatedTime","value":"{% now 'unix', '' %}"},{"name":"Url","value":"https://example.com"},{"name":"Url","value":"https://example1.com"},{"name":"Url","value":"https://example2.com"},{"name":"Too","value":"fake@example.com"},{"name":"Too","value":"fake1@example.com"},{"name":"Too","value":"fake2@example.com"},{"name":"Bto","value":"alice@example.com"},{"name":"Bto","value":"alice2@example.com"},{"name":"Bto","value":"alice3@example.com"},{"name":"Cc","value":"charlie@example.com"},{"name":"Cc","value":"charlie4@example.com"},{"name":"Cc","value":"charlie5@example.com"},{"name":"Bcc","value":"dave@example.com"},{"name":"Bcc","value":"dave6@example.com"},{"name":"Bcc","value":"dave7@example.com"},{"name":"Likes","value":"10"},{"name":"Shares","value":"5"},{"name":"Inbox","value":"https://example.com/inbox"},{"name":"Outbox","value":"https://example.com/outbox"},{"name":"Following","value":"https://example.com/page/{% uuid 'v4' %}"},{"name":"Following","value":"https://example.com/group/{% uuid 'v4' %}"},{"name":"Following","value":"https://example.com/person/{% uuid 'v4' %}"},{"name":"Followers","value":"https://example.com/page/{% uuid 'v4' %}"},{"name":"Followers","value":"https://example.com/group/{% uuid 'v4' %}"},{"name":"Followers","value":"https://example.com/person/{% uuid 'v4' %}"},{"name":"Liked","value":"{% uuid 'v4' %}"},{"name":"Liked","value":"{% uuid 'v4' %}"},{"name":"Liked","value":"{% uuid 'v4' %}"},{"name":"PreferredUsername","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Endpoints","value":"https://example.com/endpoint1"},{"name":"Streams","value":"https://example.com/stream1"},{"name":"PublicKey","value":"https://example.com/publickey"},{"name":"Username","value":"{% faker 'internet', '', '', '', '', '', '', '', '', '', '', '', '', 'userName', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698090300363,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_1ab22ba1e2554b75989c5bffdb2c69d9","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698955902814,"created":1698149469871,"url":"http://localhost:9091/community","name":"Community","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"85b1020f-6b52-4c4f-afa5-91201a4ca256","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698069680236.5,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_12f06829623e4c8590ede2a60126f9a4","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698967646721,"created":1698955747234,"url":"http://localhost:9091/community","name":"Community","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"76d3b1cb-bd6d-4ba8-b7e9-2b921cf75a4b","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0","id":"pair_dd0f31fb25114d358c3b4da96137225a"},{"name":"Anon-User","value":"Carole","id":"pair_71664a85b0b34ff39c6dce6683b5b74f"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2","id":"pair_fb097e7bb1af46d9b4325f4cc7234346"}],"authentication":{},"metaSortKey":-1698059370173.25,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_2c72b1a7696c49f4b816beaa72df4ab5","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699157390292,"created":1698148687006,"url":"http://localhost:9091/community","name":"Community","description":"","method":"POST","body":{},"parameters":[{"name":"Id","value":"{% uuid 'v4' %}","id":"pair_ae40dc96301945f3be1379a9397e9528"},{"name":"InstanceName","value":"DU","id":"pair_a13dd9eda26a41729eb1f5bb2edf2950"},{"name":"InstanceId","value":"d9f129f4-b8e8-4a57-b8aa-5e190899b9e","id":"pair_3fd25e7bbbe84f66a4417b99e06d4c05"},{"name":"Name","value":"{% faker 'company', '', '', '', '', 'catchPhraseAdjective', '', '', '', '', '', 'noun', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %} Community","id":"pair_266c7c40603548a7a925419ee319bcd3"},{"name":"Description","value":"{% faker 'science', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_9591946918a646ae9e54a5da3eeeb356"},{"name":"Icon","value":"{% faker 'image', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_e88a2a1d97304d7aa4117277d6f4e699"},{"name":"Cover","value":"{% faker 'image', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_12723c3af82848e0a05f990aa2c173f5"},{"name":"CreatedAt","value":"{% now 'unix', '' %}","id":"pair_5df4864d6a184cb29715d34de5f3962a"},{"name":"UpdatedAt","value":"{% now 'unix', '' %}","id":"pair_9aaad2ed736a47bc941da9c4e8e4c085"},{"name":"Members","value":"{% faker 'number', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_0b70d28ea61f496f9f1e91b089064d99"},{"name":"Admins","value":"jony,rony,koko","id":"pair_92f71553d9d249e78d4506434bfa6d7e"},{"name":"Moderators","value":"jony,rony,koko","id":"pair_c3482a2c707c40919c56ccb9c580aaf1"},{"name":"Post","value":"{% uuid 'v4' %}","id":"pair_b9d6fcbb35644cfa97016ba6bb647af6"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698049060110,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_cd9246929fbc4f02b680e8bb99e10252","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437494095,"created":1698246032201,"url":"http://localhost:9091/instance","name":"Instance","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"c91b3811-3026-4c85-bc8e-0a9e95529261","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698042616320.4688,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_b57b5102d39243f59fe638fcbbafcd8d","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698967746988,"created":1698955836278,"url":"http://localhost:9091/instance","name":"Instance","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"Id","value":"141eabf0-1302-481f-bc46-88e94c9f8f4b","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0","id":"pair_c294a8b311604c6c8d2b753a8fc1620e"},{"name":"Anon-User","value":"Carole","id":"pair_ce37d6640dec455ca29dde606e742370"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2","id":"pair_4323a5255eec414e816273961582e312"}],"authentication":{},"metaSortKey":-1698041810846.7773,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_e922e15727374c02867d054768fb7397","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437504841,"created":1698149498959,"url":"http://localhost:9091/instance","name":"Instance","description":"","method":"POST","body":{},"parameters":[{"name":"Id","value":"{% uuid 'v4' %}"},{"name":"Name","value":"GitHub Copilot"},{"name":"Description","value":"An AI programming assistant"},{"name":"Type","value":"Software"},{"name":"Status","value":"Active"},{"name":"Owner","value":"{% faker 'company', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"CreatedBy","value":"{% request 'name', '', 0 %}"},{"name":"CommunityIds","value":"1"},{"name":"CommunityIds","value":"2"},{"name":"CommunityIds","value":"3"},{"name":"CreatedAt","value":"{% now 'unix', '' %}"},{"name":"UpdatedBy","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"UpdatedAt","value":"{% now 'unix', '' %}"},{"name":"DeletedBy","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"DeletedAt","value":"{% now 'unix', '' %}"},{"name":"Tags","value":"AI"},{"name":"Tags","value":"Programming"},{"name":"Tags","value":"Assistant"},{"name":"Labels","value":"Feature Request"},{"name":"Labels","value":"Bug"},{"name":"PublicDomain","value":"www.example.com"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698041005373.086,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_c0b1cb7ae78e4a02a8ce39b87971fd26","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699192009963,"created":1698253744227,"url":"http://localhost:9091/comments","name":"Comments","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"cid","value":"5da2a790-74f2-4a52-8f27-e17dcd33d460","description":"Comment ID"},{"id":"pair_3505ae430a7b44638850ee0acbb75cbd","name":"pid","value":"107c2076-67ed-4df4-a6ce-a41079313057","description":"Post ID"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698039394425.7031,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_b9728bcdbd98443299c14167cfec3407","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699298573089,"created":1699298013175,"url":"http://localhost:9091/commentsbypost","name":"CommentsByPost(multi)","description":"","method":"GET","body":{},"parameters":[{"id":"pair_3505ae430a7b44638850ee0acbb75cbd","name":"pid","value":"546d41d1-876f-4455-be64-d1b4ca845f1f","description":"Post ID"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Laila"},{"name":"Anon-Token","value":"85005406a191cc319a29c29ff4f77c78121c8d5be9be757a23d587528e79c555c78903acec8ddee16ceeb3f65876966a"}],"authentication":{},"metaSortKey":-1698039193054.1553,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_61f22f05597e4307add789d047a78056","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698967759860,"created":1698955977010,"url":"http://localhost:9091/comments","name":"Comments","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"cid","value":"5da2a790-74f2-4a52-8f27-e17dcd33d460","description":"Comment ID"},{"id":"pair_3505ae430a7b44638850ee0acbb75cbd","name":"pid","value":"107c2076-67ed-4df4-a6ce-a41079313057","description":"Post ID"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698038991682.6074,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_bf18fd23ed0f446789df3d4df6ecac95","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699298140991,"created":1698253142694,"url":"http://localhost:9091/comments","name":"Comments","description":"","method":"POST","body":{},"parameters":[{"name":"Id","value":"{% uuid 'v4' %}","id":"pair_4348da5a37fc460da7ab60af519ed3c0"},{"name":"User","value":"C{% faker 'internet', '', '', '', '', '', '', '', '', '', '', '', '', 'userName', '', '', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_a01133cb43d04667841c9cde054bcaa4"},{"name":"PostId","value":"546d41d1-876f-4455-be64-d1b4ca845f1f","id":"pair_2e7743c307e74a0681000df45112ee4f"},{"name":"UserId","value":"{% uuid 'v4' %}","id":"pair_7ebfc4cc7c78458fb862a6d0d0c3a714"},{"name":"RepliedTo","value":"{% uuid 'v4' %}","id":"pair_ea345b4d11964f4f82887bc1be2e23c2"},{"name":"Content","value":"{% faker 'lorem', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'paragraphs', '', '', '', '', '', '', '', '', '', 'en' %}","id":"pair_6fc45ee36f194d49a24abc8e706cc600"},{"name":"CreatedDate","value":"{% now 'unix', '' %}","id":"pair_f4557eff55d54105b5fe0acb09bdc552"},{"name":"UpdatedDate","value":"{% now 'unix', '' %}","id":"pair_fe62f73105d04b4ab8aeda59ce0e16b5"},{"name":"Likes","value":"{% faker 'number', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'octal', '', '', '', '', '', '', '', 'en' %}","id":"pair_1cfe11b45a324efd954b997498475869"},{"name":"Replies","value":"{% uuid 'v4' %}","id":"pair_622775d0c2d34e49ae2761b1d2198744"},{"name":"Replies","value":"{% uuid 'v4' %}","id":"pair_9dec14c2f3ae46ba847eafe4e07c6f11"},{"name":"Replies","value":"{% uuid 'v4' %}","id":"pair_a5cc1c15cdf64b15985acbc73a950f44"},{"name":"IsDeleted","value":"false","id":"pair_216f2802e278478abe48a7e396e4ec13"},{"name":"IsUpdated","value":"false","id":"pair_dd491d40a4d14576856f0d9f95e874c9"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Laila"},{"name":"Anon-Token","value":"85005406a191cc319a29c29ff4f77c78121c8d5be9be757a23d587528e79c555c78903acec8ddee16ceeb3f65876966a"}],"authentication":{},"metaSortKey":-1698038588939.5117,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_e2081103122543a7a14cd40ede2afea2","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437524798,"created":1698257847498,"url":"http://localhost:9091/message","name":"message","description":"","method":"GET","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"MsgId","value":"eed52709-ff15-48b5-812f-283897d732eb","description":"Comment ID"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698037783453.3203,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_6839ff994fc14defbb2bdd8649a08990","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698968282490,"created":1698956032609,"url":"http://localhost:9091/message","name":"message","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_fb2fe53f2c834cc4a124d55d50aaaae2","name":"MsgId","value":"eed52709-ff15-48b5-812f-283897d732eb","description":"Comment ID"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698037582075.5225,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_cd814e7e85f44a3ba073bfeb0715e088","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699154774278,"created":1698253888040,"url":"http://localhost:9091/message","name":"message","description":"","method":"POST","body":{},"parameters":[{"name":"MsgId","value":"{% uuid 'v4' %}"},{"name":"SenderId","value":"{% uuid 'v4' %}"},{"name":"ReceiverId","value":"{% uuid 'v4' %}"},{"name":"Content","value":"{% faker 'lorem', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'paragraph', '', '', '', '', '', 'alpha', '', '', '', 'en_US' %}"},{"name":"SentTime","value":"{% now 'unix', '' %}"},{"name":"LastEdit","value":"{% now 'unix', '' %}"},{"name":"DeleteTime","value":"{% now 'unix', '' %}"},{"name":"Status","value":"0"},{"name":"Attachment","value":"{% faker 'database', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Types","value":"e/font/ttf"},{"name":"Reaction","value":"{% faker 'internet', '', '', '', '', '', '', '', '', '', '', '', '', 'emoji', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698037380697.7246,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_3eec2dc3b1574bcc90d2086589233a54","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437534911,"created":1698259678853,"url":"http://localhost:9091/follower","name":"Follower","description":"","method":"GET","body":{},"parameters":[{"name":"UserId","value":"7e52146c-5b83-494d-82e3-c14af0ab355c","id":"pair_1a1d4ed0a10f4fb78ef7c84e7278f469"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036977942.129,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_029342af35f6423c81cea45f5f2cea57","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698968309800,"created":1698956100992,"url":"http://localhost:9091/follower","name":"Follower","description":"","method":"DELETE","body":{},"parameters":[{"name":"UserId","value":"fd790f39-0d4e-43e1-a2f9-46a6dcda96e1","id":"pair_1a1d4ed0a10f4fb78ef7c84e7278f469"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698036877246.98,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_bf424963405d4ea1942563aaea3b5261","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437539831,"created":1698259715615,"url":"http://localhost:9091/follower","name":"Follower","description":"","method":"POST","body":{},"parameters":[{"name":"UserId","value":"{% uuid 'v4' %}","id":"pair_c70516b7470e4df6a1927420dfed047a"},{"name":"Status","value":"0","id":"pair_d35b3ba7d2e84f4ba74aaf1059ad522b"},{"name":"Time","value":"{% now 'unix', '' %}","id":"pair_9cb5edd495d64ae8bf4e59ed6d335d2f"},{"name":"FollowAccount","value":"{% uuid 'v4' %}","id":"pair_ab25bd39c2f045d894a959193a2f1e90"},{"name":"UnfollowAccount","value":"{% uuid 'v4' %}","id":"pair_300aa13e37704d48b9889d1927e0e6c4"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036776551.831,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_2f7eb4ac8a4845c8b4dbf0ef1ef53f99","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437546846,"created":1698259702269,"url":"http://localhost:9091/followee","name":"Followee","description":"","method":"GET","body":{},"parameters":[{"name":"UserId","value":"1e3bfb2d-79bd-4bea-a336-21b7c9fdd307"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036575161.5332,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_7a9060f61ac1438aaeb4d036fc2ca598","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698967766676,"created":1698956184006,"url":"http://localhost:9091/followee","name":"Followee","description":"","method":"DELETE","body":{},"parameters":[{"name":"UserId","value":"1e3bfb2d-79bd-4bea-a336-21b7c9fdd307"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698036524813.9587,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_ca4ffb9f35f4492888d732a26181535c","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437553662,"created":1698259670421,"url":"http://localhost:9091/followee","name":"Followee","description":"","method":"POST","body":{},"parameters":[{"name":"UserId","value":"{% uuid 'v4' %}"},{"name":"BlockAccountLink","value":"{% uuid 'v4' %}"},{"name":"BlockAccountName","value":"fake {% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'fullName', '', '', '', '', '', '', 'en' %}"},{"name":"Time","value":"{% now 'unix', '' %}"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036474466.3843,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_d4fb3cde850c4f218eda8a31e932bd53","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1699156637543,"created":1698932420130,"url":"http://localhost:9091/like","name":"like","description":"","method":"POST","body":{},"parameters":[{"name":"EntityId","value":"{% uuid 'v4' %}","id":"pair_9da2d65364c34d74b39a9c2d4466778b"},{"name":"UserId","value":"{% faker 'person', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'firstName', '', '', '', '', '', '', 'en' %}","id":"pair_4d0ad71398c241d0b7764cfa74733e5b"},{"name":"CreatedAt","value":"{% now 'unix', '' %}","id":"pair_c08ab5b6b2d74688b7df7b050efd9546"},{"name":"EntityType","value":"Post","id":"pair_96bbc5c2a79d4d89b26b03c360ebda9b","disabled":true},{"name":"EntityType","value":"Comment","id":"pair_93f770555cdf4f10ae50587bfea7e069","disabled":true},{"name":"EntityType","value":"Reel","id":"pair_4cb92472316e4152be3c5c624f8e8f19","disabled":true},{"name":"EntityType","value":"Event","id":"pair_89b194e16cdd4ae7afe104a06b8bec0a","disabled":true},{"name":"EntityType","value":"Group","id":"pair_1e1c2c6b12084510ae34c742e7b5cc04","disabled":false}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"72c847ad52d285e5082f22ee2ee45a392bef10aa8623f2aad22a5afd2384278b594beee03d5dca98fe3b510187ec3d7e"}],"authentication":{},"metaSortKey":-1698036424118.8098,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_58bf2f8611ea4fad8f156b7680bc760a","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698932432563,"created":1698932406302,"url":"http://localhost:9091/followee","name":"Like","description":"","method":"GET","body":{},"parameters":[{"name":"UserId","value":"1e3bfb2d-79bd-4bea-a336-21b7c9fdd307"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036398945.0225,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_e5f1285acd4c44f89415c2471d52191e","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698938429384,"created":1698938387627,"url":"http://localhost:9091/likes_entity","name":"Likes by Enity","description":"","method":"GET","body":{},"parameters":[{"name":"EntityId","value":"bb7e85ec-e193-4825-a018-9b4b31b7e397","id":"pair_e6adf5372aba46d2a9d3072d82bc7068"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036392651.5757,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_fc4b368174f54744b7f87ce753beb7c9","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698938550652,"created":1698938454610,"url":"http://localhost:9091/likes_user","name":"Likes by User","description":"","method":"GET","body":{},"parameters":[{"name":"UserId","value":"Barrett","id":"pair_e6adf5372aba46d2a9d3072d82bc7068"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036389504.8523,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_7c2c9c3bf3cf4310b9344a7ad28ae87c","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698968522072,"created":1698932441967,"url":"http://localhost:9091/like","name":"Like","description":"","method":"DELETE","body":{},"parameters":[{"name":"EntityId","value":"62f9ac77-1d06-4f27-8d2c-c4bf7e842799","id":"pair_a958be605e0f45e5893453568d6ebb11"},{"name":"UserId","value":"Urban","id":"pair_465404c24497492381851f2c343a20ca"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698036386358.129,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_dc8764cef49e4d5284d94dcbb6839407","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698956445222,"created":1698262009670,"url":"http://localhost:9091/notification","name":"notification","description":"","method":"GET","body":{},"parameters":[{"name":"Receiver","value":"","id":"pair_0bf0ec16743b40ef8900275380e718b8"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036373771.2354,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_50f471c16a074a0dbb108a821df825a9","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698437576390,"created":1698261478336,"url":"http://localhost:9091/notification","name":"Notification","description":"","method":"POST","body":{},"parameters":[{"name":"Receiver","value":"{% uuid 'v4' %}"},{"name":"Title","value":"fake {% faker 'lorem', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'sentence', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Body","value":"fake {% faker 'lorem', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'paragraphs', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Source","value":"{% uuid 'v4' %}"},{"name":"Image","value":"{% faker 'image', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'en' %}"},{"name":"Sound","value":"Defaults"},{"name":"Time","value":"{% now 'unix', '' %}"},{"name":"Channel","value":"{% uuid 'v4' %}"},{"name":"PriorityLevel","value":"{% faker 'number', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', 'octal', '', '', '', '', '', '', '', 'en' %}"},{"name":"ReadStatus","value":"0"},{"name":"Created","value":"{% now 'unix', '' %}"}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"d09298dea57f24eacf66f959b5569809830d1d6f228e39932f1fe112aadec5d8a5ca892ec80d67bbbeb80a364e23ea57"}],"authentication":{},"metaSortKey":-1698036172330.9375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_e8318d133e5d4f97bf498b2fb5a1e12f","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698956556070,"created":1698598905312,"url":"http://localhost:9091/file","name":"File","description":"","method":"POST","body":{"mimeType":"multipart/form-data","params":[{"id":"pair_3895b02e772e4d33980e26d653318163","name":"file","value":"","description":"","type":"file","fileName":"/home/jony/Pictures/dl_image_verify.jpg"}]},"parameters":[{"id":"pair_78f99378da384a6b9eb273c12087681a","name":"","value":"","description":""}],"headers":[{"name":"Content-Type","value":"multipart/form-data"},{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"fa9b8bbc012a6f308dfe49af025d2ed84b9053235f9878998311504e0842c315879f9820f916619a9989c12734126fbd"}],"authentication":{},"metaSortKey":-1698036172230.9375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_1d6a1999c34b4061aafa0594a7c9eaa6","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698956558877,"created":1698601136769,"url":"http://localhost:9091/file","name":"File","description":"","method":"GET","body":{},"parameters":[{"id":"pair_1984d920fa954a138c9e11bf63e91daa","name":"id","value":"01HDYDB7NEXX73TMHHH7WWPW38","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"fa9b8bbc012a6f308dfe49af025d2ed84b9053235f9878998311504e0842c315879f9820f916619a9989c12734126fbd"}],"authentication":{},"metaSortKey":-1698036172205.9375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_7ea8855c2e2f4f8f8e28ff966f631d8c","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698969547321,"created":1698956536305,"url":"http://localhost:9091/file","name":"File","description":"","method":"DELETE","body":{},"parameters":[{"id":"pair_1984d920fa954a138c9e11bf63e91daa","name":"ulid","value":"01HE97BVMMXX73TMHHH7WWPW38","description":""}],"headers":[{"name":"User-Agent","value":"insomnia/8.3.0"},{"name":"Anon-User","value":"Carole"},{"name":"Anon-Token","value":"c0ac22129474f2cf46ed3ba382b18d0feafbbf5563fd6278efb90e680b858f89f7b60610ab7596c7858bc52541cce2e2"}],"authentication":{},"metaSortKey":-1698036172193.4375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_5ff6994c769a43028cc7caf706dbc203","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698956677671,"created":1698598963923,"url":"http://localhost:9091/files","name":"Files","description":"","method":"POST","body":{"mimeType":"multipart/form-data","params":[{"id":"pair_ed8e38ea22a842a8b1eeecc50f7ad24c","name":"files","value":"fake","description":"","type":"file"},{"id":"pair_dab28a8b72b748dfa607da060b19a0b1","name":"files","value":"","description":"","type":"file"}]},"parameters":[],"headers":[{"name":"Content-Type","value":"multipart/form-data"},{"name":"User-Agent","value":"insomnia/8.3.0"}],"authentication":{},"metaSortKey":-1698036172180.9375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"req_22972e4f08414d3eaa770eaf6770b2a3","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698956954144,"created":1698956700839,"url":"http://localhost:9091/files","name":"Files","description":"","method":"DELETE","body":{"mimeType":"multipart/form-data","params":[]},"parameters":[{"name":"ulids","value":"filename/ulid"},{"name":"ulids","value":"filename/ulid"},{"name":"ulids","value":"filename/ulid"},{"name":"ulids","value":"filename/ulid"},{"name":"ulids","value":"filename/ulid"}],"headers":[{"name":"Content-Type","value":"multipart/form-data"},{"name":"User-Agent","value":"insomnia/8.3.0"}],"authentication":{},"metaSortKey":-1698036172130.9375,"isPrivate":false,"settingStoreCookies":true,"settingSendCookies":true,"settingDisableRenderRequestBody":false,"settingEncodeUrl":true,"settingRebuildPath":true,"settingFollowRedirects":"global","_type":"request"},{"_id":"env_5ecd43d108504ce8b97efff0bed37dc7","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698007813917,"created":1698007813917,"name":"Base Environment","data":{},"dataPropertyOrder":null,"color":null,"isPrivate":false,"metaSortKey":1698007813917,"_type":"environment"},{"_id":"jar_069646bb15464c029654f5605b42e8e0","parentId":"wrk_b3a37033fefb4c40bbe7ba00b47964ce","modified":1698007813918,"created":1698007813918,"name":"Default Jar","cookies":[],"_type":"cookie_jar"}]} \ No newline at end of file diff --git a/internal/model/comments_test.go b/internal/model/_comments_test.go similarity index 97% rename from internal/model/comments_test.go rename to internal/model/_comments_test.go index 2659ef1..d17d448 100644 --- a/internal/model/comments_test.go +++ b/internal/model/_comments_test.go @@ -12,10 +12,10 @@ import ( func TestComments_Save_Get(t *testing.T) { // Create a new Comments object with some data cm := &Comment{ - + PostId: "1", Id: "2", - Text: "This is a comment", + Content: "This is a comment", } // Call the Save method diff --git a/internal/model/comments.go b/internal/model/comments.go index 1cfbbd6..3ebcb12 100644 --- a/internal/model/comments.go +++ b/internal/model/comments.go @@ -4,6 +4,7 @@ import ( "fmt" "github.com/SohelAhmedJoni/Awazz-Backend/internal/durable" + "github.com/syndtr/goleveldb/leveldb/util" "google.golang.org/protobuf/proto" ) @@ -26,6 +27,71 @@ func (cm *Comment) Get() error { return nil } +func GetFromByPost(cms *[]Comment, PostId string) error { + ldb, err := durable.LevelDBCreateDatabase("Database/", "NOSQL", "/") + if err != nil { + return nil + } + defer ldb.Close() + + iter := ldb.NewIterator(util.BytesPrefix([]byte(fmt.Sprintf("comment-%v", PostId))), nil) + + for iter.Next() { + var cm Comment + err = proto.Unmarshal(iter.Value(), &cm) + if err != nil { + return nil + } + *cms = append(*cms, cm) + } + + iter.Release() + err = iter.Error() + if err != nil { + return err + } + return nil +} + +func (cm *Comment) SavetoSQL(frag_num int64) error { + //mysql put + db, err := durable.CreateDatabase("Database/", "Common", fmt.Sprintf("Shard_%d.sqlite", frag_num)) + if err != nil { + return err + } + sql := `CREATE TABLE IF NOT EXISTS Comment ( + Id VARCHAR(250) PRIMARY KEY, + User VARCHAR(250) NOT NULL, + PostId VARCHAR(250) NOT NULL, + UserId VARCHAR(250) NOT NULL, + RepliedTo VARCHAR(250), + Content TEXT, + CreatedDate TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + UpdatedDate TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + Likes INTEGER DEFAULT 0, + Replies INTEGER DEFAULT 0, + IsDeleted BOOLEAN DEFAULT 0, + IsUpdated BOOLEAN DEFAULT 0 +)` + defer db.Close() + _, err = db.Exec(sql) + if err != nil { + return err + } + statement, err := db.Prepare("INSERT INTO Comment (Id,User,PostId,UserId,RepliedTo,Content,CreatedDate,UpdatedDate,Likes,Replies,IsDeleted,IsUpdated) VALUES (?,?,?,?,?,?,?,?,?,?,?,?)") + + if err != nil { + panic(err) + } + cm.IsDeleted = false + cm.IsUpdated = false + _, err = statement.Exec(cm.Id, cm.User, cm.PostId, cm.UserId, cm.RepliedTo, cm.Content, cm.CreatedDate, cm.UpdatedDate, cm.Likes, len(cm.Replies), cm.IsDeleted, cm.IsUpdated) + if err != nil { + panic(err) + } + return nil +} + func (cm *Comment) Save() error { //leveldb put db, err := durable.LevelDBCreateDatabase("Database/", "NOSQL", "/") diff --git a/internal/model/comments.pb.go b/internal/model/comments.pb.go index 981ccab..9c5b3c7 100644 --- a/internal/model/comments.pb.go +++ b/internal/model/comments.pb.go @@ -40,7 +40,7 @@ type Comment struct { PostId string `protobuf:"bytes,3,opt,name=post_id,json=postId,proto3" json:"post_id,omitempty"` UserId string `protobuf:"bytes,4,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` RepliedTo string `protobuf:"bytes,5,opt,name=replied_to,json=repliedTo,proto3" json:"replied_to,omitempty"` - Text string `protobuf:"bytes,6,opt,name=text,proto3" json:"text,omitempty"` + Content string `protobuf:"bytes,6,opt,name=content,proto3" json:"content,omitempty"` CreatedDate int64 `protobuf:"varint,7,opt,name=created_date,json=createdDate,proto3" json:"created_date,omitempty"` UpdatedDate int64 `protobuf:"varint,8,opt,name=updated_date,json=updatedDate,proto3" json:"updated_date,omitempty"` Likes int64 `protobuf:"varint,9,opt,name=likes,proto3" json:"likes,omitempty"` @@ -116,9 +116,9 @@ func (x *Comment) GetRepliedTo() string { return "" } -func (x *Comment) GetText() string { +func (x *Comment) GetContent() string { if x != nil { - return x.Text + return x.Content } return "" } @@ -216,7 +216,7 @@ var File_comments_proto protoreflect.FileDescriptor var file_comments_proto_rawDesc = []byte{ 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x22, 0xc6, 0x02, 0x0a, 0x07, 0x43, 0x6f, 0x6d, 0x6d, + 0x12, 0x05, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x22, 0xcc, 0x02, 0x0a, 0x07, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x75, 0x73, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x75, 0x73, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x70, 0x6f, 0x73, 0x74, 0x5f, @@ -224,24 +224,25 @@ var file_comments_proto_rawDesc = []byte{ 0x12, 0x17, 0x0a, 0x07, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, - 0x65, 0x70, 0x6c, 0x69, 0x65, 0x64, 0x54, 0x6f, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x65, 0x78, 0x74, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x65, 0x78, 0x74, 0x12, 0x21, 0x0a, 0x0c, - 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x03, 0x52, 0x0b, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, 0x12, - 0x21, 0x0a, 0x0c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x44, 0x61, - 0x74, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6b, 0x65, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x03, 0x52, 0x05, 0x6c, 0x69, 0x6b, 0x65, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x72, 0x65, 0x70, 0x6c, - 0x69, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x72, 0x65, 0x70, 0x6c, 0x69, - 0x65, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, - 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, - 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, - 0x22, 0x36, 0x0a, 0x08, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x2a, 0x0a, 0x08, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, - 0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x08, - 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x42, 0x09, 0x5a, 0x07, 0x2e, 0x3b, 0x6d, 0x6f, - 0x64, 0x65, 0x6c, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x65, 0x70, 0x6c, 0x69, 0x65, 0x64, 0x54, 0x6f, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, + 0x6e, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x64, 0x61, + 0x74, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x64, 0x44, 0x61, 0x74, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, + 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x0b, 0x75, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x64, 0x44, 0x61, 0x74, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6b, 0x65, + 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x6c, 0x69, 0x6b, 0x65, 0x73, 0x12, 0x18, + 0x0a, 0x07, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x09, 0x52, + 0x07, 0x72, 0x65, 0x70, 0x6c, 0x69, 0x65, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x64, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, + 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x75, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x64, 0x22, 0x36, 0x0a, 0x08, 0x43, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, + 0x74, 0x73, 0x12, 0x2a, 0x0a, 0x08, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0e, 0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x2e, 0x43, 0x6f, 0x6d, + 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x08, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x42, 0x09, + 0x5a, 0x07, 0x2e, 0x3b, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( diff --git a/internal/model/comments.proto b/internal/model/comments.proto index 69d8d64..c406e21 100644 --- a/internal/model/comments.proto +++ b/internal/model/comments.proto @@ -19,7 +19,7 @@ message Comment{ string post_id = 3; string user_id = 4; string replied_to = 5; - string text = 6 ; + string content = 6 ; int64 created_date = 7 ; int64 updated_date = 8 ; int64 likes = 9; diff --git a/pkg/utils.go b/pkg/utils.go index 38471d2..fe4d6d6 100644 --- a/pkg/utils.go +++ b/pkg/utils.go @@ -80,3 +80,17 @@ func StringToShard(s string) int64 { } return n } + +func StringFullToShard(s string) int64 { + var n int64 + if s == "" { + // UserId is missing, return 401 + n = 0 + } else { + for _, r := range []rune(s) { + n += int64(r) + } + n = n % 6 + } + return n +}