social bookmarking for atproto

[lexicon] Introduce "social.clippr.feed.getTagClips" and etc.

hexmani.ac d313d934 47dc8944

verified
+150 -19
+1 -1
lexdocs/social/clippr/actor/defs.json
··· 31 31 "type": "string", 32 32 "maxGraphemes": 500, 33 33 "maxLength": 5000, 34 - "description": "The biography associated to the profile" 34 + "description": "A description (or 'bio') associated to the profile" 35 35 }, 36 36 "avatar": { 37 37 "type": "string",
+1 -1
lexdocs/social/clippr/actor/getPreferences.json
··· 4 4 "defs": { 5 5 "main": { 6 6 "type": "query", 7 - "description": "Get the private user preferences associated to the account.", 7 + "description": "Get the private user preferences associated to the requesting account.", 8 8 "parameters": { 9 9 "type": "params", 10 10 "properties": {}
+1 -1
lexdocs/social/clippr/actor/getProfile.json
··· 23 23 "schema": { 24 24 "type": "ref", 25 25 "ref": "social.clippr.actor.defs#profileView", 26 - "description": "A reference to the profile view of the actor" 26 + "description": "A ref to the hydrated profile view of the actor" 27 27 } 28 28 } 29 29 }
+1 -1
lexdocs/social/clippr/actor/putPreferences.json
··· 4 4 "defs": { 5 5 "main": { 6 6 "type": "procedure", 7 - "description": "Set the private preferences attached to the account.", 7 + "description": "Set the private user preferences associated to the requesting account.", 8 8 "input": { 9 9 "encoding": "application/json", 10 10 "schema": {
+5 -1
lexdocs/social/clippr/actor/searchProfiles.json
··· 7 7 "description": "Find profiles matching search criteria. Does not require auth.", 8 8 "parameters": { 9 9 "type": "params", 10 + "required": [ 11 + "q" 12 + ], 10 13 "properties": { 11 14 "q": { 12 15 "type": "string", ··· 42 45 "items": { 43 46 "type": "ref", 44 47 "ref": "social.clippr.actor.defs#profileView" 45 - } 48 + }, 49 + "description": "An array of hydrated profile views" 46 50 } 47 51 } 48 52 }
+2 -2
lexdocs/social/clippr/feed/defs.json
··· 26 26 "author": { 27 27 "type": "ref", 28 28 "ref": "social.clippr.actor.defs#profileView", 29 - "description": "A reference to the actor's profile" 29 + "description": "A ref to the actor's profile" 30 30 }, 31 31 "record": { 32 32 "type": "unknown", ··· 63 63 "author": { 64 64 "type": "ref", 65 65 "ref": "social.clippr.actor.defs#profileView", 66 - "description": "A reference to the actor's profile" 66 + "description": "A ref to the actor's profile" 67 67 }, 68 68 "record": { 69 69 "type": "unknown",
+1 -1
lexdocs/social/clippr/feed/getClips.json
··· 4 4 "defs": { 5 5 "main": { 6 6 "type": "query", 7 - "description": "Get a list of clips. Does not require auth.", 7 + "description": "Get a list of hydrated clips. Does not require auth.", 8 8 "parameters": { 9 9 "type": "params", 10 10 "required": [
+6 -4
lexdocs/social/clippr/feed/getProfileClips.json
··· 4 4 "defs": { 5 5 "main": { 6 6 "type": "query", 7 - "description": "Get a view of a profile's reverse-chronological clips feed. Does not require auth.", 7 + "description": "Get a view of a profile's reverse-chronological feed containing their clips. Does not require auth.", 8 8 "parameters": { 9 9 "type": "params", 10 10 "required": [ ··· 35 35 "untagged_clips" 36 36 ], 37 37 "default": "all_clips", 38 - "description": "What types to include in response" 38 + "description": "What types of clips to include in response" 39 39 } 40 40 } 41 41 }, ··· 48 48 ], 49 49 "properties": { 50 50 "cursor": { 51 - "type": "string" 51 + "type": "string", 52 + "description": "A parameter to paginate results" 52 53 }, 53 54 "feed": { 54 55 "type": "array", 55 56 "items": { 56 57 "type": "ref", 57 58 "ref": "social.clippr.feed.defs#clipView" 58 - } 59 + }, 60 + "description": "An array of hydrated clip views" 59 61 } 60 62 } 61 63 }
+5 -3
lexdocs/social/clippr/feed/getProfileTags.json
··· 4 4 "defs": { 5 5 "main": { 6 6 "type": "query", 7 - "description": "Get a view of a profile's reverse-chronological clips feed. Does not require auth.", 7 + "description": "Get a view of a profile's reverse-chronological feed containing their tags. Does not require auth.", 8 8 "parameters": { 9 9 "type": "params", 10 10 "required": [ ··· 38 38 ], 39 39 "properties": { 40 40 "cursor": { 41 - "type": "string" 41 + "type": "string", 42 + "description": "A parameter to paginate results" 42 43 }, 43 44 "feed": { 44 45 "type": "array", 45 46 "items": { 46 47 "type": "ref", 47 48 "ref": "social.clippr.feed.defs#tagView" 48 - } 49 + }, 50 + "description": "An array of hydrated tag views" 49 51 } 50 52 } 51 53 }
+64
lexdocs/social/clippr/feed/getTagClips.json
··· 1 + { 2 + "lexicon": 1, 3 + "id": "social.clippr.feed.getTagClips", 4 + "defs": { 5 + "main": { 6 + "type": "query", 7 + "description": "Get a list of clips that are linked to a tag. Does not require auth.", 8 + "parameters": { 9 + "type": "params", 10 + "required": [ 11 + "actor", 12 + "tag" 13 + ], 14 + "properties": { 15 + "actor": { 16 + "type": "string", 17 + "format": "at-identifier", 18 + "description": "An actor to get valid tags from" 19 + }, 20 + "tag": { 21 + "type": "string", 22 + "maxGraphemes": 64, 23 + "maxLength": 640, 24 + "description": "A tag to use for discovering linked clips" 25 + }, 26 + "limit": { 27 + "type": "integer", 28 + "minimum": 1, 29 + "maximum": 1000, 30 + "default": 50, 31 + "description": "How many results to return with the query" 32 + }, 33 + "cursor": { 34 + "type": "string", 35 + "description": "A parameter to paginate results" 36 + } 37 + } 38 + }, 39 + "output": { 40 + "encoding": "application/json", 41 + "schema": { 42 + "type": "object", 43 + "required": [ 44 + "clips" 45 + ], 46 + "properties": { 47 + "cursor": { 48 + "type": "string", 49 + "description": "A parameter to paginate results" 50 + }, 51 + "clips": { 52 + "type": "array", 53 + "items": { 54 + "type": "ref", 55 + "ref": "social.clippr.feed.defs#clipView" 56 + }, 57 + "description": "An array of hydrated clip views" 58 + } 59 + } 60 + } 61 + } 62 + } 63 + } 64 + }
+1 -1
lexdocs/social/clippr/feed/searchClips.json
··· 51 51 "type": "ref", 52 52 "ref": "social.clippr.feed.defs#clipView" 53 53 }, 54 - "description": "A list of clips and their associated details" 54 + "description": "An array of hydrated clip views" 55 55 } 56 56 } 57 57 }
+1 -1
lexdocs/social/clippr/feed/searchTags.json
··· 51 51 "type": "ref", 52 52 "ref": "social.clippr.feed.defs#tagView" 53 53 }, 54 - "description": "A list of tags and their associated details" 54 + "description": "An array of hydrated tag views" 55 55 } 56 56 } 57 57 }
+7
lexicons/CHANGELOG.md
··· 1 1 # changelog for @clipprjs/lexicons 2 2 3 + ## v1.0.3 4 + 5 + * add ``social.clippr.feed.getTagClips`` query 6 + * make query parameter required for ``social.clippr.actor.searchProfiles`` 7 + * improved lexicon documentation 8 + 3 9 ## v1.0.2 10 + 4 11 * fix some description typos 5 12 * fix `social.clippr.feed.getTags` not existing due to an ID collision 6 13
+1
lexicons/lib/lexicons/index.ts
··· 17 17 export * as SocialClipprFeedGetClips from "./types/social/clippr/feed/getClips.js"; 18 18 export * as SocialClipprFeedGetProfileClips from "./types/social/clippr/feed/getProfileClips.js"; 19 19 export * as SocialClipprFeedGetProfileTags from "./types/social/clippr/feed/getProfileTags.js"; 20 + export * as SocialClipprFeedGetTagClips from "./types/social/clippr/feed/getTagClips.js"; 20 21 export * as SocialClipprFeedGetTagList from "./types/social/clippr/feed/getTagList.js"; 21 22 export * as SocialClipprFeedGetTags from "./types/social/clippr/feed/getTags.js"; 22 23 export * as SocialClipprFeedTag from "./types/social/clippr/feed/tag.js";
+1 -1
lexicons/lib/lexicons/types/social/clippr/actor/searchProfiles.ts
··· 20 20 ]), 21 21 25, 22 22 ), 23 - q: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()), 23 + q: /*#__PURE__*/ v.string(), 24 24 }), 25 25 output: { 26 26 type: "lex",
+51
lexicons/lib/lexicons/types/social/clippr/feed/getTagClips.ts
··· 1 + /* 2 + * clippr: a social bookmarking service for the AT Protocol 3 + * Copyright (c) 2025 clippr contributors. 4 + * SPDX-License-Identifier: AGPL-3.0-only 5 + */ 6 + 7 + import type {} from "@atcute/lexicons"; 8 + import * as v from "@atcute/lexicons/validations"; 9 + import type {} from "@atcute/lexicons/ambient"; 10 + import * as SocialClipprFeedDefs from "./defs.js"; 11 + 12 + const _mainSchema = /*#__PURE__*/ v.query("social.clippr.feed.getTagClips", { 13 + params: /*#__PURE__*/ v.object({ 14 + actor: /*#__PURE__*/ v.actorIdentifierString(), 15 + cursor: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()), 16 + limit: /*#__PURE__*/ v.optional( 17 + /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.integer(), [ 18 + /*#__PURE__*/ v.integerRange(1, 1000), 19 + ]), 20 + 50, 21 + ), 22 + tag: /*#__PURE__*/ v.constrain(/*#__PURE__*/ v.string(), [ 23 + /*#__PURE__*/ v.stringLength(0, 640), 24 + /*#__PURE__*/ v.stringGraphemes(0, 64), 25 + ]), 26 + }), 27 + output: { 28 + type: "lex", 29 + schema: /*#__PURE__*/ v.object({ 30 + get clips() { 31 + return /*#__PURE__*/ v.array(SocialClipprFeedDefs.clipViewSchema); 32 + }, 33 + cursor: /*#__PURE__*/ v.optional(/*#__PURE__*/ v.string()), 34 + }), 35 + }, 36 + }); 37 + 38 + type main$schematype = typeof _mainSchema; 39 + 40 + export interface mainSchema extends main$schematype {} 41 + 42 + export const mainSchema = _mainSchema as mainSchema; 43 + 44 + export interface $params extends v.InferInput<mainSchema["params"]> {} 45 + export interface $output extends v.InferXRPCBodyInput<mainSchema["output"]> {} 46 + 47 + declare module "@atcute/lexicons/ambient" { 48 + interface XRPCQueries { 49 + "social.clippr.feed.getTagClips": mainSchema; 50 + } 51 + }
+1 -1
lexicons/package.json
··· 1 1 { 2 2 "type": "module", 3 3 "name": "@clipprjs/lexicons", 4 - "version": "1.0.2", 4 + "version": "1.0.3", 5 5 "description": "Clippr schema definitions", 6 6 "license": "AGPL-3.0-only", 7 7 "private": false,