+95
lexicons/blue.microcosm/links/getBacklinks.json
+95
lexicons/blue.microcosm/links/getBacklinks.json
···
1
+
{
2
+
"lexicon": 1,
3
+
"id": "blue.microcosm.links.getBacklinks",
4
+
"defs": {
5
+
"main": {
6
+
"type": "query",
7
+
"description": "a list of records linking to any record, identity, or uri",
8
+
"parameters": {
9
+
"type": "params",
10
+
"required": [
11
+
"subject",
12
+
"source"
13
+
],
14
+
"properties": {
15
+
"subject": {
16
+
"type": "string",
17
+
"format": "uri",
18
+
"description": "the target being linked to (at-uri, did, or uri)"
19
+
},
20
+
"source": {
21
+
"type": "string",
22
+
"description": "collection and path specification (e.g., 'app.bsky.feed.like:subject.uri')"
23
+
},
24
+
"did": {
25
+
"type": "array",
26
+
"description": "filter links to those from specific users",
27
+
"items": {
28
+
"type": "string",
29
+
"format": "did"
30
+
}
31
+
},
32
+
"limit": {
33
+
"type": "integer",
34
+
"minimum": 1,
35
+
"maximum": 100,
36
+
"default": 16,
37
+
"description": "number of results to return"
38
+
}
39
+
}
40
+
},
41
+
"output": {
42
+
"encoding": "application/json",
43
+
"schema": {
44
+
"type": "object",
45
+
"required": [
46
+
"total",
47
+
"records"
48
+
],
49
+
"properties": {
50
+
"total": {
51
+
"type": "integer",
52
+
"description": "total number of matching links"
53
+
},
54
+
"records": {
55
+
"type": "array",
56
+
"items": {
57
+
"type": "ref",
58
+
"ref": "#linkRecord"
59
+
}
60
+
},
61
+
"cursor": {
62
+
"type": "string",
63
+
"description": "pagination cursor"
64
+
}
65
+
}
66
+
}
67
+
}
68
+
},
69
+
"linkRecord": {
70
+
"type": "object",
71
+
"required": [
72
+
"did",
73
+
"collection",
74
+
"rkey"
75
+
],
76
+
"properties": {
77
+
"did": {
78
+
"type": "string",
79
+
"format": "did",
80
+
"description": "the DID of the linking record's repository"
81
+
},
82
+
"collection": {
83
+
"type": "string",
84
+
"format": "nsid",
85
+
"description": "the collection of the linking record"
86
+
},
87
+
"rkey": {
88
+
"type": "string",
89
+
"format": "record-key",
90
+
"description": "the record key of the linking record"
91
+
}
92
+
}
93
+
}
94
+
}
95
+
}
+99
lexicons/blue.microcosm/links/getManyToManyCounts.json
+99
lexicons/blue.microcosm/links/getManyToManyCounts.json
···
1
+
{
2
+
"lexicon": 1,
3
+
"id": "blue.microcosm.links.getManyToManyCounts",
4
+
"defs": {
5
+
"main": {
6
+
"type": "query",
7
+
"description": "count many-to-many relationships with secondary link paths",
8
+
"parameters": {
9
+
"type": "params",
10
+
"required": [
11
+
"subject",
12
+
"source",
13
+
"pathToOther"
14
+
],
15
+
"properties": {
16
+
"subject": {
17
+
"type": "string",
18
+
"format": "uri",
19
+
"description": "the primary target being linked to (at-uri, did, or uri)"
20
+
},
21
+
"source": {
22
+
"type": "string",
23
+
"description": "collection and path specification for the primary link"
24
+
},
25
+
"pathToOther": {
26
+
"type": "string",
27
+
"description": "path to the secondary link in the many-to-many record (e.g., 'otherThing.uri')"
28
+
},
29
+
"did": {
30
+
"type": "array",
31
+
"description": "filter links to those from specific users",
32
+
"items": {
33
+
"type": "string",
34
+
"format": "did"
35
+
}
36
+
},
37
+
"otherSubject": {
38
+
"type": "array",
39
+
"description": "filter secondary links to specific subjects",
40
+
"items": {
41
+
"type": "string"
42
+
}
43
+
},
44
+
"limit": {
45
+
"type": "integer",
46
+
"minimum": 1,
47
+
"maximum": 100,
48
+
"default": 16,
49
+
"description": "number of results to return"
50
+
}
51
+
}
52
+
},
53
+
"output": {
54
+
"encoding": "application/json",
55
+
"schema": {
56
+
"type": "object",
57
+
"required": [
58
+
"counts_by_other_subject"
59
+
],
60
+
"properties": {
61
+
"counts_by_other_subject": {
62
+
"type": "array",
63
+
"items": {
64
+
"type": "ref",
65
+
"ref": "#countBySubject"
66
+
}
67
+
},
68
+
"cursor": {
69
+
"type": "string",
70
+
"description": "pagination cursor"
71
+
}
72
+
}
73
+
}
74
+
}
75
+
},
76
+
"countBySubject": {
77
+
"type": "object",
78
+
"required": [
79
+
"subject",
80
+
"total",
81
+
"distinct"
82
+
],
83
+
"properties": {
84
+
"subject": {
85
+
"type": "string",
86
+
"description": "the secondary subject being counted"
87
+
},
88
+
"total": {
89
+
"type": "integer",
90
+
"description": "total number of links to this subject"
91
+
},
92
+
"distinct": {
93
+
"type": "integer",
94
+
"description": "number of distinct DIDs linking to this subject"
95
+
}
96
+
}
97
+
}
98
+
}
99
+
}
+56
lexicons/com.bad-example/identity/resolveMiniDoc.json
+56
lexicons/com.bad-example/identity/resolveMiniDoc.json
···
1
+
{
2
+
"lexicon": 1,
3
+
"id": "com.bad-example.identity.resolveMiniDoc",
4
+
"defs": {
5
+
"main": {
6
+
"type": "query",
7
+
"description": "like com.atproto.identity.resolveIdentity but instead of the full didDoc it returns an atproto-relevant subset",
8
+
"parameters": {
9
+
"type": "params",
10
+
"required": [
11
+
"identifier"
12
+
],
13
+
"properties": {
14
+
"identifier": {
15
+
"type": "string",
16
+
"format": "at-identifier",
17
+
"description": "handle or DID to resolve"
18
+
}
19
+
}
20
+
},
21
+
"output": {
22
+
"encoding": "application/json",
23
+
"schema": {
24
+
"type": "object",
25
+
"required": [
26
+
"did",
27
+
"handle",
28
+
"pds",
29
+
"signing_key"
30
+
],
31
+
"properties": {
32
+
"did": {
33
+
"type": "string",
34
+
"format": "did",
35
+
"description": "DID, bi-directionally verified if a handle was provided in the query"
36
+
},
37
+
"handle": {
38
+
"type": "string",
39
+
"format": "handle",
40
+
"description": "the validated handle of the account or 'handle.invalid' if the handle did not bi-directionally match the DID document"
41
+
},
42
+
"pds": {
43
+
"type": "string",
44
+
"format": "uri",
45
+
"description": "the identity's PDS URL"
46
+
},
47
+
"signing_key": {
48
+
"type": "string",
49
+
"description": "the atproto signing key publicKeyMultibase"
50
+
}
51
+
}
52
+
}
53
+
}
54
+
}
55
+
}
56
+
}
+54
lexicons/com.bad-example/repo/getUriRecord.json
+54
lexicons/com.bad-example/repo/getUriRecord.json
···
1
+
{
2
+
"lexicon": 1,
3
+
"id": "com.bad-example.repo.getUriRecord",
4
+
"defs": {
5
+
"main": {
6
+
"type": "query",
7
+
"description": "ergonomic complement to com.atproto.repo.getRecord which accepts an at-uri instead of individual repo/collection/rkey params",
8
+
"parameters": {
9
+
"type": "params",
10
+
"required": [
11
+
"at_uri"
12
+
],
13
+
"properties": {
14
+
"at_uri": {
15
+
"type": "string",
16
+
"format": "at-uri",
17
+
"description": "the at-uri of the record (identifier can be a DID or handle)"
18
+
},
19
+
"cid": {
20
+
"type": "string",
21
+
"format": "cid",
22
+
"description": "optional CID of the version of the record. if not specified, return the most recent version. if specified and a newer version exists, returns 404."
23
+
}
24
+
}
25
+
},
26
+
"output": {
27
+
"encoding": "application/json",
28
+
"schema": {
29
+
"type": "object",
30
+
"required": [
31
+
"uri",
32
+
"value"
33
+
],
34
+
"properties": {
35
+
"uri": {
36
+
"type": "string",
37
+
"format": "at-uri",
38
+
"description": "at-uri for this record"
39
+
},
40
+
"cid": {
41
+
"type": "string",
42
+
"format": "cid",
43
+
"description": "CID for this exact version of the record"
44
+
},
45
+
"value": {
46
+
"type": "unknown",
47
+
"description": "the record itself"
48
+
}
49
+
}
50
+
}
51
+
}
52
+
}
53
+
}
54
+
}