@atproto/api 0.6.1 → 0.6.2
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.
- package/dist/agent.d.ts +25 -44
- package/dist/bsky-agent.d.ts +43 -62
- package/dist/client/lexicons.d.ts +18 -0
- package/dist/client/types/app/bsky/actor/createScene.d.ts +32 -0
- package/dist/client/types/app/bsky/actor/defs.d.ts +65 -74
- package/dist/client/types/app/bsky/actor/ref.d.ts +28 -0
- package/dist/client/types/app/bsky/actor/search.d.ts +22 -0
- package/dist/client/types/app/bsky/actor/searchTypeahead.d.ts +20 -0
- package/dist/client/types/app/bsky/actor/updateProfile.d.ts +40 -0
- package/dist/client/types/app/bsky/embed/external.d.ts +23 -23
- package/dist/client/types/app/bsky/embed/images.d.ts +20 -20
- package/dist/client/types/app/bsky/embed/record.d.ts +41 -53
- package/dist/client/types/app/bsky/embed/recordWithMedia.d.ts +20 -26
- package/dist/client/types/app/bsky/feed/defs.d.ts +115 -141
- package/dist/client/types/app/bsky/feed/feedViewPost.d.ts +28 -0
- package/dist/client/types/app/bsky/feed/getSavedFeeds.d.ts +21 -0
- package/dist/client/types/app/bsky/feed/getVotes.d.ts +36 -0
- package/dist/client/types/app/bsky/feed/like.d.ts +7 -7
- package/dist/client/types/app/bsky/feed/repost.d.ts +7 -7
- package/dist/client/types/app/bsky/feed/saveFeed.d.ts +17 -0
- package/dist/client/types/app/bsky/feed/setVote.d.ts +25 -0
- package/dist/client/types/app/bsky/feed/trend.d.ts +9 -0
- package/dist/client/types/app/bsky/feed/unsaveFeed.d.ts +17 -0
- package/dist/client/types/app/bsky/feed/vote.d.ts +10 -0
- package/dist/client/types/app/bsky/graph/assertCreator.d.ts +1 -0
- package/dist/client/types/app/bsky/graph/assertMember.d.ts +1 -0
- package/dist/client/types/app/bsky/graph/assertion.d.ts +10 -0
- package/dist/client/types/app/bsky/graph/block.d.ts +6 -6
- package/dist/client/types/app/bsky/graph/confirmation.d.ts +11 -0
- package/dist/client/types/app/bsky/graph/defs.d.ts +36 -36
- package/dist/client/types/app/bsky/graph/follow.d.ts +6 -6
- package/dist/client/types/app/bsky/graph/getAssertions.d.ts +48 -0
- package/dist/client/types/app/bsky/graph/getListBlocks.d.ts +21 -0
- package/dist/client/types/app/bsky/graph/getMembers.d.ts +36 -0
- package/dist/client/types/app/bsky/graph/getMemberships.d.ts +36 -0
- package/dist/client/types/app/bsky/graph/listblock.d.ts +8 -0
- package/dist/client/types/app/bsky/graph/listitem.d.ts +7 -7
- package/dist/client/types/app/bsky/graph/mute.d.ts +17 -0
- package/dist/client/types/app/bsky/graph/subscribeMuteList.d.ts +17 -0
- package/dist/client/types/app/bsky/graph/unmute.d.ts +17 -0
- package/dist/client/types/app/bsky/graph/unsubscribeMuteList.d.ts +17 -0
- package/dist/client/types/app/bsky/notification/getCount.d.ts +17 -0
- package/dist/client/types/app/bsky/notification/list.d.ts +35 -0
- package/dist/client/types/app/bsky/richtext/facet.d.ts +22 -26
- package/dist/client/types/app/bsky/system/actorScene.d.ts +1 -0
- package/dist/client/types/app/bsky/system/actorUser.d.ts +1 -0
- package/dist/client/types/app/bsky/system/declRef.d.ts +8 -0
- package/dist/client/types/app/bsky/system/declaration.d.ts +7 -0
- package/dist/client/types/com/atproto/account/create.d.ts +41 -0
- package/dist/client/types/com/atproto/account/createInviteCode.d.ts +22 -0
- package/dist/client/types/com/atproto/account/delete.d.ts +25 -0
- package/dist/client/types/com/atproto/account/get.d.ts +12 -0
- package/dist/client/types/com/atproto/account/requestDelete.d.ts +13 -0
- package/dist/client/types/com/atproto/account/requestPasswordReset.d.ts +17 -0
- package/dist/client/types/com/atproto/account/resetPassword.d.ts +24 -0
- package/dist/client/types/com/atproto/admin/blob.d.ts +37 -0
- package/dist/client/types/com/atproto/admin/moderationAction.d.ts +60 -0
- package/dist/client/types/com/atproto/admin/moderationReport.d.ts +37 -0
- package/dist/client/types/com/atproto/admin/record.d.ts +43 -0
- package/dist/client/types/com/atproto/admin/repo.d.ts +45 -0
- package/dist/client/types/com/atproto/blob/upload.d.ts +19 -0
- package/dist/client/types/com/atproto/handle/resolve.d.ts +18 -0
- package/dist/client/types/com/atproto/handle/update.d.ts +17 -0
- package/dist/client/types/com/atproto/label/subscribeLabels.d.ts +12 -12
- package/dist/client/types/com/atproto/moderation/defs.d.ts +7 -16
- package/dist/client/types/com/atproto/repo/batchWrite.d.ts +46 -0
- package/dist/client/types/com/atproto/repo/describe.d.ts +22 -0
- package/dist/client/types/com/atproto/repo/recordRef.d.ts +8 -0
- package/dist/client/types/com/atproto/repo/repoRef.d.ts +7 -0
- package/dist/client/types/com/atproto/repo/strongRef.d.ts +6 -6
- package/dist/client/types/com/atproto/report/create.d.ts +39 -0
- package/dist/client/types/com/atproto/report/reasonType.d.ts +3 -0
- package/dist/client/types/com/atproto/report/subject.d.ts +23 -0
- package/dist/client/types/com/atproto/server/defs.d.ts +16 -16
- package/dist/client/types/com/atproto/server/getAccountsConfig.d.ts +27 -0
- package/dist/client/types/com/atproto/session/create.d.ts +29 -0
- package/dist/client/types/com/atproto/session/delete.d.ts +13 -0
- package/dist/client/types/com/atproto/session/get.d.ts +18 -0
- package/dist/client/types/com/atproto/session/refresh.d.ts +24 -0
- package/dist/client/types/com/atproto/sync/getRoot.d.ts +18 -0
- package/dist/client/types/com/atproto/sync/subscribeAllRepos.d.ts +9 -0
- package/dist/client/types/com/atproto/sync/subscribeRepos.d.ts +46 -46
- package/dist/client/types/com/atproto/sync/updateRepo.d.ts +15 -0
- package/dist/client/util.d.ts +2 -5
- package/dist/helpers/bsky.d.ts +20 -0
- package/dist/index.js +69 -37
- package/dist/index.js.map +2 -2
- package/dist/mixins/bsky.d.ts +23 -0
- package/dist/rich-text/detection.d.ts +4 -4
- package/dist/rich-text/rich-text.d.ts +31 -31
- package/dist/rich-text/sanitization.d.ts +4 -7
- package/dist/rich-text/sanitize.d.ts +4 -0
- package/dist/rich-text/unicode.d.ts +9 -9
- package/dist/session.d.ts +42 -0
- package/dist/types.d.ts +22 -34
- package/package.json +1 -1
- package/src/client/lexicons.ts +19 -1
- package/src/client/types/app/bsky/feed/defs.ts +19 -0
- package/src/client/types/app/bsky/feed/getAuthorFeed.ts +2 -2
- package/src/client/types/app/bsky/feed/getFeed.ts +1 -1
- package/src/client/types/app/bsky/feed/getFeedSkeleton.ts +1 -1
- package/src/client/types/app/bsky/feed/getPostThread.ts +1 -1
- package/src/client/types/app/bsky/unspecced/getTimelineSkeleton.ts +1 -1
- package/src/client/types/com/atproto/admin/getRecord.ts +1 -1
- package/src/client/types/com/atproto/admin/getRepo.ts +1 -1
- package/src/client/types/com/atproto/admin/rebaseRepo.ts +2 -2
- package/src/client/types/com/atproto/admin/takeModerationAction.ts +1 -1
- package/src/client/types/com/atproto/repo/applyWrites.ts +1 -1
- package/src/client/types/com/atproto/repo/createRecord.ts +1 -1
- package/src/client/types/com/atproto/repo/deleteRecord.ts +1 -1
- package/src/client/types/com/atproto/repo/putRecord.ts +1 -1
- package/src/client/types/com/atproto/repo/rebaseRepo.ts +2 -2
- package/src/client/types/com/atproto/server/createAccount.ts +7 -7
- package/src/client/types/com/atproto/server/createAppPassword.ts +1 -1
- package/src/client/types/com/atproto/server/createSession.ts +1 -1
- package/src/client/types/com/atproto/server/deleteAccount.ts +2 -2
- package/src/client/types/com/atproto/server/getAccountInviteCodes.ts +1 -1
- package/src/client/types/com/atproto/server/listAppPasswords.ts +1 -1
- package/src/client/types/com/atproto/server/refreshSession.ts +1 -1
- package/src/client/types/com/atproto/server/resetPassword.ts +2 -2
- package/src/client/types/com/atproto/sync/getHead.ts +1 -1
- package/tsconfig.build.tsbuildinfo +1 -1
package/dist/agent.d.ts
CHANGED
|
@@ -1,46 +1,27 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
ComAtprotoServerCreateAccount,
|
|
4
|
-
ComAtprotoServerCreateSession,
|
|
5
|
-
ComAtprotoServerGetSession,
|
|
6
|
-
} from './client'
|
|
7
|
-
import {
|
|
8
|
-
AtpSessionData,
|
|
9
|
-
AtpAgentCreateAccountOpts,
|
|
10
|
-
AtpAgentLoginOpts,
|
|
11
|
-
AtpAgentFetchHandler,
|
|
12
|
-
AtpAgentGlobalOpts,
|
|
13
|
-
AtpPersistSessionHandler,
|
|
14
|
-
AtpAgentOpts,
|
|
15
|
-
} from './types'
|
|
1
|
+
import { AtpServiceClient, ComAtprotoServerCreateAccount, ComAtprotoServerCreateSession, ComAtprotoServerGetSession } from './client';
|
|
2
|
+
import { AtpSessionData, AtpAgentCreateAccountOpts, AtpAgentLoginOpts, AtpAgentFetchHandler, AtpAgentGlobalOpts, AtpPersistSessionHandler, AtpAgentOpts } from './types';
|
|
16
3
|
export declare class AtpAgent {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
opts:
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
private _refreshSession
|
|
41
|
-
private _refreshSessionInner
|
|
42
|
-
uploadBlob: typeof this.api.com.atproto.repo.uploadBlob
|
|
43
|
-
resolveHandle: typeof this.api.com.atproto.identity.resolveHandle
|
|
44
|
-
updateHandle: typeof this.api.com.atproto.identity.updateHandle
|
|
45
|
-
createModerationReport: typeof this.api.com.atproto.moderation.createReport
|
|
4
|
+
service: URL;
|
|
5
|
+
api: AtpServiceClient;
|
|
6
|
+
session?: AtpSessionData;
|
|
7
|
+
private _baseClient;
|
|
8
|
+
private _persistSession?;
|
|
9
|
+
private _refreshSessionPromise;
|
|
10
|
+
get com(): import("./client").ComNS;
|
|
11
|
+
static fetch: AtpAgentFetchHandler | undefined;
|
|
12
|
+
static configure(opts: AtpAgentGlobalOpts): void;
|
|
13
|
+
constructor(opts: AtpAgentOpts);
|
|
14
|
+
get hasSession(): boolean;
|
|
15
|
+
setPersistSessionHandler(handler?: AtpPersistSessionHandler): void;
|
|
16
|
+
createAccount(opts: AtpAgentCreateAccountOpts): Promise<ComAtprotoServerCreateAccount.Response>;
|
|
17
|
+
login(opts: AtpAgentLoginOpts): Promise<ComAtprotoServerCreateSession.Response>;
|
|
18
|
+
resumeSession(session: AtpSessionData): Promise<ComAtprotoServerGetSession.Response>;
|
|
19
|
+
private _addAuthHeader;
|
|
20
|
+
private _fetch;
|
|
21
|
+
private _refreshSession;
|
|
22
|
+
private _refreshSessionInner;
|
|
23
|
+
uploadBlob: typeof this.api.com.atproto.repo.uploadBlob;
|
|
24
|
+
resolveHandle: typeof this.api.com.atproto.identity.resolveHandle;
|
|
25
|
+
updateHandle: typeof this.api.com.atproto.identity.updateHandle;
|
|
26
|
+
createModerationReport: typeof this.api.com.atproto.moderation.createReport;
|
|
46
27
|
}
|
package/dist/bsky-agent.d.ts
CHANGED
|
@@ -1,64 +1,45 @@
|
|
|
1
|
-
import { AtpAgent } from './agent'
|
|
2
|
-
import { AppBskyFeedPost, AppBskyActorProfile } from './client'
|
|
1
|
+
import { AtpAgent } from './agent';
|
|
2
|
+
import { AppBskyFeedPost, AppBskyActorProfile } from './client';
|
|
3
3
|
export declare class BskyAgent extends AtpAgent {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
cid: string
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
cid: string
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
follow(subjectDid: string): Promise<{
|
|
46
|
-
uri: string
|
|
47
|
-
cid: string
|
|
48
|
-
}>
|
|
49
|
-
deleteFollow(followUri: string): Promise<void>
|
|
50
|
-
upsertProfile(
|
|
51
|
-
updateFn: (
|
|
52
|
-
existing: AppBskyActorProfile.Record | undefined,
|
|
53
|
-
) => AppBskyActorProfile.Record | Promise<AppBskyActorProfile.Record>,
|
|
54
|
-
): Promise<void>
|
|
55
|
-
mute(
|
|
56
|
-
actor: string,
|
|
57
|
-
): Promise<import('./client/types/app/bsky/graph/muteActor').Response>
|
|
58
|
-
unmute(
|
|
59
|
-
actor: string,
|
|
60
|
-
): Promise<import('./client/types/app/bsky/graph/unmuteActor').Response>
|
|
61
|
-
updateSeenNotifications(
|
|
62
|
-
seenAt?: string,
|
|
63
|
-
): Promise<import('./client/types/app/bsky/notification/updateSeen').Response>
|
|
4
|
+
get app(): import("./client").AppNS;
|
|
5
|
+
getTimeline: typeof this.api.app.bsky.feed.getTimeline;
|
|
6
|
+
getAuthorFeed: typeof this.api.app.bsky.feed.getAuthorFeed;
|
|
7
|
+
getPostThread: typeof this.api.app.bsky.feed.getPostThread;
|
|
8
|
+
getPost: typeof this.api.app.bsky.feed.post.get;
|
|
9
|
+
getPosts: typeof this.api.app.bsky.feed.getPosts;
|
|
10
|
+
getLikes: typeof this.api.app.bsky.feed.getLikes;
|
|
11
|
+
getRepostedBy: typeof this.api.app.bsky.feed.getRepostedBy;
|
|
12
|
+
getFollows: typeof this.api.app.bsky.graph.getFollows;
|
|
13
|
+
getFollowers: typeof this.api.app.bsky.graph.getFollowers;
|
|
14
|
+
getProfile: typeof this.api.app.bsky.actor.getProfile;
|
|
15
|
+
getProfiles: typeof this.api.app.bsky.actor.getProfiles;
|
|
16
|
+
getSuggestions: typeof this.api.app.bsky.actor.getSuggestions;
|
|
17
|
+
searchActors: typeof this.api.app.bsky.actor.searchActors;
|
|
18
|
+
searchActorsTypeahead: typeof this.api.app.bsky.actor.searchActorsTypeahead;
|
|
19
|
+
listNotifications: typeof this.api.app.bsky.notification.listNotifications;
|
|
20
|
+
countUnreadNotifications: typeof this.api.app.bsky.notification.getUnreadCount;
|
|
21
|
+
post(record: Partial<AppBskyFeedPost.Record> & Omit<AppBskyFeedPost.Record, 'createdAt'>): Promise<{
|
|
22
|
+
uri: string;
|
|
23
|
+
cid: string;
|
|
24
|
+
}>;
|
|
25
|
+
deletePost(postUri: string): Promise<void>;
|
|
26
|
+
like(uri: string, cid: string): Promise<{
|
|
27
|
+
uri: string;
|
|
28
|
+
cid: string;
|
|
29
|
+
}>;
|
|
30
|
+
deleteLike(likeUri: string): Promise<void>;
|
|
31
|
+
repost(uri: string, cid: string): Promise<{
|
|
32
|
+
uri: string;
|
|
33
|
+
cid: string;
|
|
34
|
+
}>;
|
|
35
|
+
deleteRepost(repostUri: string): Promise<void>;
|
|
36
|
+
follow(subjectDid: string): Promise<{
|
|
37
|
+
uri: string;
|
|
38
|
+
cid: string;
|
|
39
|
+
}>;
|
|
40
|
+
deleteFollow(followUri: string): Promise<void>;
|
|
41
|
+
upsertProfile(updateFn: (existing: AppBskyActorProfile.Record | undefined) => AppBskyActorProfile.Record | Promise<AppBskyActorProfile.Record>): Promise<void>;
|
|
42
|
+
mute(actor: string): Promise<import("./client/types/app/bsky/graph/muteActor").Response>;
|
|
43
|
+
unmute(actor: string): Promise<import("./client/types/app/bsky/graph/unmuteActor").Response>;
|
|
44
|
+
updateSeenNotifications(seenAt?: string): Promise<import("./client/types/app/bsky/notification/updateSeen").Response>;
|
|
64
45
|
}
|
|
@@ -4209,6 +4209,24 @@ export declare const schemaDict: {
|
|
|
4209
4209
|
type: string;
|
|
4210
4210
|
const: boolean;
|
|
4211
4211
|
};
|
|
4212
|
+
author: {
|
|
4213
|
+
type: string;
|
|
4214
|
+
ref: string;
|
|
4215
|
+
};
|
|
4216
|
+
};
|
|
4217
|
+
};
|
|
4218
|
+
blockedAuthor: {
|
|
4219
|
+
type: string;
|
|
4220
|
+
required: string[];
|
|
4221
|
+
properties: {
|
|
4222
|
+
did: {
|
|
4223
|
+
type: string;
|
|
4224
|
+
format: string;
|
|
4225
|
+
};
|
|
4226
|
+
viewer: {
|
|
4227
|
+
type: string;
|
|
4228
|
+
ref: string;
|
|
4229
|
+
};
|
|
4212
4230
|
};
|
|
4213
4231
|
};
|
|
4214
4232
|
generatorView: {
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Headers, XRPCError } from '@atproto/xrpc';
|
|
2
|
+
import * as AppBskySystemDeclRef from '../system/declRef';
|
|
3
|
+
export interface QueryParams {
|
|
4
|
+
}
|
|
5
|
+
export interface InputSchema {
|
|
6
|
+
handle: string;
|
|
7
|
+
recoveryKey?: string;
|
|
8
|
+
[k: string]: unknown;
|
|
9
|
+
}
|
|
10
|
+
export interface OutputSchema {
|
|
11
|
+
handle: string;
|
|
12
|
+
did: string;
|
|
13
|
+
declaration: AppBskySystemDeclRef.Main;
|
|
14
|
+
[k: string]: unknown;
|
|
15
|
+
}
|
|
16
|
+
export interface CallOptions {
|
|
17
|
+
headers?: Headers;
|
|
18
|
+
qp?: QueryParams;
|
|
19
|
+
encoding: 'application/json';
|
|
20
|
+
}
|
|
21
|
+
export interface Response {
|
|
22
|
+
success: boolean;
|
|
23
|
+
headers: Headers;
|
|
24
|
+
data: OutputSchema;
|
|
25
|
+
}
|
|
26
|
+
export declare class InvalidHandleError extends XRPCError {
|
|
27
|
+
constructor(src: XRPCError);
|
|
28
|
+
}
|
|
29
|
+
export declare class HandleNotAvailableError extends XRPCError {
|
|
30
|
+
constructor(src: XRPCError);
|
|
31
|
+
}
|
|
32
|
+
export declare function toKnownErr(e: any): any;
|
|
@@ -1,88 +1,79 @@
|
|
|
1
|
-
import { ValidationResult } from '@atproto/lexicon'
|
|
2
|
-
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs'
|
|
3
|
-
import * as AppBskyGraphDefs from '../graph/defs'
|
|
1
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
2
|
+
import * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs';
|
|
3
|
+
import * as AppBskyGraphDefs from '../graph/defs';
|
|
4
4
|
export interface ProfileViewBasic {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
did: string;
|
|
6
|
+
handle: string;
|
|
7
|
+
displayName?: string;
|
|
8
|
+
avatar?: string;
|
|
9
|
+
viewer?: ViewerState;
|
|
10
|
+
labels?: ComAtprotoLabelDefs.Label[];
|
|
11
|
+
[k: string]: unknown;
|
|
12
12
|
}
|
|
13
|
-
export declare function isProfileViewBasic(v: unknown): v is ProfileViewBasic
|
|
14
|
-
export declare function validateProfileViewBasic(v: unknown): ValidationResult
|
|
13
|
+
export declare function isProfileViewBasic(v: unknown): v is ProfileViewBasic;
|
|
14
|
+
export declare function validateProfileViewBasic(v: unknown): ValidationResult;
|
|
15
15
|
export interface ProfileView {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
16
|
+
did: string;
|
|
17
|
+
handle: string;
|
|
18
|
+
displayName?: string;
|
|
19
|
+
description?: string;
|
|
20
|
+
avatar?: string;
|
|
21
|
+
indexedAt?: string;
|
|
22
|
+
viewer?: ViewerState;
|
|
23
|
+
labels?: ComAtprotoLabelDefs.Label[];
|
|
24
|
+
[k: string]: unknown;
|
|
25
25
|
}
|
|
26
|
-
export declare function isProfileView(v: unknown): v is ProfileView
|
|
27
|
-
export declare function validateProfileView(v: unknown): ValidationResult
|
|
26
|
+
export declare function isProfileView(v: unknown): v is ProfileView;
|
|
27
|
+
export declare function validateProfileView(v: unknown): ValidationResult;
|
|
28
28
|
export interface ProfileViewDetailed {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
29
|
+
did: string;
|
|
30
|
+
handle: string;
|
|
31
|
+
displayName?: string;
|
|
32
|
+
description?: string;
|
|
33
|
+
avatar?: string;
|
|
34
|
+
banner?: string;
|
|
35
|
+
followersCount?: number;
|
|
36
|
+
followsCount?: number;
|
|
37
|
+
postsCount?: number;
|
|
38
|
+
indexedAt?: string;
|
|
39
|
+
viewer?: ViewerState;
|
|
40
|
+
labels?: ComAtprotoLabelDefs.Label[];
|
|
41
|
+
[k: string]: unknown;
|
|
42
42
|
}
|
|
43
|
-
export declare function isProfileViewDetailed(
|
|
44
|
-
|
|
45
|
-
): v is ProfileViewDetailed
|
|
46
|
-
export declare function validateProfileViewDetailed(
|
|
47
|
-
v: unknown,
|
|
48
|
-
): ValidationResult
|
|
43
|
+
export declare function isProfileViewDetailed(v: unknown): v is ProfileViewDetailed;
|
|
44
|
+
export declare function validateProfileViewDetailed(v: unknown): ValidationResult;
|
|
49
45
|
export interface ViewerState {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
46
|
+
muted?: boolean;
|
|
47
|
+
mutedByList?: AppBskyGraphDefs.ListViewBasic;
|
|
48
|
+
blockedBy?: boolean;
|
|
49
|
+
blocking?: string;
|
|
50
|
+
following?: string;
|
|
51
|
+
followedBy?: string;
|
|
52
|
+
[k: string]: unknown;
|
|
57
53
|
}
|
|
58
|
-
export declare function isViewerState(v: unknown): v is ViewerState
|
|
59
|
-
export declare function validateViewerState(v: unknown): ValidationResult
|
|
60
|
-
export declare type Preferences = (
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
| {
|
|
65
|
-
$type: string
|
|
66
|
-
[k: string]: unknown
|
|
67
|
-
}
|
|
68
|
-
)[]
|
|
54
|
+
export declare function isViewerState(v: unknown): v is ViewerState;
|
|
55
|
+
export declare function validateViewerState(v: unknown): ValidationResult;
|
|
56
|
+
export declare type Preferences = (AdultContentPref | ContentLabelPref | SavedFeedsPref | {
|
|
57
|
+
$type: string;
|
|
58
|
+
[k: string]: unknown;
|
|
59
|
+
})[];
|
|
69
60
|
export interface AdultContentPref {
|
|
70
|
-
|
|
71
|
-
|
|
61
|
+
enabled: boolean;
|
|
62
|
+
[k: string]: unknown;
|
|
72
63
|
}
|
|
73
|
-
export declare function isAdultContentPref(v: unknown): v is AdultContentPref
|
|
74
|
-
export declare function validateAdultContentPref(v: unknown): ValidationResult
|
|
64
|
+
export declare function isAdultContentPref(v: unknown): v is AdultContentPref;
|
|
65
|
+
export declare function validateAdultContentPref(v: unknown): ValidationResult;
|
|
75
66
|
export interface ContentLabelPref {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
67
|
+
label: string;
|
|
68
|
+
visibility: 'show' | 'warn' | 'hide' | (string & {});
|
|
69
|
+
[k: string]: unknown;
|
|
79
70
|
}
|
|
80
|
-
export declare function isContentLabelPref(v: unknown): v is ContentLabelPref
|
|
81
|
-
export declare function validateContentLabelPref(v: unknown): ValidationResult
|
|
71
|
+
export declare function isContentLabelPref(v: unknown): v is ContentLabelPref;
|
|
72
|
+
export declare function validateContentLabelPref(v: unknown): ValidationResult;
|
|
82
73
|
export interface SavedFeedsPref {
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
74
|
+
pinned: string[];
|
|
75
|
+
saved: string[];
|
|
76
|
+
[k: string]: unknown;
|
|
86
77
|
}
|
|
87
|
-
export declare function isSavedFeedsPref(v: unknown): v is SavedFeedsPref
|
|
88
|
-
export declare function validateSavedFeedsPref(v: unknown): ValidationResult
|
|
78
|
+
export declare function isSavedFeedsPref(v: unknown): v is SavedFeedsPref;
|
|
79
|
+
export declare function validateSavedFeedsPref(v: unknown): ValidationResult;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { ValidationResult } from '@atproto/lexicon';
|
|
2
|
+
import * as AppBskySystemDeclRef from '../system/declRef';
|
|
3
|
+
export interface Main {
|
|
4
|
+
did: string;
|
|
5
|
+
declarationCid: string;
|
|
6
|
+
[k: string]: unknown;
|
|
7
|
+
}
|
|
8
|
+
export declare function isMain(v: unknown): v is Main;
|
|
9
|
+
export declare function validateMain(v: unknown): ValidationResult;
|
|
10
|
+
export interface WithInfo {
|
|
11
|
+
did: string;
|
|
12
|
+
declaration: AppBskySystemDeclRef.Main;
|
|
13
|
+
handle: string;
|
|
14
|
+
displayName?: string;
|
|
15
|
+
avatar?: string;
|
|
16
|
+
viewer?: ViewerState;
|
|
17
|
+
[k: string]: unknown;
|
|
18
|
+
}
|
|
19
|
+
export declare function isWithInfo(v: unknown): v is WithInfo;
|
|
20
|
+
export declare function validateWithInfo(v: unknown): ValidationResult;
|
|
21
|
+
export interface ViewerState {
|
|
22
|
+
muted?: boolean;
|
|
23
|
+
following?: string;
|
|
24
|
+
followedBy?: string;
|
|
25
|
+
[k: string]: unknown;
|
|
26
|
+
}
|
|
27
|
+
export declare function isViewerState(v: unknown): v is ViewerState;
|
|
28
|
+
export declare function validateViewerState(v: unknown): ValidationResult;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Headers } from '@atproto/xrpc';
|
|
2
|
+
import * as AppBskyActorProfile from './profile';
|
|
3
|
+
export interface QueryParams {
|
|
4
|
+
term?: string;
|
|
5
|
+
limit?: number;
|
|
6
|
+
before?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare type InputSchema = undefined;
|
|
9
|
+
export interface OutputSchema {
|
|
10
|
+
cursor?: string;
|
|
11
|
+
users: AppBskyActorProfile.ViewBasic[];
|
|
12
|
+
[k: string]: unknown;
|
|
13
|
+
}
|
|
14
|
+
export interface CallOptions {
|
|
15
|
+
headers?: Headers;
|
|
16
|
+
}
|
|
17
|
+
export interface Response {
|
|
18
|
+
success: boolean;
|
|
19
|
+
headers: Headers;
|
|
20
|
+
data: OutputSchema;
|
|
21
|
+
}
|
|
22
|
+
export declare function toKnownErr(e: any): any;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { Headers } from '@atproto/xrpc';
|
|
2
|
+
import * as AppBskyActorRef from './ref';
|
|
3
|
+
export interface QueryParams {
|
|
4
|
+
term?: string;
|
|
5
|
+
limit?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare type InputSchema = undefined;
|
|
8
|
+
export interface OutputSchema {
|
|
9
|
+
users: AppBskyActorRef.WithInfo[];
|
|
10
|
+
[k: string]: unknown;
|
|
11
|
+
}
|
|
12
|
+
export interface CallOptions {
|
|
13
|
+
headers?: Headers;
|
|
14
|
+
}
|
|
15
|
+
export interface Response {
|
|
16
|
+
success: boolean;
|
|
17
|
+
headers: Headers;
|
|
18
|
+
data: OutputSchema;
|
|
19
|
+
}
|
|
20
|
+
export declare function toKnownErr(e: any): any;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { Headers, XRPCError } from '@atproto/xrpc';
|
|
2
|
+
import { BlobRef } from '@atproto/lexicon';
|
|
3
|
+
export interface QueryParams {
|
|
4
|
+
}
|
|
5
|
+
export interface InputSchema {
|
|
6
|
+
displayName?: string;
|
|
7
|
+
description?: string | null;
|
|
8
|
+
avatar?: BlobRef | null;
|
|
9
|
+
banner?: BlobRef | null;
|
|
10
|
+
[k: string]: unknown;
|
|
11
|
+
}
|
|
12
|
+
export interface OutputSchema {
|
|
13
|
+
uri: string;
|
|
14
|
+
cid: string;
|
|
15
|
+
record: {};
|
|
16
|
+
[k: string]: unknown;
|
|
17
|
+
}
|
|
18
|
+
export interface CallOptions {
|
|
19
|
+
headers?: Headers;
|
|
20
|
+
qp?: QueryParams;
|
|
21
|
+
encoding: 'application/json';
|
|
22
|
+
}
|
|
23
|
+
export interface Response {
|
|
24
|
+
success: boolean;
|
|
25
|
+
headers: Headers;
|
|
26
|
+
data: OutputSchema;
|
|
27
|
+
}
|
|
28
|
+
export declare class InvalidBlobError extends XRPCError {
|
|
29
|
+
constructor(src: XRPCError);
|
|
30
|
+
}
|
|
31
|
+
export declare class BlobTooLargeError extends XRPCError {
|
|
32
|
+
constructor(src: XRPCError);
|
|
33
|
+
}
|
|
34
|
+
export declare class InvalidMimeTypeError extends XRPCError {
|
|
35
|
+
constructor(src: XRPCError);
|
|
36
|
+
}
|
|
37
|
+
export declare class InvalidImageDimensionsError extends XRPCError {
|
|
38
|
+
constructor(src: XRPCError);
|
|
39
|
+
}
|
|
40
|
+
export declare function toKnownErr(e: any): any;
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
|
1
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon';
|
|
2
2
|
export interface Main {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
external: External;
|
|
4
|
+
[k: string]: unknown;
|
|
5
5
|
}
|
|
6
|
-
export declare function isMain(v: unknown): v is Main
|
|
7
|
-
export declare function validateMain(v: unknown): ValidationResult
|
|
6
|
+
export declare function isMain(v: unknown): v is Main;
|
|
7
|
+
export declare function validateMain(v: unknown): ValidationResult;
|
|
8
8
|
export interface External {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
9
|
+
uri: string;
|
|
10
|
+
title: string;
|
|
11
|
+
description: string;
|
|
12
|
+
thumb?: BlobRef;
|
|
13
|
+
[k: string]: unknown;
|
|
14
14
|
}
|
|
15
|
-
export declare function isExternal(v: unknown): v is External
|
|
16
|
-
export declare function validateExternal(v: unknown): ValidationResult
|
|
15
|
+
export declare function isExternal(v: unknown): v is External;
|
|
16
|
+
export declare function validateExternal(v: unknown): ValidationResult;
|
|
17
17
|
export interface View {
|
|
18
|
-
|
|
19
|
-
|
|
18
|
+
external: ViewExternal;
|
|
19
|
+
[k: string]: unknown;
|
|
20
20
|
}
|
|
21
|
-
export declare function isView(v: unknown): v is View
|
|
22
|
-
export declare function validateView(v: unknown): ValidationResult
|
|
21
|
+
export declare function isView(v: unknown): v is View;
|
|
22
|
+
export declare function validateView(v: unknown): ValidationResult;
|
|
23
23
|
export interface ViewExternal {
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
uri: string;
|
|
25
|
+
title: string;
|
|
26
|
+
description: string;
|
|
27
|
+
thumb?: string;
|
|
28
|
+
[k: string]: unknown;
|
|
29
29
|
}
|
|
30
|
-
export declare function isViewExternal(v: unknown): v is ViewExternal
|
|
31
|
-
export declare function validateViewExternal(v: unknown): ValidationResult
|
|
30
|
+
export declare function isViewExternal(v: unknown): v is ViewExternal;
|
|
31
|
+
export declare function validateViewExternal(v: unknown): ValidationResult;
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
|
1
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon';
|
|
2
2
|
export interface Main {
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
images: Image[];
|
|
4
|
+
[k: string]: unknown;
|
|
5
5
|
}
|
|
6
|
-
export declare function isMain(v: unknown): v is Main
|
|
7
|
-
export declare function validateMain(v: unknown): ValidationResult
|
|
6
|
+
export declare function isMain(v: unknown): v is Main;
|
|
7
|
+
export declare function validateMain(v: unknown): ValidationResult;
|
|
8
8
|
export interface Image {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
image: BlobRef;
|
|
10
|
+
alt: string;
|
|
11
|
+
[k: string]: unknown;
|
|
12
12
|
}
|
|
13
|
-
export declare function isImage(v: unknown): v is Image
|
|
14
|
-
export declare function validateImage(v: unknown): ValidationResult
|
|
13
|
+
export declare function isImage(v: unknown): v is Image;
|
|
14
|
+
export declare function validateImage(v: unknown): ValidationResult;
|
|
15
15
|
export interface View {
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
images: ViewImage[];
|
|
17
|
+
[k: string]: unknown;
|
|
18
18
|
}
|
|
19
|
-
export declare function isView(v: unknown): v is View
|
|
20
|
-
export declare function validateView(v: unknown): ValidationResult
|
|
19
|
+
export declare function isView(v: unknown): v is View;
|
|
20
|
+
export declare function validateView(v: unknown): ValidationResult;
|
|
21
21
|
export interface ViewImage {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
thumb: string;
|
|
23
|
+
fullsize: string;
|
|
24
|
+
alt: string;
|
|
25
|
+
[k: string]: unknown;
|
|
26
26
|
}
|
|
27
|
-
export declare function isViewImage(v: unknown): v is ViewImage
|
|
28
|
-
export declare function validateViewImage(v: unknown): ValidationResult
|
|
27
|
+
export declare function isViewImage(v: unknown): v is ViewImage;
|
|
28
|
+
export declare function validateViewImage(v: unknown): ValidationResult;
|