From 525960bfb5bcd9062eac459aa95763698b3ef984 Mon Sep 17 00:00:00 2001 From: Alona Enraght-Moony Date: Wed, 30 Aug 2023 20:00:44 +0100 Subject: [PATCH] Update lexicons to commit ad1fcf138711139ceedcf63db3702bf3b6cdb753 See https://github.com/bluesky-social/atproto/commit/ad1fcf138711139ceedcf63db3702bf3b6cdb753 --- .../lexicons/app/bsky/feed/getActorLikes.json | 37 +++ .../app/bsky/notification/registerPush.json | 23 ++ .../com/atproto/admin/rebaseRepo.json | 33 -- .../lexicons/com/atproto/repo/rebaseRepo.json | 33 -- .../com/atproto/sync/getCheckout.json | 7 +- .../com/atproto/sync/getCommitPath.json | 44 --- lexgen/lexicons/com/atproto/sync/getHead.json | 2 +- .../com/atproto/sync/getLatestCommit.json | 35 ++ lexgen/lexicons/com/atproto/sync/getRepo.json | 11 +- .../lexicons/com/atproto/sync/listBlobs.json | 8 +- .../com/atproto/sync/subscribeRepos.json | 15 +- .../com/atproto/temp/upgradeRepoVersion.json | 20 ++ lexgen/src/lexicon.rs | 7 +- lexgen/validator/lexicon/lexicons.ts | 298 ++++++++++-------- src/lex/com/atproto/sync.rs | 2 +- 15 files changed, 311 insertions(+), 264 deletions(-) create mode 100644 lexgen/lexicons/app/bsky/feed/getActorLikes.json create mode 100644 lexgen/lexicons/app/bsky/notification/registerPush.json delete mode 100644 lexgen/lexicons/com/atproto/admin/rebaseRepo.json delete mode 100644 lexgen/lexicons/com/atproto/repo/rebaseRepo.json delete mode 100644 lexgen/lexicons/com/atproto/sync/getCommitPath.json create mode 100644 lexgen/lexicons/com/atproto/sync/getLatestCommit.json create mode 100644 lexgen/lexicons/com/atproto/temp/upgradeRepoVersion.json diff --git a/lexgen/lexicons/app/bsky/feed/getActorLikes.json b/lexgen/lexicons/app/bsky/feed/getActorLikes.json new file mode 100644 index 0000000..38bb353 --- /dev/null +++ b/lexgen/lexicons/app/bsky/feed/getActorLikes.json @@ -0,0 +1,37 @@ +{ + "lexicon": 1, + "id": "app.bsky.feed.getActorLikes", + "defs": { + "main": { + "type": "query", + "description": "A view of the posts liked by an actor.", + "parameters": { + "type": "params", + "required": ["actor"], + "properties": { + "actor": {"type": "string", "format": "at-identifier"}, + "limit": {"type": "integer", "minimum": 1, "maximum": 100, "default": 50}, + "cursor": {"type": "string"} + } + }, + "output": { + "encoding": "application/json", + "schema": { + "type": "object", + "required": ["feed"], + "properties": { + "cursor": {"type": "string"}, + "feed": { + "type": "array", + "items": {"type": "ref", "ref": "app.bsky.feed.defs#feedViewPost"} + } + } + } + }, + "errors": [ + {"name": "BlockedActor"}, + {"name": "BlockedByActor"} + ] + } + } +} diff --git a/lexgen/lexicons/app/bsky/notification/registerPush.json b/lexgen/lexicons/app/bsky/notification/registerPush.json new file mode 100644 index 0000000..af83cfa --- /dev/null +++ b/lexgen/lexicons/app/bsky/notification/registerPush.json @@ -0,0 +1,23 @@ +{ + "lexicon": 1, + "id": "app.bsky.notification.registerPush", + "defs": { + "main": { + "type": "procedure", + "description": "Register for push notifications with a service", + "input": { + "encoding": "application/json", + "schema": { + "type": "object", + "required": ["serviceDid", "token", "platform", "appId"], + "properties": { + "serviceDid": {"type": "string", "format": "did"}, + "token": {"type": "string"}, + "platform": {"type": "string", "knownValues": ["ios", "android", "web"]}, + "appId": {"type": "string"} + } + } + } + } + } +} diff --git a/lexgen/lexicons/com/atproto/admin/rebaseRepo.json b/lexgen/lexicons/com/atproto/admin/rebaseRepo.json deleted file mode 100644 index 86e75c5..0000000 --- a/lexgen/lexicons/com/atproto/admin/rebaseRepo.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "lexicon": 1, - "id": "com.atproto.admin.rebaseRepo", - "defs": { - "main": { - "type": "procedure", - "description": "Administrative action to rebase an account's repo", - "input": { - "encoding": "application/json", - "schema": { - "type": "object", - "required": ["repo"], - "properties": { - "repo": { - "type": "string", - "format": "at-identifier", - "description": "The handle or DID of the repo." - }, - "swapCommit": { - "type": "string", - "format": "cid", - "description": "Compare and swap with the previous commit by cid." - } - } - } - }, - "errors": [ - {"name": "InvalidSwap"}, - {"name": "ConcurrentWrites"} - ] - } - } -} diff --git a/lexgen/lexicons/com/atproto/repo/rebaseRepo.json b/lexgen/lexicons/com/atproto/repo/rebaseRepo.json deleted file mode 100644 index ff278c0..0000000 --- a/lexgen/lexicons/com/atproto/repo/rebaseRepo.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - "lexicon": 1, - "id": "com.atproto.repo.rebaseRepo", - "defs": { - "main": { - "type": "procedure", - "description": "Simple rebase of repo that deletes history", - "input": { - "encoding": "application/json", - "schema": { - "type": "object", - "required": ["repo"], - "properties": { - "repo": { - "type": "string", - "format": "at-identifier", - "description": "The handle or DID of the repo." - }, - "swapCommit": { - "type": "string", - "format": "cid", - "description": "Compare and swap with the previous commit by cid." - } - } - } - }, - "errors": [ - {"name": "InvalidSwap"}, - {"name": "ConcurrentWrites"} - ] - } - } -} diff --git a/lexgen/lexicons/com/atproto/sync/getCheckout.json b/lexgen/lexicons/com/atproto/sync/getCheckout.json index 16b2330..0f57cb3 100644 --- a/lexgen/lexicons/com/atproto/sync/getCheckout.json +++ b/lexgen/lexicons/com/atproto/sync/getCheckout.json @@ -4,7 +4,7 @@ "defs": { "main": { "type": "query", - "description": "Gets the repo state.", + "description": "DEPRECATED - please use com.atproto.sync.getRepo instead", "parameters": { "type": "params", "required": ["did"], @@ -13,11 +13,6 @@ "type": "string", "format": "did", "description": "The DID of the repo." - }, - "commit": { - "type": "string", - "format": "cid", - "description": "The commit to get the checkout from. Defaults to current HEAD." } } }, diff --git a/lexgen/lexicons/com/atproto/sync/getCommitPath.json b/lexgen/lexicons/com/atproto/sync/getCommitPath.json deleted file mode 100644 index d011595..0000000 --- a/lexgen/lexicons/com/atproto/sync/getCommitPath.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "lexicon": 1, - "id": "com.atproto.sync.getCommitPath", - "defs": { - "main": { - "type": "query", - "description": "Gets the path of repo commits", - "parameters": { - "type": "params", - "required": ["did"], - "properties": { - "did": { - "type": "string", - "format": "did", - "description": "The DID of the repo." - }, - "latest": { - "type": "string", - "format": "cid", - "description": "The most recent commit" - }, - "earliest": { - "type": "string", - "format": "cid", - "description": "The earliest commit to start from" - } - } - }, - "output": { - "encoding": "application/json", - "schema": { - "type": "object", - "required": ["commits"], - "properties": { - "commits": { - "type": "array", - "items": { "type": "string", "format": "cid" } - } - } - } - } - } - } -} \ No newline at end of file diff --git a/lexgen/lexicons/com/atproto/sync/getHead.json b/lexgen/lexicons/com/atproto/sync/getHead.json index 38bfe22..bfd110e 100644 --- a/lexgen/lexicons/com/atproto/sync/getHead.json +++ b/lexgen/lexicons/com/atproto/sync/getHead.json @@ -4,7 +4,7 @@ "defs": { "main": { "type": "query", - "description": "Gets the current HEAD CID of a repo.", + "description": "DEPRECATED - please use com.atproto.sync.getLatestCommit instead", "parameters": { "type": "params", "required": ["did"], diff --git a/lexgen/lexicons/com/atproto/sync/getLatestCommit.json b/lexgen/lexicons/com/atproto/sync/getLatestCommit.json new file mode 100644 index 0000000..8beebda --- /dev/null +++ b/lexgen/lexicons/com/atproto/sync/getLatestCommit.json @@ -0,0 +1,35 @@ +{ + "lexicon": 1, + "id": "com.atproto.sync.getLatestCommit", + "defs": { + "main": { + "type": "query", + "description": "Gets the current commit CID & revision of the repo.", + "parameters": { + "type": "params", + "required": ["did"], + "properties": { + "did": { + "type": "string", + "format": "did", + "description": "The DID of the repo." + } + } + }, + "output": { + "encoding": "application/json", + "schema": { + "type": "object", + "required": ["cid", "rev"], + "properties": { + "cid": {"type": "string", "format": "cid"}, + "rev": {"type": "string"} + } + } + }, + "errors": [ + {"name": "RepoNotFound"} + ] + } + } +} diff --git a/lexgen/lexicons/com/atproto/sync/getRepo.json b/lexgen/lexicons/com/atproto/sync/getRepo.json index bf0991d..87ecaa1 100644 --- a/lexgen/lexicons/com/atproto/sync/getRepo.json +++ b/lexgen/lexicons/com/atproto/sync/getRepo.json @@ -4,7 +4,7 @@ "defs": { "main": { "type": "query", - "description": "Gets the repo state.", + "description": "Gets the did's repo, optionally catching up from a specific revision.", "parameters": { "type": "params", "required": ["did"], @@ -14,15 +14,10 @@ "format": "did", "description": "The DID of the repo." }, - "earliest": { + "since": { "type": "string", "format": "cid", - "description": "The earliest commit in the commit range (not inclusive)" - }, - "latest": { - "type": "string", - "format": "cid", - "description": "The latest commit in the commit range (inclusive)" + "description": "The revision of the repo to catch up from." } } }, diff --git a/lexgen/lexicons/com/atproto/sync/listBlobs.json b/lexgen/lexicons/com/atproto/sync/listBlobs.json index 8939a5e..7ca3039 100644 --- a/lexgen/lexicons/com/atproto/sync/listBlobs.json +++ b/lexgen/lexicons/com/atproto/sync/listBlobs.json @@ -4,14 +4,15 @@ "defs": { "main": { "type": "query", - "description": "List blob cids for some range of commits", + "description": "List blob cids since some revision", "parameters": { "type": "params", "required": ["did"], "properties": { "did": {"type": "string", "format": "did", "description": "The DID of the repo."}, - "latest": { "type": "string", "format": "cid", "description": "The most recent commit"}, - "earliest": { "type": "string", "format": "cid", "description": "The earliest commit to start from"} + "since": { "type": "string", "format": "cid", "description": "Optional revision of the repo to list blobs since"}, + "limit": {"type": "integer", "minimum": 1, "maximum": 1000, "default": 500}, + "cursor": {"type": "string"} } }, "output": { @@ -20,6 +21,7 @@ "type": "object", "required": ["cids"], "properties": { + "cursor": {"type": "string"}, "cids": { "type": "array", "items": { "type": "string", "format": "cid" } diff --git a/lexgen/lexicons/com/atproto/sync/subscribeRepos.json b/lexgen/lexicons/com/atproto/sync/subscribeRepos.json index 04a6334..ee3e88a 100644 --- a/lexgen/lexicons/com/atproto/sync/subscribeRepos.json +++ b/lexgen/lexicons/com/atproto/sync/subscribeRepos.json @@ -33,8 +33,8 @@ }, "commit": { "type": "object", - "required": ["seq", "rebase", "tooBig", "repo", "commit", "prev", "blocks", "ops", "blobs", "time"], - "nullable": ["prev"], + "required": ["seq", "rebase", "tooBig", "repo", "commit", "rev", "since", "blocks", "ops", "blobs", "time"], + "nullable": ["prev", "since"], "properties": { "seq": {"type": "integer"}, "rebase": {"type": "boolean"}, @@ -42,6 +42,14 @@ "repo": {"type": "string", "format": "did"}, "commit": {"type": "cid-link"}, "prev": {"type": "cid-link"}, + "rev": { + "type": "string", + "description": "The rev of the emitted commit" + }, + "since": { + "type": "string", + "description": "The rev of the last emitted commit from this repo" + }, "blocks": { "type": "bytes", "description": "CAR file containing relevant blocks", @@ -104,6 +112,7 @@ }, "repoOp": { "type": "object", + "description": "A repo operation, ie a write of a single record. For creates and updates, cid is the record's CID as of this operation. For deletes, it's null.", "required": ["action", "path", "cid"], "nullable": ["cid"], "properties": { @@ -120,4 +129,4 @@ } } } -} \ No newline at end of file +} diff --git a/lexgen/lexicons/com/atproto/temp/upgradeRepoVersion.json b/lexgen/lexicons/com/atproto/temp/upgradeRepoVersion.json new file mode 100644 index 0000000..bd19374 --- /dev/null +++ b/lexgen/lexicons/com/atproto/temp/upgradeRepoVersion.json @@ -0,0 +1,20 @@ +{ + "lexicon": 1, + "id": "com.atproto.temp.upgradeRepoVersion", + "defs": { + "main": { + "type": "procedure", + "description": "Upgrade a repo to v3", + "input": { + "encoding": "application/json", + "schema": { + "type": "object", + "required": ["did"], + "properties": { + "did": { "type": "string", "format": "did" } + } + } + } + } + } +} diff --git a/lexgen/src/lexicon.rs b/lexgen/src/lexicon.rs index e91eb05..500b712 100644 --- a/lexgen/src/lexicon.rs +++ b/lexgen/src/lexicon.rs @@ -407,6 +407,7 @@ mod tests { "app/bsky/feed/describeFeedGenerator.json", "app/bsky/feed/generator.json", "app/bsky/feed/getActorFeeds.json", + "app/bsky/feed/getActorLikes.json", "app/bsky/feed/getAuthorFeed.json", "app/bsky/feed/getFeed.json", "app/bsky/feed/getFeedGenerator.json", @@ -438,6 +439,7 @@ mod tests { "app/bsky/graph/unmuteActorList.json", "app/bsky/notification/getUnreadCount.json", "app/bsky/notification/listNotifications.json", + "app/bsky/notification/registerPush.json", "app/bsky/notification/updateSeen.json", "app/bsky/richtext/facet.json", "app/bsky/unspecced/applyLabels.json", @@ -455,7 +457,6 @@ mod tests { "com/atproto/admin/getModerationReports.json", "com/atproto/admin/getRecord.json", "com/atproto/admin/getRepo.json", - "com/atproto/admin/rebaseRepo.json", "com/atproto/admin/resolveModerationReports.json", "com/atproto/admin/reverseModerationAction.json", "com/atproto/admin/searchRepos.json", @@ -477,7 +478,6 @@ mod tests { "com/atproto/repo/getRecord.json", "com/atproto/repo/listRecords.json", "com/atproto/repo/putRecord.json", - "com/atproto/repo/rebaseRepo.json", "com/atproto/repo/strongRef.json", "com/atproto/repo/uploadBlob.json", "com/atproto/server/createAccount.json", @@ -500,8 +500,8 @@ mod tests { "com/atproto/sync/getBlob.json", "com/atproto/sync/getBlocks.json", "com/atproto/sync/getCheckout.json", - "com/atproto/sync/getCommitPath.json", "com/atproto/sync/getHead.json", + "com/atproto/sync/getLatestCommit.json", "com/atproto/sync/getRecord.json", "com/atproto/sync/getRepo.json", "com/atproto/sync/listBlobs.json", @@ -509,6 +509,7 @@ mod tests { "com/atproto/sync/notifyOfUpdate.json", "com/atproto/sync/requestCrawl.json", "com/atproto/sync/subscribeRepos.json", + "com/atproto/temp/upgradeRepoVersion.json", ]; #[test] diff --git a/lexgen/validator/lexicon/lexicons.ts b/lexgen/validator/lexicon/lexicons.ts index 1e31f13..8398755 100644 --- a/lexgen/validator/lexicon/lexicons.ts +++ b/lexgen/validator/lexicon/lexicons.ts @@ -1228,6 +1228,62 @@ export const schemaDict = { }, }, }, + AppBskyFeedGetActorLikes: { + lexicon: 1, + id: 'app.bsky.feed.getActorLikes', + defs: { + main: { + type: 'query', + description: 'A view of the posts liked by an actor.', + parameters: { + type: 'params', + required: ['actor'], + properties: { + actor: { + type: 'string', + format: 'at-identifier', + }, + limit: { + type: 'integer', + minimum: 1, + maximum: 100, + default: 50, + }, + cursor: { + type: 'string', + }, + }, + }, + output: { + encoding: 'application/json', + schema: { + type: 'object', + required: ['feed'], + properties: { + cursor: { + type: 'string', + }, + feed: { + type: 'array', + items: { + type: 'ref', + ref: 'lex:app.bsky.feed.defs#feedViewPost', + }, + }, + }, + }, + }, + errors: [ + { + name: 'BlockedActor', + }, + { + name: 'BlockedByActor', + }, + ], + }, + }, + }, AppBskyFeedGetAuthorFeed: { lexicon: 1, id: 'app.bsky.feed.getAuthorFeed', @@ -2723,6 +2779,39 @@ export const schemaDict = { }, }, }, + AppBskyNotificationRegisterPush: { + lexicon: 1, + id: 'app.bsky.notification.registerPush', + defs: { + main: { + type: 'procedure', + description: 'Register for push notifications with a service', + input: { + encoding: 'application/json', + schema: { + type: 'object', + required: ['serviceDid', 'token', 'platform', 'appId'], + properties: { + serviceDid: { + type: 'string', + format: 'did', + }, + token: { + type: 'string', + }, + platform: { + type: 'string', + knownValues: ['ios', 'android', 'web'], + }, + appId: { + type: 'string', + }, + }, + }, + }, + }, + }, + }, AppBskyNotificationUpdateSeen: { lexicon: 1, id: 'app.bsky.notification.updateSeen', @@ -3999,44 +4088,6 @@ export const schemaDict = { }, }, }, - ComAtprotoAdminRebaseRepo: { - lexicon: 1, - id: 'com.atproto.admin.rebaseRepo', - defs: { - main: { - type: 'procedure', - description: "Administrative action to rebase an account's repo", - input: { - encoding: 'application/json', - schema: { - type: 'object', - required: ['repo'], - properties: { - repo: { - type: 'string', - format: 'at-identifier', - description: 'The handle or DID of the repo.', - }, - swapCommit: { - type: 'string', - format: 'cid', - description: - 'Compare and swap with the previous commit by cid.', - }, - }, - }, - }, - errors: [ - { - name: 'InvalidSwap', - }, - { - name: 'ConcurrentWrites', - }, - ], - }, - }, - }, ComAtprotoAdminResolveModerationReports: { lexicon: 1, id: 'com.atproto.admin.resolveModerationReports', @@ -5202,44 +5253,6 @@ export const schemaDict = { }, }, }, - ComAtprotoRepoRebaseRepo: { - lexicon: 1, - id: 'com.atproto.repo.rebaseRepo', - defs: { - main: { - type: 'procedure', - description: 'Simple rebase of repo that deletes history', - input: { - encoding: 'application/json', - schema: { - type: 'object', - required: ['repo'], - properties: { - repo: { - type: 'string', - format: 'at-identifier', - description: 'The handle or DID of the repo.', - }, - swapCommit: { - type: 'string', - format: 'cid', - description: - 'Compare and swap with the previous commit by cid.', - }, - }, - }, - }, - errors: [ - { - name: 'InvalidSwap', - }, - { - name: 'ConcurrentWrites', - }, - ], - }, - }, - }, ComAtprotoRepoStrongRef: { lexicon: 1, id: 'com.atproto.repo.strongRef', @@ -6042,7 +6055,7 @@ export const schemaDict = { defs: { main: { type: 'query', - description: 'Gets the repo state.', + description: 'DEPRECATED - please use com.atproto.sync.getRepo instead', parameters: { type: 'params', required: ['did'], @@ -6052,12 +6065,6 @@ export const schemaDict = { format: 'did', description: 'The DID of the repo.', }, - commit: { - type: 'string', - format: 'cid', - description: - 'The commit to get the checkout from. Defaults to current HEAD.', - }, }, }, output: { @@ -6066,13 +6073,14 @@ export const schemaDict = { }, }, }, - ComAtprotoSyncGetCommitPath: { + ComAtprotoSyncGetHead: { lexicon: 1, - id: 'com.atproto.sync.getCommitPath', + id: 'com.atproto.sync.getHead', defs: { main: { type: 'query', - description: 'Gets the path of repo commits', + description: + 'DEPRECATED - please use com.atproto.sync.getLatestCommit instead', parameters: { type: 'params', required: ['did'], @@ -6082,44 +6090,36 @@ export const schemaDict = { format: 'did', description: 'The DID of the repo.', }, - latest: { - type: 'string', - format: 'cid', - description: 'The most recent commit', - }, - earliest: { - type: 'string', - format: 'cid', - description: 'The earliest commit to start from', - }, }, }, output: { encoding: 'application/json', schema: { type: 'object', - required: ['commits'], + required: ['root'], properties: { - commits: { - type: 'array', - items: { - type: 'string', - format: 'cid', - }, + root: { + type: 'string', + format: 'cid', }, }, }, }, + errors: [ + { + name: 'HeadNotFound', + }, + ], }, }, }, - ComAtprotoSyncGetHead: { + ComAtprotoSyncGetLatestCommit: { lexicon: 1, - id: 'com.atproto.sync.getHead', + id: 'com.atproto.sync.getLatestCommit', defs: { main: { type: 'query', - description: 'Gets the current HEAD CID of a repo.', + description: 'Gets the current commit CID & revision of the repo.', parameters: { type: 'params', required: ['did'], @@ -6135,18 +6135,21 @@ export const schemaDict = { encoding: 'application/json', schema: { type: 'object', - required: ['root'], + required: ['cid', 'rev'], properties: { - root: { + cid: { type: 'string', format: 'cid', }, + rev: { + type: 'string', + }, }, }, }, errors: [ { - name: 'HeadNotFound', + name: 'RepoNotFound', }, ], }, @@ -6195,7 +6198,8 @@ export const schemaDict = { defs: { main: { type: 'query', - description: 'Gets the repo state.', + description: + "Gets the did's repo, optionally catching up from a specific revision.", parameters: { type: 'params', required: ['did'], @@ -6205,16 +6209,10 @@ export const schemaDict = { format: 'did', description: 'The DID of the repo.', }, - earliest: { + since: { type: 'string', format: 'cid', - description: - 'The earliest commit in the commit range (not inclusive)', - }, - latest: { - type: 'string', - format: 'cid', - description: 'The latest commit in the commit range (inclusive)', + description: 'The revision of the repo to catch up from.', }, }, }, @@ -6230,7 +6228,7 @@ export const schemaDict = { defs: { main: { type: 'query', - description: 'List blob cids for some range of commits', + description: 'List blob cids since some revision', parameters: { type: 'params', required: ['did'], @@ -6240,15 +6238,19 @@ export const schemaDict = { format: 'did', description: 'The DID of the repo.', }, - latest: { + since: { type: 'string', format: 'cid', - description: 'The most recent commit', + description: 'Optional revision of the repo to list blobs since', + }, + limit: { + type: 'integer', + minimum: 1, + maximum: 1000, + default: 500, }, - earliest: { + cursor: { type: 'string', - format: 'cid', - description: 'The earliest commit to start from', }, }, }, @@ -6258,6 +6260,9 @@ export const schemaDict = { type: 'object', required: ['cids'], properties: { + cursor: { + type: 'string', + }, cids: { type: 'array', items: { @@ -6422,13 +6427,14 @@ export const schemaDict = { 'tooBig', 'repo', 'commit', - 'prev', + 'rev', + 'since', 'blocks', 'ops', 'blobs', 'time', ], - nullable: ['prev'], + nullable: ['prev', 'since'], properties: { seq: { type: 'integer', @@ -6449,6 +6455,14 @@ export const schemaDict = { prev: { type: 'cid-link', }, + rev: { + type: 'string', + description: 'The rev of the emitted commit', + }, + since: { + type: 'string', + description: 'The rev of the last emitted commit from this repo', + }, blocks: { type: 'bytes', description: 'CAR file containing relevant blocks', @@ -6548,6 +6562,8 @@ export const schemaDict = { }, repoOp: { type: 'object', + description: + "A repo operation, ie a write of a single record. For creates and updates, cid is the record's CID as of this operation. For deletes, it's null.", required: ['action', 'path', 'cid'], nullable: ['cid'], properties: { @@ -6565,6 +6581,29 @@ export const schemaDict = { }, }, }, + ComAtprotoTempUpgradeRepoVersion: { + lexicon: 1, + id: 'com.atproto.temp.upgradeRepoVersion', + defs: { + main: { + type: 'procedure', + description: 'Upgrade a repo to v3', + input: { + encoding: 'application/json', + schema: { + type: 'object', + required: ['did'], + properties: { + did: { + type: 'string', + format: 'did', + }, + }, + }, + }, + }, + }, + }, } export const schemas: LexiconDoc[] = Object.values(schemaDict) as LexiconDoc[] export const lexicons: Lexicons = new Lexicons(schemas) @@ -6586,6 +6625,7 @@ export const ids = { AppBskyFeedDescribeFeedGenerator: 'app.bsky.feed.describeFeedGenerator', AppBskyFeedGenerator: 'app.bsky.feed.generator', AppBskyFeedGetActorFeeds: 'app.bsky.feed.getActorFeeds', + AppBskyFeedGetActorLikes: 'app.bsky.feed.getActorLikes', AppBskyFeedGetAuthorFeed: 'app.bsky.feed.getAuthorFeed', AppBskyFeedGetFeed: 'app.bsky.feed.getFeed', AppBskyFeedGetFeedGenerator: 'app.bsky.feed.getFeedGenerator', @@ -6618,6 +6658,7 @@ export const ids = { AppBskyNotificationGetUnreadCount: 'app.bsky.notification.getUnreadCount', AppBskyNotificationListNotifications: 'app.bsky.notification.listNotifications', + AppBskyNotificationRegisterPush: 'app.bsky.notification.registerPush', AppBskyNotificationUpdateSeen: 'app.bsky.notification.updateSeen', AppBskyRichtextFacet: 'app.bsky.richtext.facet', AppBskyUnspeccedApplyLabels: 'app.bsky.unspecced.applyLabels', @@ -6637,7 +6678,6 @@ export const ids = { ComAtprotoAdminGetModerationReports: 'com.atproto.admin.getModerationReports', ComAtprotoAdminGetRecord: 'com.atproto.admin.getRecord', ComAtprotoAdminGetRepo: 'com.atproto.admin.getRepo', - ComAtprotoAdminRebaseRepo: 'com.atproto.admin.rebaseRepo', ComAtprotoAdminResolveModerationReports: 'com.atproto.admin.resolveModerationReports', ComAtprotoAdminReverseModerationAction: @@ -6661,7 +6701,6 @@ export const ids = { ComAtprotoRepoGetRecord: 'com.atproto.repo.getRecord', ComAtprotoRepoListRecords: 'com.atproto.repo.listRecords', ComAtprotoRepoPutRecord: 'com.atproto.repo.putRecord', - ComAtprotoRepoRebaseRepo: 'com.atproto.repo.rebaseRepo', ComAtprotoRepoStrongRef: 'com.atproto.repo.strongRef', ComAtprotoRepoUploadBlob: 'com.atproto.repo.uploadBlob', ComAtprotoServerCreateAccount: 'com.atproto.server.createAccount', @@ -6687,8 +6726,8 @@ export const ids = { ComAtprotoSyncGetBlob: 'com.atproto.sync.getBlob', ComAtprotoSyncGetBlocks: 'com.atproto.sync.getBlocks', ComAtprotoSyncGetCheckout: 'com.atproto.sync.getCheckout', - ComAtprotoSyncGetCommitPath: 'com.atproto.sync.getCommitPath', ComAtprotoSyncGetHead: 'com.atproto.sync.getHead', + ComAtprotoSyncGetLatestCommit: 'com.atproto.sync.getLatestCommit', ComAtprotoSyncGetRecord: 'com.atproto.sync.getRecord', ComAtprotoSyncGetRepo: 'com.atproto.sync.getRepo', ComAtprotoSyncListBlobs: 'com.atproto.sync.listBlobs', @@ -6696,4 +6735,5 @@ export const ids = { ComAtprotoSyncNotifyOfUpdate: 'com.atproto.sync.notifyOfUpdate', ComAtprotoSyncRequestCrawl: 'com.atproto.sync.requestCrawl', ComAtprotoSyncSubscribeRepos: 'com.atproto.sync.subscribeRepos', + ComAtprotoTempUpgradeRepoVersion: 'com.atproto.temp.upgradeRepoVersion', } diff --git a/src/lex/com/atproto/sync.rs b/src/lex/com/atproto/sync.rs index 4a2a004..f6c88c0 100644 --- a/src/lex/com/atproto/sync.rs +++ b/src/lex/com/atproto/sync.rs @@ -3,7 +3,7 @@ pub mod get_head; #[allow(unused_imports)] use super::super::super::_lex; -///Gets the current HEAD CID of a repo. +///DEPRECATED - please use com.atproto.sync.getLatestCommit instead pub async fn get_head( client: &_lex::_rt::Client, args: &_lex::com::atproto::sync::get_head::Params,