Live video on the AT Protocol

add 'createdBy' to place.stream.key

Natalie B 508f20d7 85ef3d6e

+72 -3
+2 -2
js/app/src/router.tsx
··· 140 140 Multi: "multi/:config", 141 141 Support: "support", 142 142 Settings: "settings", 143 - KeyManagement: "settings/key-management", 143 + KeyManagement: "key-management", 144 144 GoLive: "golive", 145 145 LiveDashboard: "live", 146 146 Login: "login", ··· 442 442 /> 443 443 444 444 <Drawer.Screen 445 - name="Key Manager" 445 + name="KeyManagement" 446 446 component={KeyManager} 447 447 options={{ 448 448 drawerLabel: () => <Text>Key Manager</Text>,
+5
js/docs/src/content/docs/lex-reference/place-stream-key.md
··· 23 23 | ------------ | -------- | ----- | ---------------------------------------------------- | --------------------------------- | 24 24 | `signingKey` | `string` | ✅ | The did:key signing key for the stream. | Min Length: 57<br/>Max Length: 57 | 25 25 | `createdAt` | `string` | ✅ | Client-declared timestamp when this key was created. | Format: `datetime` | 26 + | `createdBy` | `string` | ❌ | The name of the client that created this key. | | 26 27 27 28 --- 28 29 ··· 51 52 "type": "string", 52 53 "format": "datetime", 53 54 "description": "Client-declared timestamp when this key was created." 55 + }, 56 + "createdBy": { 57 + "type": "string", 58 + "description": "The name of the client that created this key." 54 59 } 55 60 } 56 61 }
+4
lexicons/place/stream/key.json
··· 20 20 "type": "string", 21 21 "format": "datetime", 22 22 "description": "Client-declared timestamp when this key was created." 23 + }, 24 + "createdBy": { 25 + "type": "string", 26 + "description": "The name of the client that created this key." 23 27 } 24 28 } 25 29 }
+59 -1
pkg/streamplace/cbor_gen.go
··· 28 28 } 29 29 30 30 cw := cbg.NewCborWriter(w) 31 + fieldCount := 4 31 32 32 - if _, err := cw.Write([]byte{163}); err != nil { 33 + if t.CreatedBy == nil { 34 + fieldCount-- 35 + } 36 + 37 + if _, err := cw.Write(cbg.CborEncodeMajorType(cbg.MajMap, uint64(fieldCount))); err != nil { 33 38 return err 34 39 } 35 40 ··· 75 80 return err 76 81 } 77 82 83 + // t.CreatedBy (string) (string) 84 + if t.CreatedBy != nil { 85 + 86 + if len("createdBy") > 1000000 { 87 + return xerrors.Errorf("Value in field \"createdBy\" was too long") 88 + } 89 + 90 + if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len("createdBy"))); err != nil { 91 + return err 92 + } 93 + if _, err := cw.WriteString(string("createdBy")); err != nil { 94 + return err 95 + } 96 + 97 + if t.CreatedBy == nil { 98 + if _, err := cw.Write(cbg.CborNull); err != nil { 99 + return err 100 + } 101 + } else { 102 + if len(*t.CreatedBy) > 1000000 { 103 + return xerrors.Errorf("Value in field t.CreatedBy was too long") 104 + } 105 + 106 + if err := cw.WriteMajorTypeHeader(cbg.MajTextString, uint64(len(*t.CreatedBy))); err != nil { 107 + return err 108 + } 109 + if _, err := cw.WriteString(string(*t.CreatedBy)); err != nil { 110 + return err 111 + } 112 + } 113 + } 114 + 78 115 // t.SigningKey (string) (string) 79 116 if len("signingKey") > 1000000 { 80 117 return xerrors.Errorf("Value in field \"signingKey\" was too long") ··· 162 199 } 163 200 164 201 t.CreatedAt = string(sval) 202 + } 203 + // t.CreatedBy (string) (string) 204 + case "createdBy": 205 + 206 + { 207 + b, err := cr.ReadByte() 208 + if err != nil { 209 + return err 210 + } 211 + if b != cbg.CborNull[0] { 212 + if err := cr.UnreadByte(); err != nil { 213 + return err 214 + } 215 + 216 + sval, err := cbg.ReadStringWithMax(cr, 1000000) 217 + if err != nil { 218 + return err 219 + } 220 + 221 + t.CreatedBy = (*string)(&sval) 222 + } 165 223 } 166 224 // t.SigningKey (string) (string) 167 225 case "signingKey":
+2
pkg/streamplace/streamkey.go
··· 16 16 LexiconTypeID string `json:"$type,const=place.stream.key" cborgen:"$type,const=place.stream.key"` 17 17 // createdAt: Client-declared timestamp when this key was created. 18 18 CreatedAt string `json:"createdAt" cborgen:"createdAt"` 19 + // createdBy: The name of the client that created this key. 20 + CreatedBy *string `json:"createdBy,omitempty" cborgen:"createdBy,omitempty"` 19 21 // signingKey: The did:key signing key for the stream. 20 22 SigningKey string `json:"signingKey" cborgen:"signingKey"` 21 23 }