demo CLI tool for grain.social

add relevant lexicons as JSON files

+402
+193
lexicons/com.atproto/label.defs
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "label": { 5 + "description": "Metadata tag on an atproto resource (eg, repo or record).", 6 + "properties": { 7 + "cid": { 8 + "description": "Optionally, CID specifying the specific version of 'uri' resource this label applies to.", 9 + "format": "cid", 10 + "type": "string" 11 + }, 12 + "cts": { 13 + "description": "Timestamp when this label was created.", 14 + "format": "datetime", 15 + "type": "string" 16 + }, 17 + "exp": { 18 + "description": "Timestamp at which this label expires (no longer applies).", 19 + "format": "datetime", 20 + "type": "string" 21 + }, 22 + "neg": { 23 + "description": "If true, this is a negation label, overwriting a previous label.", 24 + "type": "boolean" 25 + }, 26 + "sig": { 27 + "description": "Signature of dag-cbor encoded label.", 28 + "type": "bytes" 29 + }, 30 + "src": { 31 + "description": "DID of the actor who created this label.", 32 + "format": "did", 33 + "type": "string" 34 + }, 35 + "uri": { 36 + "description": "AT URI of the record, repository (account), or other resource that this label applies to.", 37 + "format": "uri", 38 + "type": "string" 39 + }, 40 + "val": { 41 + "description": "The short string name of the value or type of this label.", 42 + "maxLength": 128, 43 + "type": "string" 44 + }, 45 + "ver": { 46 + "description": "The AT Protocol version of the label object.", 47 + "type": "integer" 48 + } 49 + }, 50 + "required": [ 51 + "src", 52 + "uri", 53 + "val", 54 + "cts" 55 + ], 56 + "type": "object" 57 + }, 58 + "labelValue": { 59 + "knownValues": [ 60 + "!hide", 61 + "!no-promote", 62 + "!warn", 63 + "!no-unauthenticated", 64 + "dmca-violation", 65 + "doxxing", 66 + "porn", 67 + "sexual", 68 + "nudity", 69 + "nsfl", 70 + "gore" 71 + ], 72 + "type": "string" 73 + }, 74 + "labelValueDefinition": { 75 + "description": "Declares a label value and its expected interpretations and behaviors.", 76 + "properties": { 77 + "adultOnly": { 78 + "description": "Does the user need to have adult content enabled in order to configure this label?", 79 + "type": "boolean" 80 + }, 81 + "blurs": { 82 + "description": "What should this label hide in the UI, if applied? 'content' hides all of the target; 'media' hides the images/video/audio; 'none' hides nothing.", 83 + "knownValues": [ 84 + "content", 85 + "media", 86 + "none" 87 + ], 88 + "type": "string" 89 + }, 90 + "defaultSetting": { 91 + "default": "warn", 92 + "description": "The default setting for this label.", 93 + "knownValues": [ 94 + "ignore", 95 + "warn", 96 + "hide" 97 + ], 98 + "type": "string" 99 + }, 100 + "identifier": { 101 + "description": "The value of the label being defined. Must only include lowercase ascii and the '-' character ([a-z-]+).", 102 + "maxGraphemes": 100, 103 + "maxLength": 100, 104 + "type": "string" 105 + }, 106 + "locales": { 107 + "items": { 108 + "ref": "#labelValueDefinitionStrings", 109 + "type": "ref" 110 + }, 111 + "type": "array" 112 + }, 113 + "severity": { 114 + "description": "How should a client visually convey this label? 'inform' means neutral and informational; 'alert' means negative and warning; 'none' means show nothing.", 115 + "knownValues": [ 116 + "inform", 117 + "alert", 118 + "none" 119 + ], 120 + "type": "string" 121 + } 122 + }, 123 + "required": [ 124 + "identifier", 125 + "severity", 126 + "blurs", 127 + "locales" 128 + ], 129 + "type": "object" 130 + }, 131 + "labelValueDefinitionStrings": { 132 + "description": "Strings which describe the label in the UI, localized into a specific language.", 133 + "properties": { 134 + "description": { 135 + "description": "A longer description of what the label means and why it might be applied.", 136 + "maxGraphemes": 10000, 137 + "maxLength": 100000, 138 + "type": "string" 139 + }, 140 + "lang": { 141 + "description": "The code of the language these strings are written in.", 142 + "format": "language", 143 + "type": "string" 144 + }, 145 + "name": { 146 + "description": "A short human-readable name for the label.", 147 + "maxGraphemes": 64, 148 + "maxLength": 640, 149 + "type": "string" 150 + } 151 + }, 152 + "required": [ 153 + "lang", 154 + "name", 155 + "description" 156 + ], 157 + "type": "object" 158 + }, 159 + "selfLabel": { 160 + "description": "Metadata tag on an atproto record, published by the author within the record. Note that schemas should use #selfLabels, not #selfLabel.", 161 + "properties": { 162 + "val": { 163 + "description": "The short string name of the value or type of this label.", 164 + "maxLength": 128, 165 + "type": "string" 166 + } 167 + }, 168 + "required": [ 169 + "val" 170 + ], 171 + "type": "object" 172 + }, 173 + "selfLabels": { 174 + "description": "Metadata tags on an atproto record, published by the author within the record.", 175 + "properties": { 176 + "values": { 177 + "items": { 178 + "ref": "#selfLabel", 179 + "type": "ref" 180 + }, 181 + "maxLength": 10, 182 + "type": "array" 183 + } 184 + }, 185 + "required": [ 186 + "values" 187 + ], 188 + "type": "object" 189 + } 190 + }, 191 + "id": "com.atproto.label.defs", 192 + "lexicon": 1 193 + }
+41
lexicons/social.grain/actor.profile.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "main": { 5 + "description": "A declaration of a basic account profile.", 6 + "key": "literal:self", 7 + "record": { 8 + "properties": { 9 + "avatar": { 10 + "accept": [ 11 + "image/png", 12 + "image/jpeg" 13 + ], 14 + "description": "Small image to be displayed next to posts from account. AKA, 'profile picture'", 15 + "maxSize": 1000000, 16 + "type": "blob" 17 + }, 18 + "createdAt": { 19 + "format": "datetime", 20 + "type": "string" 21 + }, 22 + "description": { 23 + "description": "Free-form profile description text.", 24 + "maxGraphemes": 256, 25 + "maxLength": 2560, 26 + "type": "string" 27 + }, 28 + "displayName": { 29 + "maxGraphemes": 64, 30 + "maxLength": 640, 31 + "type": "string" 32 + } 33 + }, 34 + "type": "object" 35 + }, 36 + "type": "record" 37 + } 38 + }, 39 + "id": "social.grain.actor.profile", 40 + "lexicon": 1 41 + }
+25
lexicons/social.grain/defs.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "aspectRatio": { 5 + "description": "width:height represents an aspect ratio. It may be approximate, and may not correspond to absolute dimensions in any given unit.", 6 + "properties": { 7 + "height": { 8 + "minimum": 1, 9 + "type": "integer" 10 + }, 11 + "width": { 12 + "minimum": 1, 13 + "type": "integer" 14 + } 15 + }, 16 + "required": [ 17 + "width", 18 + "height" 19 + ], 20 + "type": "object" 21 + } 22 + }, 23 + "id": "social.grain.defs", 24 + "lexicon": 1 25 + }
+28
lexicons/social.grain/favorite.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "main": { 5 + "key": "tid", 6 + "record": { 7 + "properties": { 8 + "createdAt": { 9 + "format": "datetime", 10 + "type": "string" 11 + }, 12 + "subject": { 13 + "format": "at-uri", 14 + "type": "string" 15 + } 16 + }, 17 + "required": [ 18 + "createdAt", 19 + "subject" 20 + ], 21 + "type": "object" 22 + }, 23 + "type": "record" 24 + } 25 + }, 26 + "id": "social.grain.favorite", 27 + "lexicon": 1 28 + }
+37
lexicons/social.grain/gallery.item.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "main": { 5 + "key": "tid", 6 + "record": { 7 + "properties": { 8 + "createdAt": { 9 + "format": "datetime", 10 + "type": "string" 11 + }, 12 + "gallery": { 13 + "format": "at-uri", 14 + "type": "string" 15 + }, 16 + "item": { 17 + "format": "at-uri", 18 + "type": "string" 19 + }, 20 + "position": { 21 + "default": 0, 22 + "type": "integer" 23 + } 24 + }, 25 + "required": [ 26 + "createdAt", 27 + "gallery", 28 + "item" 29 + ], 30 + "type": "object" 31 + }, 32 + "type": "record" 33 + } 34 + }, 35 + "id": "social.grain.gallery.item", 36 + "lexicon": 1 37 + }
+39
lexicons/social.grain/gallery.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "main": { 5 + "key": "tid", 6 + "record": { 7 + "properties": { 8 + "createdAt": { 9 + "format": "datetime", 10 + "type": "string" 11 + }, 12 + "description": { 13 + "maxLength": 1000, 14 + "type": "string" 15 + }, 16 + "labels": { 17 + "description": "Self-label values for this post. Effectively content warnings.", 18 + "refs": [ 19 + "com.atproto.label.defs#selfLabels" 20 + ], 21 + "type": "union" 22 + }, 23 + "title": { 24 + "maxLength": 100, 25 + "type": "string" 26 + } 27 + }, 28 + "required": [ 29 + "title", 30 + "createdAt" 31 + ], 32 + "type": "object" 33 + }, 34 + "type": "record" 35 + } 36 + }, 37 + "id": "social.grain.gallery", 38 + "lexicon": 1 39 + }
+39
lexicons/social.grain/photo.json
··· 1 + { 2 + "$type": "com.atproto.lexicon.schema", 3 + "defs": { 4 + "main": { 5 + "key": "tid", 6 + "record": { 7 + "properties": { 8 + "alt": { 9 + "description": "Alt text description of the image, for accessibility.", 10 + "type": "string" 11 + }, 12 + "aspectRatio": { 13 + "ref": "social.grain.defs#aspectRatio", 14 + "type": "ref" 15 + }, 16 + "createdAt": { 17 + "format": "datetime", 18 + "type": "string" 19 + }, 20 + "photo": { 21 + "accept": [ 22 + "image/*" 23 + ], 24 + "maxSize": 1000000, 25 + "type": "blob" 26 + } 27 + }, 28 + "required": [ 29 + "photo", 30 + "alt" 31 + ], 32 + "type": "object" 33 + }, 34 + "type": "record" 35 + } 36 + }, 37 + "id": "social.grain.photo", 38 + "lexicon": 1 39 + }