@atproto/bsky 0.0.201 → 0.0.202

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/api/app/bsky/ageassurance/begin.d.ts.map +1 -1
  3. package/dist/api/app/bsky/ageassurance/begin.js +15 -8
  4. package/dist/api/app/bsky/ageassurance/begin.js.map +1 -1
  5. package/dist/api/index.d.ts +1 -0
  6. package/dist/api/index.d.ts.map +1 -1
  7. package/dist/api/index.js +2 -1
  8. package/dist/api/index.js.map +1 -1
  9. package/dist/api/sitemap.d.ts +4 -0
  10. package/dist/api/sitemap.d.ts.map +1 -0
  11. package/dist/api/sitemap.js +67 -0
  12. package/dist/api/sitemap.js.map +1 -0
  13. package/dist/data-plane/server/routes/index.d.ts.map +1 -1
  14. package/dist/data-plane/server/routes/index.js +2 -0
  15. package/dist/data-plane/server/routes/index.js.map +1 -1
  16. package/dist/data-plane/server/routes/profile.d.ts.map +1 -1
  17. package/dist/data-plane/server/routes/profile.js +10 -8
  18. package/dist/data-plane/server/routes/profile.js.map +1 -1
  19. package/dist/data-plane/server/routes/sitemap.d.ts +5 -0
  20. package/dist/data-plane/server/routes/sitemap.d.ts.map +1 -0
  21. package/dist/data-plane/server/routes/sitemap.js +38 -0
  22. package/dist/data-plane/server/routes/sitemap.js.map +1 -0
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/index.js +3 -0
  25. package/dist/index.js.map +1 -1
  26. package/dist/lexicon/lexicons.d.ts +2 -2
  27. package/dist/lexicon/lexicons.d.ts.map +1 -1
  28. package/dist/lexicon/lexicons.js +1 -0
  29. package/dist/lexicon/lexicons.js.map +1 -1
  30. package/dist/lexicon/types/app/bsky/notification/listNotifications.d.ts +1 -1
  31. package/dist/lexicon/types/app/bsky/notification/listNotifications.d.ts.map +1 -1
  32. package/dist/lexicon/types/app/bsky/notification/listNotifications.js.map +1 -1
  33. package/dist/proto/bsky_connect.d.ts +21 -1
  34. package/dist/proto/bsky_connect.d.ts.map +1 -1
  35. package/dist/proto/bsky_connect.js +20 -0
  36. package/dist/proto/bsky_connect.js.map +1 -1
  37. package/dist/proto/bsky_pb.d.ts +97 -0
  38. package/dist/proto/bsky_pb.d.ts.map +1 -1
  39. package/dist/proto/bsky_pb.js +256 -5
  40. package/dist/proto/bsky_pb.js.map +1 -1
  41. package/package.json +6 -6
  42. package/proto/bsky.proto +31 -0
  43. package/src/api/app/bsky/ageassurance/begin.ts +21 -11
  44. package/src/api/index.ts +2 -0
  45. package/src/api/sitemap.ts +76 -0
  46. package/src/data-plane/server/routes/index.ts +2 -0
  47. package/src/data-plane/server/routes/profile.ts +8 -6
  48. package/src/data-plane/server/routes/sitemap.ts +43 -0
  49. package/src/index.ts +6 -1
  50. package/src/lexicon/lexicons.ts +1 -0
  51. package/src/lexicon/types/app/bsky/notification/listNotifications.ts +1 -0
  52. package/src/proto/bsky_connect.ts +21 -1
  53. package/src/proto/bsky_pb.ts +188 -0
  54. package/tests/sitemap.test.ts +75 -0
  55. package/tests/views/age-assurance-v2.test.ts +51 -0
  56. package/tsconfig.build.tsbuildinfo +1 -1
  57. package/tsconfig.tests.tsbuildinfo +1 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atproto/bsky",
3
- "version": "0.0.201",
3
+ "version": "0.0.202",
4
4
  "license": "MIT",
5
5
  "description": "Reference implementation of app.bsky App View (Bluesky API)",
6
6
  "keywords": [
@@ -53,15 +53,15 @@
53
53
  "zod": "3.23.8",
54
54
  "@atproto-labs/fetch-node": "0.2.0",
55
55
  "@atproto-labs/xrpc-utils": "0.0.24",
56
- "@atproto/api": "^0.18.6",
56
+ "@atproto/api": "^0.18.7",
57
57
  "@atproto/common": "^0.5.3",
58
58
  "@atproto/crypto": "^0.4.5",
59
59
  "@atproto/did": "^0.2.3",
60
60
  "@atproto/identity": "^0.4.10",
61
61
  "@atproto/lexicon": "^0.6.0",
62
62
  "@atproto/repo": "^0.8.12",
63
- "@atproto/syntax": "^0.4.2",
64
63
  "@atproto/sync": "^0.1.39",
64
+ "@atproto/syntax": "^0.4.2",
65
65
  "@atproto/xrpc-server": "^0.10.3"
66
66
  },
67
67
  "devDependencies": {
@@ -78,10 +78,10 @@
78
78
  "jest": "^28.1.2",
79
79
  "ts-node": "^10.8.2",
80
80
  "typescript": "^5.6.3",
81
- "@atproto/lex-cli": "^0.9.8",
82
- "@atproto/api": "^0.18.6",
81
+ "@atproto/api": "^0.18.7",
82
+ "@atproto/xrpc": "^0.7.7",
83
83
  "@atproto/pds": "^0.4.199",
84
- "@atproto/xrpc": "^0.7.7"
84
+ "@atproto/lex-cli": "^0.9.8"
85
85
  },
