backend for xcvr appview
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

add message timestamps to lexicons and migrations

+19 -1
+9 -1
lexicons/org/xcvr/lrc/defs.json
··· 4 4 "defs": { 5 5 "messageView": { 6 6 "type": "object", 7 - "required": ["uri", "author", "body"], 7 + "required": ["uri", "author", "body", "startedAt", "postedAt"], 8 8 "properties": { 9 9 "uri": { 10 10 "type": "string", ··· 25 25 "type": "integer", 26 26 "minimum": 0, 27 27 "maximum": 16777215 28 + }, 29 + "startedAt": { 30 + "type": "string", 31 + "format": "datetime" 32 + }, 33 + "postedAt": { 34 + "type": "string", 35 + "format": "datetime" 28 36 } 29 37 } 30 38 }
+4
lexicons/org/xcvr/lrc/message.json
··· 25 25 "type": "integer", 26 26 "minimum": 0, 27 27 "maximum": 16777215 28 + }, 29 + "postedAt": { 30 + "type": "string", 31 + "format": "datetime" 28 32 } 29 33 } 30 34 }
+4
lexicons/org/xcvr/lrc/signet.json
··· 22 22 "author": { 23 23 "type": "string", 24 24 "format": "did" 25 + }, 26 + "startedAt": { 27 + "type": "string", 28 + "format": "datetime" 25 29 } 26 30 } 27 31 }
+2
migrations/001_init.up.sql
··· 35 35 FOREIGN KEY (channel_uri) REFERENCES channels(uri) ON DELETE CASCADE, 36 36 message_id INTEGER CHECK (message_id BETWEEN 0 AND 4294967295), 37 37 cid TEXT NOT NULL, 38 + started_at TIMESTAMPTZ NOT NULL DEFAULT now(), 38 39 indexed_at TIMESTAMPTZ NOT NULL DEFAULT now() 39 40 ); 40 41 ··· 49 50 nick TEXT NOT NULL DEFAULT 'wanderer', 50 51 color INTEGER CHECK (color BETWEEN 0 AND 16777215), 51 52 cid TEXT NOT NULL, 53 + posted_at TIMESTAMPTZ NOT NULL DEFAULT now(), 52 54 indexed_at TIMESTAMPTZ NOT NULL DEFAULT now() 53 55 ); 54 56