summaryrefslogtreecommitdiff
path: root/desk/sur/nostrill/comms.hoon
blob: 42ea1ba6beed58390cbb63e95866b23a8029ff57 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
/-  sur=nostrill, nsur=nostr, feed=trill-feed, post=trill-post
|%
+$  poke
  $%  [%req req]
      [%res res]
      [%dbug *]
  ==
+$  emgagement
  $%  [%reply host=@p id=@da]
      [%del-reply host=@p id=@da]
      [%reaction host=@p id=@da reaction=@t]
  ==
+$  req
  $%  [%feed ~]
      [%thread id=@da]
  ==
+$  res
  $%  [%ok p=res-data]
      [%ng msg=@t]
  ==
+$  res-data
  $%  [%feed =fc:feed profile=(unit user-meta:nsur)]
      [%thread p=full-node:post]
  ==
:: TODO there's some overlap between what we send to the UI and we send to our followers
:: but it's not exactly the same
+$  fact
  $%  [%post post-fact]
      [%prof prof-fact]
      [%init res]
  ==
+$  post-fact
  $%  [%add p=post:post]
      [%del id=@da]
      [%changes p=post:post]
  ==
+$  prof-fact
  $%  [%prof =user-meta:nsur]
      [%keys pub=@ux]
  ==
--