86
86
  "scripts": {
87
87
  "codegen": "lex gen-server --yes ./src/lexicon ../../lexicons/com/atproto/*/* ../../lexicons/app/bsky/*/* ../../lexicons/chat/bsky/*/*",
package/proto/bsky.proto CHANGED
@@ -1310,6 +1310,33 @@ message GetFollowsFollowingResponse {
1310
1310
  repeated FollowsFollowing results = 1;
1311
1311
  }
1312
1312
 
1313
+ message GetSitemapIndexRequest {
1314
+ SitemapPageType type = 1;
1315
+ }
1316
+
1317
+ message GetSitemapIndexResponse {
1318
+ // GZIP compressed XML sitemap
1319
+ bytes sitemap = 1;
1320
+ }
1321
+
1322
+ // Sitemap HTTP paths are typically of the form `/type/yyyy-mm-dd/N.xml.gz`, i.e. `/users/2025-01-01/1.xml.gz`
1323
+ message GetSitemapPageRequest {
1324
+ SitemapPageType type = 1;
1325
+ google.protobuf.Timestamp date = 2;
1326
+ // One-indexed
1327
+ int32 bucket = 3;
1328
+ }
1329
+
1330
+ enum SitemapPageType {
1331
+ SITEMAP_PAGE_TYPE_UNSPECIFIED = 0;
1332
+ SITEMAP_PAGE_TYPE_USER = 1;
1333
+ }
1334
+
1335
+ message GetSitemapPageResponse {
1336
+ // GZIP compressed XML sitemap
1337
+ bytes sitemap = 1;
1338
+ }
1339
+
1313
1340
  // Ping
1314
1341
  message PingRequest {}
1315
1342
  message PingResponse {}
@@ -1470,6 +1497,10 @@ service Service {
1470
1497
  // Graph
1471
1498
  rpc GetFollowsFollowing(GetFollowsFollowingRequest) returns (GetFollowsFollowingResponse);
1472
1499
 
1500
+ // Sitemaps
1501
+ rpc GetSitemapIndex(GetSitemapIndexRequest) returns (GetSitemapIndexResponse);
1502
+ rpc GetSitemapPage(GetSitemapPageRequest) returns (GetSitemapPageResponse);
1503
+
1473
1504
  // Ping
1474
1505
  rpc Ping(PingRequest) returns (PingResponse);
1475
1506
 
@@ -37,14 +37,14 @@ export default function (server: Server, ctx: AppContext) {
37
37
 
38
38
  const actorDid = auth.credentials.iss
39
39
  const actorInfo = await getAgeVerificationState(ctx, actorDid)
40
+ const existingStatus = actorInfo?.ageAssuranceStatus?.status
41
+ const existingAccess = actorInfo?.ageAssuranceStatus?.access
40
42
 
41
- if (actorInfo?.ageAssuranceStatus) {
42
- if (actorInfo.ageAssuranceStatus.status === 'blocked') {
43
- throw new InvalidRequestError(
44
- `Cannot initiate age assurance flow from current state: ${actorInfo.ageAssuranceStatus.status}`,
45
- 'InvalidInitiation',
46
- )
47
- }
43
+ if (existingStatus === 'blocked') {
44
+ throw new InvalidRequestError(
45
+ `Cannot initiate age assurance flow from current state: ${existingStatus}`,
46
+ 'InvalidInitiation',
47
+ )
48
48
  }
49
49
 
50
50
  const attemptId = crypto.randomUUID()
@@ -107,14 +107,24 @@ export default function (server: Server, ctx: AppContext) {
107
107
  })
108
108
  }
109
109
 
110
+ // If we have existing status/access for this region, retain it.
111
+ const nextStatus =
112
+ existingStatus && existingStatus !== 'unknown'
113
+ ? existingStatus
114
+ : 'pending'
115
+ const nextAccess =
116
+ existingAccess && existingAccess !== 'unknown'
117
+ ? existingAccess
118
+ : 'unknown'
119
+
110
120
  const event = await createEvent(ctx, actorDid, {
111
121
  attemptId,
112
122
  email,
113
123
  // Assumes `app.set('trust proxy', ...)` configured with `true` or specific values.
114
124
  initIp: req.ip,
115
125
  initUa: getClientUa(req),
116
- status: 'pending',
117
- access: 'unknown',
126
+ status: nextStatus,
127
+ access: nextAccess,
118
128
  countryCode,
119
129
  regionCode,
120
130
  })
@@ -123,8 +133,8 @@ export default function (server: Server, ctx: AppContext) {
123
133
  encoding: 'application/json',
124
134
  body: {
125
135
  lastInitiatedAt: event.createdAt,
126
- status: 'pending',
127
- access: 'unknown',
136
+ status: nextStatus,
137
+ access: nextAccess,
128
138
  },
129
139
  }
130
140
  },
package/src/api/index.ts CHANGED
@@ -95,6 +95,8 @@ export * as blobResolver from './blob-resolver'
95
95
 
96
96
  export * as external from './external'
97
97
 
98
+ export * as sitemap from './sitemap'
99
+
98
100
  export default function (server: Server, ctx: AppContext) {
99
101
  // app.bsky
100
102
  getTimeline(server, ctx)
@@ -0,0 +1,76 @@
1
+ import { Readable } from 'node:stream'
2
+ import { Timestamp } from '@bufbuild/protobuf'
3
+ import { Code, ConnectError } from '@connectrpc/connect'
4
+ import express, { RequestHandler, Router } from 'express'
5
+ import { AppContext } from '../context'
6
+ import { httpLogger as log } from '../logger'
7
+ import { SitemapPageType } from '../proto/bsky_pb'
8
+
9
+ export const createRouter = (ctx: AppContext): Router => {
10
+ const router = Router()
11
+ router.get('/external/sitemap/users.xml.gz', userIndexHandler(ctx))
12
+ router.get(
13
+ '/external/sitemap/users/:date/:bucket.xml.gz',
14
+ userPageHandler(ctx),
15
+ )
16
+ return router
17
+ }
18
+
19
+ const userIndexHandler =
20
+ (ctx: AppContext): RequestHandler =>
21
+ async (_req: express.Request, res: express.Response) => {
22
+ try {
23
+ const result = await ctx.dataplane.getSitemapIndex({
24
+ type: SitemapPageType.USER,
25
+ })
26
+ res.set('Content-Type', 'application/gzip')
27
+ res.set('Content-Encoding', 'gzip')
28
+ Readable.from(Buffer.from(result.sitemap)).pipe(res)
29
+ } catch (err) {
30
+ log.error({ err }, 'failed to get sitemap index')
31
+ return res.status(500).send('Internal Server Error')
32
+ }
33
+ }
34
+
35
+ const userPageHandler =
36
+ (ctx: AppContext): RequestHandler =>
37
+ async (req: express.Request, res: express.Response) => {
38
+ const { date, bucket } = req.params
39
+
40
+ // Parse date (YYYY-MM-DD format)
41
+ const dateParts = date.split('-')
42
+ if (dateParts.length !== 3) {
43
+ return res.status(400).send('Invalid date format. Expected YYYY-MM-DD')
44
+ }
45
+
46
+ const year = parseInt(dateParts[0], 10)
47
+ const month = parseInt(dateParts[1], 10)
48
+ const day = parseInt(dateParts[2], 10)
49
+
50
+ if (isNaN(year) || isNaN(month) || isNaN(day)) {
51
+ return res.status(400).send('Invalid date format. Expected YYYY-MM-DD')
52
+ }
53
+
54
+ // Parse bucket (1-indexed)
55
+ const bucketNum = parseInt(bucket, 10)
56
+ if (isNaN(bucketNum) || bucketNum < 1) {
57
+ return res.status(400).send('Invalid bucket number')
58
+ }
59
+
60
+ try {
61
+ const result = await ctx.dataplane.getSitemapPage({
62
+ type: SitemapPageType.USER,
63
+ date: Timestamp.fromDate(new Date(year, month - 1, day)),
64
+ bucket: bucketNum,
65
+ })
66
+ res.set('Content-Type', 'application/gzip')
67
+ res.set('Content-Encoding', 'gzip')
68
+ Readable.from(Buffer.from(result.sitemap)).pipe(res)
69
+ } catch (err) {
70
+ if (err instanceof ConnectError && err.code === Code.NotFound) {
71
+ return res.status(404).send('Sitemap page not found')
72
+ }
73
+ log.error({ err }, 'failed to get sitemap page')
74
+ return res.status(500).send('Internal Server Error')
75
+ }
76
+ }
@@ -22,6 +22,7 @@ import records from './records'
22
22
  import relationships from './relationships'
23
23
  import reposts from './reposts'
24
24
  import search from './search'
25
+ import sitemap from './sitemap'
25
26
  import starterPacks from './starter-packs'
26
27
  import suggestions from './suggestions'
27
28
  import sync from './sync'
@@ -50,6 +51,7 @@ export default (db: Database, idResolver: IdResolver) =>
50
51
  ...relationships(db),
51
52
  ...reposts(db),
52
53
  ...search(db),
54
+ ...sitemap(),
53
55
  ...suggestions(db),
54
56
  ...sync(db),
55
57
  ...threads(db),
@@ -136,12 +136,14 @@ export default (db: Database): Partial<ServiceImpl<typeof Service>> => ({
136
136
 
137
137
  const status = row?.ageAssuranceStatus ?? 'unknown'
138
138
  let access = row?.ageAssuranceAccess
139
- if (status === 'assured') {
140
- access = 'full'
141
- } else if (status === 'blocked') {
142
- access = 'none'
143
- } else {
144
- access = 'unknown'
139
+ if (!access || access === 'unknown') {
140
+ if (status === 'assured') {
141
+ access = 'full'
142
+ } else if (status === 'blocked') {
143
+ access = 'none'
144
+ } else {
145
+ access = 'unknown'
146
+ }
145
147
  }
146
148
 
147
149
  return {
@@ -0,0 +1,43 @@
1
+ import { gzipSync } from 'node:zlib'
2
+ import { Code, ConnectError, ServiceImpl } from '@connectrpc/connect'
3
+ import { Service } from '../../../proto/bsky_connect'
4
+ import { GetSitemapPageRequest } from '../../../proto/bsky_pb'
5
+
6
+ const MOCK_SITEMAP_INDEX = `<?xml version="1.0" encoding="UTF-8"?>
7
+ <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
8
+ <sitemap>
9
+ <loc>https://bsky.app/sitemap/users/2025-01-01/1.xml.gz</loc>
10
+ </sitemap>
11
+ </sitemapindex>`
12
+
13
+ const MOCK_SITEMAP_PAGE = `<?xml version="1.0" encoding="UTF-8"?>
14
+ <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
15
+ <url>
16
+ <loc>https://bsky.app/profile/test.bsky.social</loc>
17
+ </url>
18
+ </urlset>`
19
+
20
+ export default (): Partial<ServiceImpl<typeof Service>> => ({
21
+ async getSitemapIndex() {
22
+ return {
23
+ sitemap: gzipSync(Buffer.from(MOCK_SITEMAP_INDEX)),
24
+ }
25
+ },
26
+ async getSitemapPage(req: GetSitemapPageRequest) {
27
+ const date = req.date?.toDate()
28
+ const isExpectedDate =
29
+ date &&
30
+ date.getFullYear() === 2025 &&
31
+ date.getMonth() === 0 &&
32
+ date.getDate() === 1
33
+ const isExpectedBucket = req.bucket === 1
34
+
35
+ if (!isExpectedDate || !isExpectedBucket) {
36
+ throw new ConnectError('Sitemap page not found', Code.NotFound)
37
+ }
38
+
39
+ return {
40
+ sitemap: gzipSync(Buffer.from(MOCK_SITEMAP_PAGE)),
41
+ }
42
+ },
43
+ })
package/src/index.ts CHANGED
@@ -10,7 +10,7 @@ import { AtpAgent } from '@atproto/api'
10
10
  import { DAY, SECOND } from '@atproto/common'
11
11
  import { Keypair } from '@atproto/crypto'
12
12
  import { IdResolver } from '@atproto/identity'
13
- import API, { blobResolver, external, health, wellKnown } from './api'
13
+ import API, { blobResolver, external, health, sitemap, wellKnown } from './api'
14
14
  import { createBlobDispatcher } from './api/blob-dispatcher'
15
15
  import { AuthVerifier, createPublicKeyObject } from './auth-verifier'
16
16
  import { authWithApiKey as bsyncAuth, createBsyncClient } from './bsync'
@@ -225,6 +225,11 @@ export class BskyAppView {
225
225
  app.use(wellKnown.createRouter(ctx))
226
226
  app.use(blobResolver.createMiddleware(ctx))
227
227
  app.use(imageServer.createMiddleware(ctx, { prefix: '/img/' }))
228
+
229
+ if (config.dataplaneUrls.length > 0 || config.dataplaneUrlsEtcdKeyPrefix) {
230
+ app.use(sitemap.createRouter(ctx))
231
+ }
232
+
228
233
  app.use(server.xrpc.router)
229
234
  app.use(error.handler)
230
235
  app.use('/external', external.createRouter(ctx))
@@ -6803,6 +6803,7 @@ export const schemaDict = {
6803
6803
  'like-via-repost',
6804
6804
  'repost-via-repost',
6805
6805
  'subscribed-post',
6806
+ 'contact-match',
6806
6807
  ],
6807
6808
  },
6808
6809
  reasonSubject: {
@@ -67,6 +67,7 @@ export interface Notification {
67
67
  | 'like-via-repost'
68
68
  | 'repost-via-repost'
69
69
  | 'subscribed-post'
70
+ | 'contact-match'
70
71
  | (string & {})
71
72
  reasonSubject?: string
72
73
  record: { [_ in string]: unknown }
@@ -3,7 +3,7 @@
3
3
  /* eslint-disable */
4
4
  // @ts-nocheck
5
5
 
6
- import { ClearActorMutelistSubscriptionsRequest, ClearActorMutelistSubscriptionsResponse, ClearActorMutesRequest, ClearActorMutesResponse, ClearThreadMutesRequest, ClearThreadMutesResponse, CreateActorMutelistSubscriptionRequest, CreateActorMutelistSubscriptionResponse, CreateActorMuteRequest, CreateActorMuteResponse, CreateThreadMuteRequest, CreateThreadMuteResponse, DeleteActorMutelistSubscriptionRequest, DeleteActorMutelistSubscriptionResponse, DeleteActorMuteRequest, DeleteActorMuteResponse, DeleteThreadMuteRequest, DeleteThreadMuteResponse, GetActivitySubscriptionDidsRequest, GetActivitySubscriptionDidsResponse, GetActivitySubscriptionsByActorAndSubjectsRequest, GetActivitySubscriptionsByActorAndSubjectsResponse, GetActorBookmarksRequest, GetActorBookmarksResponse, GetActorChatDeclarationRecordsRequest, GetActorChatDeclarationRecordsResponse, GetActorFeedsRequest, GetActorFeedsResponse, GetActorFollowsActorsRequest, GetActorFollowsActorsResponse, GetActorLikesRequest, GetActorLikesResponse, GetActorListsRequest, GetActorListsResponse, GetActorMutesActorRequest, GetActorMutesActorResponse, GetActorMutesActorViaListRequest, GetActorMutesActorViaListResponse, GetActorRepostsRequest, GetActorRepostsResponse, GetActorsRequest, GetActorsResponse, GetActorStarterPacksRequest, GetActorStarterPacksResponse, GetActorTakedownRequest, GetActorTakedownResponse, GetAllLabelersRequest, GetAllLabelersResponse, GetAuthorFeedRequest, GetAuthorFeedResponse, GetBidirectionalBlockRequest, GetBidirectionalBlockResponse, GetBidirectionalBlockViaListRequest, GetBidirectionalBlockViaListResponse, GetBlobTakedownRequest, GetBlobTakedownResponse, GetBlockExistenceRequest, GetBlockExistenceResponse, GetBlocklistSubscriptionRequest, GetBlocklistSubscriptionResponse, GetBlocklistSubscriptionsRequest, GetBlocklistSubscriptionsResponse, GetBlockRecordsRequest, GetBlockRecordsResponse, GetBlocksRequest, GetBlocksResponse, GetBookmarksByActorAndSubjectsRequest, GetBookmarksByActorAndSubjectsResponse, GetCountsForUsersRequest, GetCountsForUsersResponse, GetDidsByHandlesRequest, GetDidsByHandlesResponse, GetFeedGeneratorRecordsRequest, GetFeedGeneratorRecordsResponse, GetFeedGeneratorStatusRequest, GetFeedGeneratorStatusResponse, GetFollowersRequest, GetFollowersResponse, GetFollowRecordsRequest, GetFollowRecordsResponse, GetFollowsFollowingRequest, GetFollowsFollowingResponse, GetFollowsRequest, GetFollowsResponse, GetFollowSuggestionsRequest, GetFollowSuggestionsResponse, GetIdentityByDidRequest, GetIdentityByDidResponse, GetIdentityByHandleRequest, GetIdentityByHandleResponse, GetInteractionCountsRequest, GetInteractionCountsResponse, GetLabelerRecordsRequest, GetLabelerRecordsResponse, GetLabelsRequest, GetLabelsResponse, GetLatestRevRequest, GetLatestRevResponse, GetLikeRecordsRequest, GetLikeRecordsResponse, GetLikesByActorAndSubjectsRequest, GetLikesByActorAndSubjectsResponse, GetLikesBySubjectRequest, GetLikesBySubjectResponse, GetLikesBySubjectSortedRequest, GetLikesBySubjectSortedResponse, GetListBlockRecordsRequest, GetListBlockRecordsResponse, GetListCountRequest, GetListCountResponse, GetListCountsRequest, GetListCountsResponse, GetListFeedRequest, GetListFeedResponse, GetListItemRecordsRequest, GetListItemRecordsResponse, GetListMembershipRequest, GetListMembershipResponse, GetListMembersRequest, GetListMembersResponse, GetListRecordsRequest, GetListRecordsResponse, GetMutelistSubscriptionRequest, GetMutelistSubscriptionResponse, GetMutelistSubscriptionsRequest, GetMutelistSubscriptionsResponse, GetMutesRequest, GetMutesResponse, GetNewUserCountForRangeRequest, GetNewUserCountForRangeResponse, GetNotificationDeclarationRecordsRequest, GetNotificationDeclarationRecordsResponse, GetNotificationPreferencesRequest, GetNotificationPreferencesResponse, GetNotificationSeenRequest, GetNotificationSeenResponse, GetNotificationsRequest, GetNotificationsResponse, GetPostgateRecordsRequest, GetPostgateRecordsResponse, GetPostRecordsRequest, GetPostRecordsResponse, GetProfileRecordsRequest, GetProfileRecordsResponse, GetQuotesBySubjectSortedRequest, GetQuotesBySubjectSortedResponse, GetRecordTakedownRequest, GetRecordTakedownResponse, GetRelationshipsRequest, GetRelationshipsResponse, GetRepostRecordsRequest, GetRepostRecordsResponse, GetRepostsByActorAndSubjectsRequest, GetRepostsByActorAndSubjectsResponse, GetRepostsBySubjectRequest, GetRepostsBySubjectResponse, GetStarterPackCountsRequest, GetStarterPackCountsResponse, GetStarterPackRecordsRequest, GetStarterPackRecordsResponse, GetStatusRecordsRequest, GetStatusRecordsResponse, GetSuggestedEntitiesRequest, GetSuggestedEntitiesResponse, GetSuggestedFeedsRequest, GetSuggestedFeedsResponse, GetThreadGateRecordsRequest, GetThreadGateRecordsResponse, GetThreadMutesOnSubjectsRequest, GetThreadMutesOnSubjectsResponse, GetThreadRequest, GetThreadResponse, GetTimelineRequest, GetTimelineResponse, GetUnreadNotificationCountRequest, GetUnreadNotificationCountResponse, GetVerificationRecordsRequest, GetVerificationRecordsResponse, GetVerificationsIssuedRequest, GetVerificationsIssuedResponse, GetVerificationsReceivedRequest, GetVerificationsReceivedResponse, PingRequest, PingResponse, SearchActorsRequest, SearchActorsResponse, SearchFeedGeneratorsRequest, SearchFeedGeneratorsResponse, SearchPostsRequest, SearchPostsResponse, SearchStarterPacksRequest, SearchStarterPacksResponse, TakedownActorRequest, TakedownActorResponse, TakedownBlobRequest, TakedownBlobResponse, TakedownRecordRequest, TakedownRecordResponse, UntakedownActorRequest, UntakedownActorResponse, UntakedownBlobRequest, UntakedownBlobResponse, UntakedownRecordRequest, UntakedownRecordResponse, UpdateActorUpstreamStatusRequest, UpdateActorUpstreamStatusResponse, UpdateNotificationSeenRequest, UpdateNotificationSeenResponse } from "./bsky_pb";
6
+ import { ClearActorMutelistSubscriptionsRequest, ClearActorMutelistSubscriptionsResponse, ClearActorMutesRequest, ClearActorMutesResponse, ClearThreadMutesRequest, ClearThreadMutesResponse, CreateActorMutelistSubscriptionRequest, CreateActorMutelistSubscriptionResponse, CreateActorMuteRequest, CreateActorMuteResponse, CreateThreadMuteRequest, CreateThreadMuteResponse, DeleteActorMutelistSubscriptionRequest, DeleteActorMutelistSubscriptionResponse, DeleteActorMuteRequest, DeleteActorMuteResponse, DeleteThreadMuteRequest, DeleteThreadMuteResponse, GetActivitySubscriptionDidsRequest, GetActivitySubscriptionDidsResponse, GetActivitySubscriptionsByActorAndSubjectsRequest, GetActivitySubscriptionsByActorAndSubjectsResponse, GetActorBookmarksRequest, GetActorBookmarksResponse, GetActorChatDeclarationRecordsRequest, GetActorChatDeclarationRecordsResponse, GetActorFeedsRequest, GetActorFeedsResponse, GetActorFollowsActorsRequest, GetActorFollowsActorsResponse, GetActorLikesRequest, GetActorLikesResponse, GetActorListsRequest, GetActorListsResponse, GetActorMutesActorRequest, GetActorMutesActorResponse, GetActorMutesActorViaListRequest, GetActorMutesActorViaListResponse, GetActorRepostsRequest, GetActorRepostsResponse, GetActorsRequest, GetActorsResponse, GetActorStarterPacksRequest, GetActorStarterPacksResponse, GetActorTakedownRequest, GetActorTakedownResponse, GetAllLabelersRequest, GetAllLabelersResponse, GetAuthorFeedRequest, GetAuthorFeedResponse, GetBidirectionalBlockRequest, GetBidirectionalBlockResponse, GetBidirectionalBlockViaListRequest, GetBidirectionalBlockViaListResponse, GetBlobTakedownRequest, GetBlobTakedownResponse, GetBlockExistenceRequest, GetBlockExistenceResponse, GetBlocklistSubscriptionRequest, GetBlocklistSubscriptionResponse, GetBlocklistSubscriptionsRequest, GetBlocklistSubscriptionsResponse, GetBlockRecordsRequest, GetBlockRecordsResponse, GetBlocksRequest, GetBlocksResponse, GetBookmarksByActorAndSubjectsRequest, GetBookmarksByActorAndSubjectsResponse, GetCountsForUsersRequest, GetCountsForUsersResponse, GetDidsByHandlesRequest, GetDidsByHandlesResponse, GetFeedGeneratorRecordsRequest, GetFeedGeneratorRecordsResponse, GetFeedGeneratorStatusRequest, GetFeedGeneratorStatusResponse, GetFollowersRequest, GetFollowersResponse, GetFollowRecordsRequest, GetFollowRecordsResponse, GetFollowsFollowingRequest, GetFollowsFollowingResponse, GetFollowsRequest, GetFollowsResponse, GetFollowSuggestionsRequest, GetFollowSuggestionsResponse, GetIdentityByDidRequest, GetIdentityByDidResponse, GetIdentityByHandleRequest, GetIdentityByHandleResponse, GetInteractionCountsRequest, GetInteractionCountsResponse, GetLabelerRecordsRequest, GetLabelerRecordsResponse, GetLabelsRequest, GetLabelsResponse, GetLatestRevRequest, GetLatestRevResponse, GetLikeRecordsRequest, GetLikeRecordsResponse, GetLikesByActorAndSubjectsRequest, GetLikesByActorAndSubjectsResponse, GetLikesBySubjectRequest, GetLikesBySubjectResponse, GetLikesBySubjectSortedRequest, GetLikesBySubjectSortedResponse, GetListBlockRecordsRequest, GetListBlockRecordsResponse, GetListCountRequest, GetListCountResponse, GetListCountsRequest, GetListCountsResponse, GetListFeedRequest, GetListFeedResponse, GetListItemRecordsRequest, GetListItemRecordsResponse, GetListMembershipRequest, GetListMembershipResponse, GetListMembersRequest, GetListMembersResponse, GetListRecordsRequest, GetListRecordsResponse, GetMutelistSubscriptionRequest, GetMutelistSubscriptionResponse, GetMutelistSubscriptionsRequest, GetMutelistSubscriptionsResponse, GetMutesRequest, GetMutesResponse, GetNewUserCountForRangeRequest, GetNewUserCountForRangeResponse, GetNotificationDeclarationRecordsRequest, GetNotificationDeclarationRecordsResponse, GetNotificationPreferencesRequest, GetNotificationPreferencesResponse, GetNotificationSeenRequest, GetNotificationSeenResponse, GetNotificationsRequest, GetNotificationsResponse, GetPostgateRecordsRequest, GetPostgateRecordsResponse, GetPostRecordsRequest, GetPostRecordsResponse, GetProfileRecordsRequest, GetProfileRecordsResponse, GetQuotesBySubjectSortedRequest, GetQuotesBySubjectSortedResponse, GetRecordTakedownRequest, GetRecordTakedownResponse, GetRelationshipsRequest, GetRelationshipsResponse, GetRepostRecordsRequest, GetRepostRecordsResponse, GetRepostsByActorAndSubjectsRequest, GetRepostsByActorAndSubjectsResponse, GetRepostsBySubjectRequest, GetRepostsBySubjectResponse, GetSitemapIndexRequest, GetSitemapIndexResponse, GetSitemapPageRequest, GetSitemapPageResponse, GetStarterPackCountsRequest, GetStarterPackCountsResponse, GetStarterPackRecordsRequest, GetStarterPackRecordsResponse, GetStatusRecordsRequest, GetStatusRecordsResponse, GetSuggestedEntitiesRequest, GetSuggestedEntitiesResponse, GetSuggestedFeedsRequest, GetSuggestedFeedsResponse, GetThreadGateRecordsRequest, GetThreadGateRecordsResponse, GetThreadMutesOnSubjectsRequest, GetThreadMutesOnSubjectsResponse, GetThreadRequest, GetThreadResponse, GetTimelineRequest, GetTimelineResponse, GetUnreadNotificationCountRequest, GetUnreadNotificationCountResponse, GetVerificationRecordsRequest, GetVerificationRecordsResponse, GetVerificationsIssuedRequest, GetVerificationsIssuedResponse, GetVerificationsReceivedRequest, GetVerificationsReceivedResponse, PingRequest, PingResponse, SearchActorsRequest, SearchActorsResponse, SearchFeedGeneratorsRequest, SearchFeedGeneratorsResponse, SearchPostsRequest, SearchPostsResponse, SearchStarterPacksRequest, SearchStarterPacksResponse, TakedownActorRequest, TakedownActorResponse, TakedownBlobRequest, TakedownBlobResponse, TakedownRecordRequest, TakedownRecordResponse, UntakedownActorRequest, UntakedownActorResponse, UntakedownBlobRequest, UntakedownBlobResponse, UntakedownRecordRequest, UntakedownRecordResponse, UpdateActorUpstreamStatusRequest, UpdateActorUpstreamStatusResponse, UpdateNotificationSeenRequest, UpdateNotificationSeenResponse } from "./bsky_pb";
7
7
  import { MethodKind } from "@bufbuild/protobuf";
8
8
 
9
9
  /**
@@ -858,6 +858,26 @@ export const Service = {
858
858
  O: GetFollowsFollowingResponse,
859
859
  kind: MethodKind.Unary,
860
860
  },
861
+ /**
862
+ * Sitemaps
863
+ *
864
+ * @generated from rpc bsky.Service.GetSitemapIndex
865
+ */
866
+ getSitemapIndex: {
867
+ name: "GetSitemapIndex",
868
+ I: GetSitemapIndexRequest,
869
+ O: GetSitemapIndexResponse,
870
+ kind: MethodKind.Unary,
871
+ },
872
+ /**
873
+ * @generated from rpc bsky.Service.GetSitemapPage
874
+ */
875
+ getSitemapPage: {
876
+ name: "GetSitemapPage",
877
+ I: GetSitemapPageRequest,
878
+ O: GetSitemapPageResponse,
879
+ kind: MethodKind.Unary,
880
+ },
861
881
  /**
862
882
  * Ping
863
883
  *
@@ -96,6 +96,26 @@ proto3.util.setEnumType(FeedType, "bsky.FeedType", [
96
96
  { no: 4, name: "FEED_TYPE_POSTS_WITH_VIDEO" },
97
97
  ]);
98
98
 
99
+ /**
100
+ * @generated from enum bsky.SitemapPageType
101
+ */
102
+ export enum SitemapPageType {
103
+ /**
104
+ * @generated from enum value: SITEMAP_PAGE_TYPE_UNSPECIFIED = 0;
105
+ */
106
+ UNSPECIFIED = 0,
107
+
108
+ /**
109
+ * @generated from enum value: SITEMAP_PAGE_TYPE_USER = 1;
110
+ */
111
+ USER = 1,
112
+ }
113
+ // Retrieve enum metadata with: proto3.getEnumType(SitemapPageType)
114
+ proto3.util.setEnumType(SitemapPageType, "bsky.SitemapPageType", [
115
+ { no: 0, name: "SITEMAP_PAGE_TYPE_UNSPECIFIED" },
116
+ { no: 1, name: "SITEMAP_PAGE_TYPE_USER" },
117
+ ]);
118
+
99
119
  /**
100
120
  * @generated from message bsky.Record
101
121
  */
@@ -9391,6 +9411,174 @@ export class GetFollowsFollowingResponse extends Message<GetFollowsFollowingResp
9391
9411
  }
9392
9412
  }
9393
9413
 
9414
+ /**
9415
+ * @generated from message bsky.GetSitemapIndexRequest
9416
+ */
9417
+ export class GetSitemapIndexRequest extends Message<GetSitemapIndexRequest> {
9418
+ /**
9419
+ * @generated from field: bsky.SitemapPageType type = 1;
9420
+ */
9421
+ type = SitemapPageType.UNSPECIFIED;
9422
+
9423
+ constructor(data?: PartialMessage<GetSitemapIndexRequest>) {
9424
+ super();
9425
+ proto3.util.initPartial(data, this);
9426
+ }
9427
+
9428
+ static readonly runtime: typeof proto3 = proto3;
9429
+ static readonly typeName = "bsky.GetSitemapIndexRequest";
9430
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
9431
+ { no: 1, name: "type", kind: "enum", T: proto3.getEnumType(SitemapPageType) },
9432
+ ]);
9433
+
9434
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetSitemapIndexRequest {
9435
+ return new GetSitemapIndexRequest().fromBinary(bytes, options);
9436
+ }
9437
+
9438
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetSitemapIndexRequest {
9439
+ return new GetSitemapIndexRequest().fromJson(jsonValue, options);
9440
+ }
9441
+
9442
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetSitemapIndexRequest {
9443
+ return new GetSitemapIndexRequest().fromJsonString(jsonString, options);
9444
+ }
9445
+
9446
+ static equals(a: GetSitemapIndexRequest | PlainMessage<GetSitemapIndexRequest> | undefined, b: GetSitemapIndexRequest | PlainMessage<GetSitemapIndexRequest> | undefined): boolean {
9447
+ return proto3.util.equals(GetSitemapIndexRequest, a, b);
9448
+ }
9449
+ }
9450
+
9451
+ /**
9452
+ * @generated from message bsky.GetSitemapIndexResponse
9453
+ */
9454
+ export class GetSitemapIndexResponse extends Message<GetSitemapIndexResponse> {
9455
+ /**
9456
+ * GZIP compressed XML sitemap
9457
+ *
9458
+ * @generated from field: bytes sitemap = 1;
9459
+ */
9460
+ sitemap = new Uint8Array(0);
9461
+
9462
+ constructor(data?: PartialMessage<GetSitemapIndexResponse>) {
9463
+ super();
9464
+ proto3.util.initPartial(data, this);
9465
+ }
9466
+
9467
+ static readonly runtime: typeof proto3 = proto3;
9468
+ static readonly typeName = "bsky.GetSitemapIndexResponse";
9469
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
9470
+ { no: 1, name: "sitemap", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
9471
+ ]);
9472
+
9473
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetSitemapIndexResponse {
9474
+ return new GetSitemapIndexResponse().fromBinary(bytes, options);
9475
+ }
9476
+
9477
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetSitemapIndexResponse {
9478
+ return new GetSitemapIndexResponse().fromJson(jsonValue, options);
9479
+ }
9480
+
9481
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetSitemapIndexResponse {
9482
+ return new GetSitemapIndexResponse().fromJsonString(jsonString, options);
9483
+ }
9484
+
9485
+ static equals(a: GetSitemapIndexResponse | PlainMessage<GetSitemapIndexResponse> | undefined, b: GetSitemapIndexResponse | PlainMessage<GetSitemapIndexResponse> | undefined): boolean {
9486
+ return proto3.util.equals(GetSitemapIndexResponse, a, b);
9487
+ }
9488
+ }
9489
+
9490
+ /**
9491
+ * Sitemap HTTP paths are typically of the form `/type/yyyy-mm-dd/N.xml.gz`, i.e. `/users/2025-01-01/1.xml.gz`
9492
+ *
9493
+ * @generated from message bsky.GetSitemapPageRequest
9494
+ */
9495
+ export class GetSitemapPageRequest extends Message<GetSitemapPageRequest> {
9496
+ /**
9497
+ * @generated from field: bsky.SitemapPageType type = 1;
9498
+ */
9499
+ type = SitemapPageType.UNSPECIFIED;
9500
+
9501
+ /**
9502
+ * @generated from field: google.protobuf.Timestamp date = 2;
9503
+ */
9504
+ date?: Timestamp;
9505
+
9506
+ /**
9507
+ * One-indexed
9508
+ *
9509
+ * @generated from field: int32 bucket = 3;
9510
+ */
9511
+ bucket = 0;
9512
+
9513
+ constructor(data?: PartialMessage<GetSitemapPageRequest>) {
9514
+ super();
9515
+ proto3.util.initPartial(data, this);
9516
+ }
9517
+
9518
+ static readonly runtime: typeof proto3 = proto3;
9519
+ static readonly typeName = "bsky.GetSitemapPageRequest";
9520
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
9521
+ { no: 1, name: "type", kind: "enum", T: proto3.getEnumType(SitemapPageType) },
9522
+ { no: 2, name: "date", kind: "message", T: Timestamp },
9523
+ { no: 3, name: "bucket", kind: "scalar", T: 5 /* ScalarType.INT32 */ },
9524
+ ]);
9525
+
9526
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetSitemapPageRequest {
9527
+ return new GetSitemapPageRequest().fromBinary(bytes, options);
9528
+ }
9529
+
9530
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetSitemapPageRequest {
9531
+ return new GetSitemapPageRequest().fromJson(jsonValue, options);
9532
+ }
9533
+
9534
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetSitemapPageRequest {
9535
+ return new GetSitemapPageRequest().fromJsonString(jsonString, options);
9536
+ }
9537
+
9538
+ static equals(a: GetSitemapPageRequest | PlainMessage<GetSitemapPageRequest> | undefined, b: GetSitemapPageRequest | PlainMessage<GetSitemapPageRequest> | undefined): boolean {
9539
+ return proto3.util.equals(GetSitemapPageRequest, a, b);
9540
+ }
9541
+ }
9542
+
9543
+ /**
9544
+ * @generated from message bsky.GetSitemapPageResponse
9545
+ */
9546
+ export class GetSitemapPageResponse extends Message<GetSitemapPageResponse> {
9547
+ /**
9548
+ * GZIP compressed XML sitemap
9549
+ *
9550
+ * @generated from field: bytes sitemap = 1;
9551
+ */
9552
+ sitemap = new Uint8Array(0);
9553
+
9554
+ constructor(data?: PartialMessage<GetSitemapPageResponse>) {
9555
+ super();
9556
+ proto3.util.initPartial(data, this);
9557
+ }
9558
+
9559
+ static readonly runtime: typeof proto3 = proto3;
9560
+ static readonly typeName = "bsky.GetSitemapPageResponse";
9561
+ static readonly fields: FieldList = proto3.util.newFieldList(() => [
9562
+ { no: 1, name: "sitemap", kind: "scalar", T: 12 /* ScalarType.BYTES */ },
9563
+ ]);
9564
+
9565
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetSitemapPageResponse {
9566
+ return new GetSitemapPageResponse().fromBinary(bytes, options);
9567
+ }
9568
+
9569
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetSitemapPageResponse {
9570
+ return new GetSitemapPageResponse().fromJson(jsonValue, options);
9571
+ }
9572
+
9573
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetSitemapPageResponse {
9574
+ return new GetSitemapPageResponse().fromJsonString(jsonString, options);
9575
+ }
9576
+
9577
+ static equals(a: GetSitemapPageResponse | PlainMessage<GetSitemapPageResponse> | undefined, b: GetSitemapPageResponse | PlainMessage<GetSitemapPageResponse> | undefined): boolean {
9578
+ return proto3.util.equals(GetSitemapPageResponse, a, b);
9579
+ }
9580
+ }
9581
+
9394
9582
  /**
9395
9583
  * Ping
9396
9584
  *