@atproto/lex-client 0.0.5 → 0.0.7

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 (77) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/agent.d.ts +1 -1
  3. package/dist/agent.d.ts.map +1 -1
  4. package/dist/agent.js +3 -0
  5. package/dist/agent.js.map +1 -1
  6. package/dist/client.d.ts +34 -32
  7. package/dist/client.d.ts.map +1 -1
  8. package/dist/client.js +17 -21
  9. package/dist/client.js.map +1 -1
  10. package/dist/{xrpc-error.d.ts → errors.d.ts} +22 -27
  11. package/dist/errors.d.ts.map +1 -0
  12. package/dist/{xrpc-error.js → errors.js} +38 -33
  13. package/dist/errors.js.map +1 -0
  14. package/dist/index.d.ts +2 -0
  15. package/dist/index.d.ts.map +1 -1
  16. package/dist/index.js +2 -0
  17. package/dist/index.js.map +1 -1
  18. package/dist/lexicons/com/atproto/repo/createRecord.defs.d.ts.map +1 -1
  19. package/dist/lexicons/com/atproto/repo/createRecord.defs.js +5 -7
  20. package/dist/lexicons/com/atproto/repo/createRecord.defs.js.map +1 -1
  21. package/dist/lexicons/com/atproto/repo/deleteRecord.defs.d.ts.map +1 -1
  22. package/dist/lexicons/com/atproto/repo/deleteRecord.defs.js +5 -7
  23. package/dist/lexicons/com/atproto/repo/deleteRecord.defs.js.map +1 -1
  24. package/dist/lexicons/com/atproto/repo/getRecord.defs.d.ts.map +1 -1
  25. package/dist/lexicons/com/atproto/repo/getRecord.defs.js +3 -5
  26. package/dist/lexicons/com/atproto/repo/getRecord.defs.js.map +1 -1
  27. package/dist/lexicons/com/atproto/repo/listRecords.defs.d.ts.map +1 -1
  28. package/dist/lexicons/com/atproto/repo/listRecords.defs.js +2 -3
  29. package/dist/lexicons/com/atproto/repo/listRecords.defs.js.map +1 -1
  30. package/dist/lexicons/com/atproto/repo/putRecord.defs.d.ts.map +1 -1
  31. package/dist/lexicons/com/atproto/repo/putRecord.defs.js +5 -7
  32. package/dist/lexicons/com/atproto/repo/putRecord.defs.js.map +1 -1
  33. package/dist/lexicons/com/atproto/repo/uploadBlob.defs.d.ts.map +1 -1
  34. package/dist/lexicons/com/atproto/repo/uploadBlob.defs.js +3 -4
  35. package/dist/lexicons/com/atproto/repo/uploadBlob.defs.js.map +1 -1
  36. package/dist/lexicons/index.d.ts +2 -0
  37. package/dist/lexicons/index.d.ts.map +1 -0
  38. package/dist/lexicons/index.js +9 -0
  39. package/dist/lexicons/index.js.map +1 -0
  40. package/dist/response.d.ts +38 -0
  41. package/dist/response.d.ts.map +1 -0
  42. package/dist/{xrpc-response.js → response.js} +24 -20
  43. package/dist/response.js.map +1 -0
  44. package/dist/types.d.ts +0 -4
  45. package/dist/types.d.ts.map +1 -1
  46. package/dist/types.js +0 -4
  47. package/dist/types.js.map +1 -1
  48. package/dist/xrpc.d.ts +23 -17
  49. package/dist/xrpc.d.ts.map +1 -1
  50. package/dist/xrpc.js +15 -17
  51. package/dist/xrpc.js.map +1 -1
  52. package/package.json +10 -10
  53. package/src/agent.ts +6 -2
  54. package/src/client.ts +72 -66
  55. package/src/{xrpc-error.ts → errors.ts} +59 -48
  56. package/src/index.ts +2 -0
  57. package/src/lexicons/com/atproto/repo/createRecord.defs.ts +22 -28
  58. package/src/lexicons/com/atproto/repo/deleteRecord.defs.ts +18 -24
  59. package/src/lexicons/com/atproto/repo/getRecord.defs.ts +5 -10
  60. package/src/lexicons/com/atproto/repo/listRecords.defs.ts +6 -9
  61. package/src/lexicons/com/atproto/repo/putRecord.defs.ts +23 -29
  62. package/src/lexicons/com/atproto/repo/uploadBlob.defs.ts +4 -7
  63. package/src/lexicons/index.ts +5 -0
  64. package/src/{xrpc-response.ts → response.ts} +45 -30
  65. package/src/types.ts +0 -6
  66. package/src/xrpc.ts +56 -57
  67. package/tsconfig.tests.json +4 -7
  68. package/dist/lexicons.d.ts +0 -2
  69. package/dist/lexicons.d.ts.map +0 -1
  70. package/dist/lexicons.js +0 -6
  71. package/dist/lexicons.js.map +0 -1
  72. package/dist/xrpc-error.d.ts.map +0 -1
  73. package/dist/xrpc-error.js.map +0 -1
  74. package/dist/xrpc-response.d.ts +0 -35
  75. package/dist/xrpc-response.d.ts.map +0 -1
  76. package/dist/xrpc-response.js.map +0 -1
  77. package/src/lexicons.ts +0 -1
@@ -1,20 +1,11 @@
1
+ import { LexError, LexErrorCode, LexErrorData } from '@atproto/lex-data';
1
2
  import { l } from '@atproto/lex-schema';
2
3
  import { Payload } from './util.js';
3
- export type XrpcErrorCode = string;
4
- export declare const xrpcErrorCodeSchema: l.Schema<XrpcErrorCode>;
5
- export declare class XrpcError<N extends XrpcErrorCode = XrpcErrorCode> extends Error {
6
- readonly error: N;
4
+ export type LexRpcErrorPayload<N extends LexErrorCode = LexErrorCode> = Payload<LexErrorData<N>, 'application/json'>;
5
+ export declare class LexRpcError<N extends LexErrorCode = LexErrorCode> extends LexError<N> {
7
6
  name: string;
8
7
  constructor(error: N, message?: string, options?: ErrorOptions);
9
8
  }
10
- export type XrpcErrorBody<N extends XrpcErrorCode = XrpcErrorCode> = {
11
- error: N;
12
- message?: string;
13
- };
14
- export type XrpcErrorPayload<N extends XrpcErrorCode = XrpcErrorCode> = {
15
- encoding: 'application/json';
16
- body: XrpcErrorBody<N>;
17
- };
18
9
  /**
19
10
  * All unsuccessful responses should follow a standard error response
20
11
  * schema. The Content-Type should be application/json, and the payload
@@ -27,11 +18,11 @@ export type XrpcErrorPayload<N extends XrpcErrorCode = XrpcErrorCode> = {
27
18
  *
28
19
  * This function checks whether a given payload matches this schema.
29
20
  */
30
- export declare function isXrpcErrorPayload(payload: Payload | null): payload is XrpcErrorPayload;
21
+ export declare function isLexRpcErrorPayload(payload: Payload | null): payload is LexRpcErrorPayload;
31
22
  /**
32
23
  * Interface representing a failed XRPC request result.
33
24
  */
34
- type XrpcFailureResult<N extends XrpcErrorCode, E> = l.ResultFailure<E> & {
25
+ type LexRpcFailureResult<N extends LexErrorCode, E> = l.ResultFailure<E> & {
35
26
  readonly error: N;
36
27
  shouldRetry(): boolean;
37
28
  matchesSchema(): boolean;
@@ -40,32 +31,34 @@ type XrpcFailureResult<N extends XrpcErrorCode, E> = l.ResultFailure<E> & {
40
31
  * Class used to represent an HTTP request that resulted in an XRPC method error
41
32
  * That is, a non-2xx response with a valid XRPC error payload.
42
33
  */
43
- export declare class XrpcResponseError<M extends l.Procedure | l.Query = l.Procedure | l.Query, N extends XrpcErrorCode = XrpcErrorCode> extends XrpcError<N> implements XrpcFailureResult<N, XrpcResponseError<M, N>> {
34
+ export declare class LexRpcResponseError<M extends l.Procedure | l.Query = l.Procedure | l.Query, N extends LexErrorCode = LexErrorCode> extends LexRpcError<N> implements LexRpcFailureResult<N, LexRpcResponseError<M, N>> {
44
35
  readonly method: M;
45
36
  readonly status: number;
46
37
  readonly headers: Headers;
47
- readonly payload: XrpcErrorPayload<N>;
48
- name: "XrpcResponseError";
49
- constructor(method: M, status: number, headers: Headers, payload: XrpcErrorPayload<N>, options?: ErrorOptions);
38
+ readonly payload: LexRpcErrorPayload<N>;
39
+ name: string;
40
+ constructor(method: M, status: number, headers: Headers, payload: LexRpcErrorPayload<N>, options?: ErrorOptions);
50
41
  readonly success = false;
51
42
  get reason(): this;
52
- get body(): XrpcErrorBody;
43
+ get body(): LexErrorData;
53
44
  matchesSchema(): this is M extends {
54
45
  errors: readonly (infer E extends string)[];
55
- } ? XrpcResponseError<M, E> : never;
46
+ } ? LexRpcResponseError<M, E> : never;
56
47
  shouldRetry(): boolean;
48
+ toJSON(): LexErrorData<N>;
49
+ toResponse(): Response;
57
50
  }
58
51
  /**
59
52
  * This class represents an invalid XRPC response from the server.
60
53
  */
61
- export declare class XrpcInvalidResponseError extends XrpcError<'UpstreamFailure'> implements XrpcFailureResult<'UpstreamFailure', XrpcInvalidResponseError> {
62
- name: "XrpcInvalidResponseError";
54
+ export declare class LexRpcUpstreamError<N extends 'InvalidResponse' | 'UpstreamFailure' = 'InvalidResponse' | 'UpstreamFailure'> extends LexRpcError<N> implements LexRpcFailureResult<N, LexRpcUpstreamError<N>> {
55
+ name: "LexRpcUpstreamError";
63
56
  readonly response: {
64
57
  status: number;
65
58
  headers: Headers;
66
59
  payload: Payload | null;
67
60
  };
68
- constructor(message: string, response: {
61
+ constructor(error: N, message: string, response: {
69
62
  status: number;
70
63
  headers: Headers;
71
64
  }, payload: Payload | null, options?: ErrorOptions);
@@ -73,15 +66,17 @@ export declare class XrpcInvalidResponseError extends XrpcError<'UpstreamFailure
73
66
  get reason(): this;
74
67
  matchesSchema(): false;
75
68
  shouldRetry(): boolean;
69
+ toResponse(): Response;
76
70
  }
77
- export declare class XrpcUnexpectedError extends XrpcError<'InternalServerError'> implements XrpcFailureResult<'InternalServerError', unknown> {
78
- name: "XrpcUnexpectedError";
71
+ export declare class LexRpcUnexpectedError extends LexRpcError<'InternalServerError'> implements LexRpcFailureResult<'InternalServerError', unknown> {
72
+ name: "LexRpcUnexpectedError";
79
73
  protected constructor(message: string, options: Required<ErrorOptions>);
80
74
  readonly success = false;
81
75
  get reason(): unknown;
82
76
  matchesSchema(): false;
83
77
  shouldRetry(): boolean;
84
- static from(cause: unknown, message?: string): XrpcUnexpectedError;
78
+ toResponse(): Response;
79
+ static from(cause: unknown, message?: string): LexRpcUnexpectedError;
85
80
  }
86
81
  export {};
87
- //# sourceMappingURL=xrpc-error.d.ts.map
82
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AACxE,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAEnC,MAAM,MAAM,kBAAkB,CAAC,CAAC,SAAS,YAAY,GAAG,YAAY,IAAI,OAAO,CAC7E,YAAY,CAAC,C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aAAa,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,CAAC,YAAY,CAAC;IAItE,QAAQ,CAAC,OAAO,SAAQ;IAExB,IAAI,MAAM,YAET;IAED,aAAa,IAAI,KAAK;IAItB,WAAW,IAAI,OAAO;IAItB,UAAU,IAAI,QAAQ;IAItB,MAAM,CAAC,IAAI,CACT,KAAK,EAAE,OAAO,EACd,OAAO,GAAE,MAEgB,GACxB,qBAAqB;CAIzB"}
@@ -1,24 +1,16 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.XrpcUnexpectedError = exports.XrpcInvalidResponseError = exports.XrpcResponseError = exports.XrpcError = exports.xrpcErrorCodeSchema = void 0;
4
- exports.isXrpcErrorPayload = isXrpcErrorPayload;
3
+ exports.LexRpcUnexpectedError = exports.LexRpcUpstreamError = exports.LexRpcResponseError = exports.LexRpcError = void 0;
4
+ exports.isLexRpcErrorPayload = isLexRpcErrorPayload;
5
+ const lex_data_1 = require("@atproto/lex-data");
5
6
  const lex_schema_1 = require("@atproto/lex-schema");
6
- exports.xrpcErrorCodeSchema = lex_schema_1.l.string({
7
- minLength: 1,
8
- });
9
- class XrpcError extends Error {
10
- error;
11
- name = 'XrpcError';
12
- constructor(error, message = `An ${error} XRPC error occurred.`, options) {
13
- super(message, options);
14
- this.error = error;
7
+ class LexRpcError extends lex_data_1.LexError {
8
+ name = 'LexRpcError';
9
+ constructor(error, message = `${error} Lexicon RPC error`, options) {
10
+ super(error, message, options);
15
11
  }
16
12
  }
17
- exports.XrpcError = XrpcError;
18
- const xrpcErrorBodySchema = lex_schema_1.l.object({
19
- error: exports.xrpcErrorCodeSchema,
20
- message: lex_schema_1.l.optional(lex_schema_1.l.string()),
21
- });
13
+ exports.LexRpcError = LexRpcError;
22
14
  /**
23
15
  * All unsuccessful responses should follow a standard error response
24
16
  * schema. The Content-Type should be application/json, and the payload
@@ -31,21 +23,21 @@ const xrpcErrorBodySchema = lex_schema_1.l.object({
31
23
  *
32
24
  * This function checks whether a given payload matches this schema.
33
25
  */
34
- function isXrpcErrorPayload(payload) {
26
+ function isLexRpcErrorPayload(payload) {
35
27
  return (payload !== null &&
36
28
  payload.encoding === 'application/json' &&
37
- xrpcErrorBodySchema.matches(payload.body));
29
+ lex_schema_1.l.lexErrorData.matches(payload.body));
38
30
  }
39
31
  /**
40
32
  * Class used to represent an HTTP request that resulted in an XRPC method error
41
33
  * That is, a non-2xx response with a valid XRPC error payload.
42
34
  */
43
- class XrpcResponseError extends XrpcError {
35
+ class LexRpcResponseError extends LexRpcError {
44
36
  method;
45
37
  status;
46
38
  headers;
47
39
  payload;
48
- name = 'XrpcResponseError';
40
+ name = 'LexRpcResponseError';
49
41
  constructor(method, status, headers, payload, options) {
50
42
  const { error, message } = payload.body;
51
43
  super(error, message, options);
@@ -70,17 +62,24 @@ class XrpcResponseError extends XrpcError {
70
62
  return false;
71
63
  return true;
72
64
  }
65
+ toJSON() {
66
+ return this.payload.body;
67
+ }
68
+ toResponse() {
69
+ const { status, headers } = this;
70
+ return Response.json(this.toJSON(), { status, headers });
71
+ }
73
72
  }
74
- exports.XrpcResponseError = XrpcResponseError;
73
+ exports.LexRpcResponseError = LexRpcResponseError;
75
74
  /**
76
75
  * This class represents an invalid XRPC response from the server.
77
76
  */
78
- class XrpcInvalidResponseError extends XrpcError {
79
- name = 'XrpcInvalidResponseError';
77
+ class LexRpcUpstreamError extends LexRpcError {
78
+ name = 'LexRpcUpstreamError';
80
79
  // For debugging purposes, we keep the response details here
81
80
  response;
82
- constructor(message, response, payload, options) {
83
- super('UpstreamFailure', message, { cause: options?.cause });
81
+ constructor(error, message, response, payload, options) {
82
+ super(error, message, { cause: options?.cause });
84
83
  this.response = {
85
84
  status: response.status,
86
85
  headers: response.headers,
@@ -98,10 +97,13 @@ class XrpcInvalidResponseError extends XrpcError {
98
97
  // Do not retry client errors
99
98
  return this.response.status >= 500;
100
99
  }
100
+ toResponse() {
101
+ return Response.json(this.toJSON(), { status: 502 });
102
+ }
101
103
  }
102
- exports.XrpcInvalidResponseError = XrpcInvalidResponseError;
103
- class XrpcUnexpectedError extends XrpcError {
104
- name = 'XrpcUnexpectedError';
104
+ exports.LexRpcUpstreamError = LexRpcUpstreamError;
105
+ class LexRpcUnexpectedError extends LexRpcError {
106
+ name = 'LexRpcUnexpectedError';
105
107
  constructor(message, options) {
106
108
  super('InternalServerError', message, options);
107
109
  }
@@ -115,13 +117,16 @@ class XrpcUnexpectedError extends XrpcError {
115
117
  shouldRetry() {
116
118
  return true;
117
119
  }
118
- static from(cause, message = cause instanceof XrpcError
120
+ toResponse() {
121
+ return Response.json(this.toJSON(), { status: 500 });
122
+ }
123
+ static from(cause, message = cause instanceof lex_data_1.LexError
119
124
  ? cause.message
120
125
  : 'XRPC request failed') {
121
- if (cause instanceof XrpcUnexpectedError)
126
+ if (cause instanceof LexRpcUnexpectedError)
122
127
  return cause;
123
- return new XrpcUnexpectedError(message, { cause });
128
+ return new LexRpcUnexpectedError(message, { cause });
124
129
  }
125
130
  }
126
- exports.XrpcUnexpectedError = XrpcUnexpectedError;
127
- //# sourceMappingURL=xrpc-error.js.map
131
+ exports.LexRpcUnexpectedError = LexRpcUnexpectedError;
132
+ //# sourceMappingURL=errors.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";;;AAmCA,oDAQC;AA3CD,gDAAwE;AACxE,oDAAuC;AAQvC,MAAa,WAEX,SAAQ,mBAAW;IACnB,IAAI,GAAG,aAAa,CAAA;IAEpB,YACE,KAAQ,EACR,UAAkB,GAAG,KAAK,oBAAoB,EAC9C,OAAsB;QAEtB,KAAK,CAAC,KAAK,EAAE,OAAO,EAAE,OAAO,CAAC,CAAA;IAChC,CAAC;CACF;AAZD,kCAYC;AAED;;;;;;;;;;;GAWG;AACH,SAAgB,oBAAoB,CAClC,OAAuB;IAEvB,OAAO,CACL,OAAO,KAAK,IAAI;QAChB,OAAO,C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M,EAAE,EAAE,EAAE,MAAM,EAAE,GAAG,EAAE,CAAC,CAAA;IACtD,CAAC;IAED,MAAM,CAAC,IAAI,CACT,KAAc,EACd,UAAkB,KAAK,YAAY,mBAAQ;QACzC,CAAC,CAAC,KAAK,CAAC,OAAO;QACf,CAAC,CAAC,qBAAqB;QAEzB,IAAI,KAAK,YAAY,qBAAqB;YAAE,OAAO,KAAK,CAAA;QACxD,OAAO,IAAI,qBAAqB,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,CAAC,CAAA;IACtD,CAAC;CACF;AArCD,sDAqCC","sourcesContent":["import { LexError, LexErrorCode, LexErrorData } from '@atproto/lex-data'\nimport { l } from '@atproto/lex-schema'\nimport { Payload } from './util.js'\n\nexport type LexRpcErrorPayload<N extends LexErrorCode = LexErrorCode> = Payload<\n LexErrorData<N>,\n 'application/json'\n>\n\nexport class LexRpcError<\n N extends LexErrorCode = LexErrorCode,\n> extends LexError<N> {\n name = 'LexRpcError'\n\n constructor(\n error: N,\n message: string = `${error} Lexicon RPC error`,\n options?: ErrorOptions,\n ) {\n super(error, message, options)\n }\n}\n\n/**\n * All unsuccessful responses should follow a standard error response\n * schema. The Content-Type should be application/json, and the payload\n * should be a JSON object with the following fields:\n *\n * - `error` (string, required): type name of the error (generic ASCII\n * constant, no whitespace)\n * - `message` (string, optional): description of the error, appropriate for\n * display to humans\n *\n * This function checks whether a given payload matches this schema.\n */\nexport function isLexRpcErrorPayload(\n payload: Payload | null,\n): payload is LexRpcErrorPayload {\n return (\n payload !== null &&\n payload.encoding === 'application/json' &&\n l.lexErrorData.matches(payload.body)\n )\n}\n\n/**\n * Interface representing a failed XRPC request result.\n */\ntype LexRpcFailureResult<N extends LexErrorCode, E> = l.ResultFailure<E> & {\n readonly error: N\n shouldRetry(): boolean\n matchesSchema(): boolean\n}\n\n/**\n * Class used to represent an HTTP request that resulted in an XRPC method error\n * That is, a non-2xx response with a valid XRPC error payload.\n */\nexport class LexRpcResponseError<\n M extends l.Procedure | l.Query = l.Procedure | l.Query,\n N extends LexErrorCode = LexErrorCode,\n >\n extends LexRpcError<N>\n implements LexRpcFailureResult<N, LexRpcResponseError<M, N>>\n{\n name = 'LexRpcResponseError'\n\n constructor(\n readonly method: M,\n readonly status: number,\n readonly headers: Headers,\n readonly payload: LexRpcErrorPayload<N>,\n options?: ErrorOptions,\n ) {\n const { error, message } = payload.body\n super(error, message, options)\n }\n\n readonly success = false\n\n get reason(): this {\n return this as this\n }\n\n get body(): LexErrorData {\n return this.payload.body\n }\n\n matchesSchema(): this is M extends {\n errors: readonly (infer E extends string)[]\n }\n ? LexRpcResponseError<M, E>\n : never {\n return this.method.errors?.includes(this.error) ?? false\n }\n\n shouldRetry(): boolean {\n // Do not retry client errors\n if (this.status < 500) return false\n\n return true\n }\n\n toJSON() {\n return this.payload.body\n }\n\n toResponse(): Response {\n const { status, headers } = this\n return Response.json(this.toJSON(), { status, headers })\n }\n}\n\n/**\n * This class represents an invalid XRPC response from the server.\n */\nexport class LexRpcUpstreamError<\n N extends 'InvalidResponse' | 'UpstreamFailure' =\n | 'InvalidResponse'\n | 'UpstreamFailure',\n >\n extends LexRpcError<N>\n implements LexRpcFailureResult<N, LexRpcUpstreamError<N>>\n{\n name = 'LexRpcUpstreamError' as const\n\n // For debugging purposes, we keep the response details here\n readonly response: {\n status: number\n headers: Headers\n payload: Payload | null\n }\n\n constructor(\n error: N,\n message: string,\n response: { status: number; headers: Headers },\n payload: Payload | null,\n options?: ErrorOptions,\n ) {\n super(error, message, { cause: options?.cause })\n this.response = {\n status: response.status,\n headers: response.headers,\n payload,\n }\n }\n\n readonly success = false as const\n\n get reason(): this {\n return this\n }\n\n matchesSchema(): false {\n return false\n }\n\n shouldRetry(): boolean {\n // Do not retry client errors\n return this.response.status >= 500\n }\n\n toResponse(): Response {\n return Response.json(this.toJSON(), { status: 502 })\n }\n}\n\nexport class LexRpcUnexpectedError\n extends LexRpcError<'InternalServerError'>\n implements LexRpcFailureResult<'InternalServerError', unknown>\n{\n name = 'LexRpcUnexpectedError' as const\n\n protected constructor(message: string, options: Required<ErrorOptions>) {\n super('InternalServerError', message, options)\n }\n\n readonly success = false\n\n get reason() {\n return this.cause\n }\n\n matchesSchema(): false {\n return false\n }\n\n shouldRetry(): boolean {\n return true\n }\n\n toResponse(): Response {\n return Response.json(this.toJSON(), { status: 500 })\n }\n\n static from(\n cause: unknown,\n message: string = cause instanceof LexError\n ? cause.message\n : 'XRPC request failed',\n ): LexRpcUnexpectedError {\n if (cause instanceof LexRpcUnexpectedError) return cause\n return new LexRpcUnexpectedError(message, { cause })\n }\n}\n"]}
package/dist/index.d.ts CHANGED
@@ -1,5 +1,7 @@
1
1
  export * from './agent.js';
2
2
  export * from './client.js';
3
+ export * from './errors.js';
4
+ export * from './response.js';
3
5
  export * from './types.js';
4
6
  export * from './xrpc.js';
5
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,YAAY,CAAA;AAC1B,cAAc,WAAW,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,aAAa,CAAA;AAC3B,cAAc,eAAe,CAAA;AAC7B,cAAc,YAAY,CAAA;AAC1B,cAAc,WAAW,CAAA"}
package/dist/index.js CHANGED
@@ -3,6 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  tslib_1.__exportStar(require("./agent.js"), exports);
5
5
  tslib_1.__exportStar(require("./client.js"), exports);
6
+ tslib_1.__exportStar(require("./errors.js"), exports);
7
+ tslib_1.__exportStar(require("./response.js"), exports);
6
8
  tslib_1.__exportStar(require("./types.js"), exports);
7
9
  tslib_1.__exportStar(require("./xrpc.js"), exports);
8
10
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,qDAA0B;AAC1B,sDAA2B;AAC3B,qDAA0B;AAC1B,oDAAyB","sourcesContent":["export * from './agent.js'\nexport * from './client.js'\nexport * from './types.js'\nexport * from './xrpc.js'\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,qDAA0B;AAC1B,sDAA2B;AAC3B,sDAA2B;AAC3B,wDAA6B;AAC7B,qDAA0B;AAC1B,oDAAyB","sourcesContent":["export * from './agent.js'\nexport * from './client.js'\nexport * from './errors.js'\nexport * from './response.js'\nexport * from './types.js'\nexport * from './xrpc.js'\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"createRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/createRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AACvC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAA;AAE1C,QAAA,MAAM,KAAK,kCAAkC,CAAA;AAE7C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,gFAAgF;AAChF,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;8BAkCP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,gBAAgB,CAAC,OAAO,IAAI,CAAC,CAAA;AACnD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,oBAAoB,CAAC,OAAO,IAAI,CAAC,CAAA;AAC3D,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,iCAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM;;;;;;;;;;;GAA2B,EACjC,OAAO;;;;;;;;;GAA4B,CAAA"}
1
+ {"version":3,"file":"createRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/createRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AACvC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAA;AAE1C,QAAA,MAAM,KAAK,kCAAkC,CAAA;AAE7C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,gFAAgF;AAChF,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;8BA4BP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,gBAAgB,CAAC,OAAO,IAAI,CAAC,CAAA;AACnD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,oBAAoB,CAAC,OAAO,IAAI,CAAC,CAAA;AAC3D,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,iCAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM;;;;;;;;;;;GAA2B,EACjC,OAAO;;;;;;;;;GAA4B,CAAA"}
@@ -13,9 +13,8 @@ exports.$nsid = $nsid;
13
13
  const main =
14
14
  /*#__PURE__*/
15
15
  lex_schema_1.l.procedure($nsid,
16
- /*#__PURE__*/ lex_schema_1.l.params({}),
17
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
18
- /*#__PURE__*/ lex_schema_1.l.object({
16
+ /*#__PURE__*/ lex_schema_1.l.params(),
17
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
19
18
  repo: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-identifier' }),
20
19
  collection: /*#__PURE__*/ lex_schema_1.l.string({ format: 'nsid' }),
21
20
  rkey: /*#__PURE__*/ lex_schema_1.l.optional(
@@ -24,15 +23,14 @@ lex_schema_1.l.procedure($nsid,
24
23
  record: /*#__PURE__*/ lex_schema_1.l.unknownObject(),
25
24
  swapCommit: /*#__PURE__*/ lex_schema_1.l.optional(
26
25
  /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
27
- })),
28
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
29
- /*#__PURE__*/ lex_schema_1.l.object({
26
+ }),
27
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
30
28
  uri: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-uri' }),
31
29
  cid: /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' }),
32
30
  commit: /*#__PURE__*/ lex_schema_1.l.optional(
33
31
  /*#__PURE__*/ lex_schema_1.l.ref((() => RepoDefs.commitMeta))),
34
32
  validationStatus: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string()),
35
- })), ['InvalidSwap']);
33
+ }), ['InvalidSwap']);
36
34
  exports.main = main;
37
35
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$input = main.input, exports.$output = main.output;
38
36
  //# sourceMappingURL=createRecord.defs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"createRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/createRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;AAEH,oDAAuC;AACvC,iEAA0C;AAE1C,MAAM,KAAK,GAA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a,CAAC,cAAC,CAAC,GAAG,CACjB,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,UAAU,CAAQ,CACnC,CACF;IACD,gBAAgB,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;CACrE,CAAC,CACH,EACD,CAAC,aAAa,CAAC,CAChB,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.createRecord'\n\nexport { $nsid }\n\n/** Create a single new repository record. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params({}),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'record-key', maxLength: 512 }),\n ),\n validate: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n record: /*#__PURE__*/ l.unknownObject(),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n ),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n validationStatus: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n }),\n ),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
1
+ {"version":3,"file":"createRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/createRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;AAEH,oDAAuC;AACvC,iEAA0C;AAE1C,MAAM,KAAK,GAAG,+BAA+B,CAAA;AAEpC,sBAAK;AAEd,gFAAgF;AAChF,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,SAAS,CACT,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE;AACxB,aAAa,CAAC,cAAC,CAAC,WAAW,CAAC;IAC1B,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,eAAe,EAAE,CAAC;IACzD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACtD,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAC5B,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,GAAG,EAAE,CAAC,CACjE;IACD,QAAQ,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,OAAO,EAAE,CAAC;IAC7D,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;IACvC,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAClC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAC1C;CACF,CAAC;AACF,aAAa,CAAC,cAAC,CAAC,WAAW,CAAC;IAC1B,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC9C,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAC9B,aAAa,CAAC,cAAC,CAAC,GAAG,CACjB,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,UAAU,CAAQ,CACnC,CACF;IACD,gBAAgB,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;CACrE,CAAC,EACF,CAAC,aAAa,CAAC,CAChB,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.createRecord'\n\nexport { $nsid }\n\n/** Create a single new repository record. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params(),\n /*#__PURE__*/ l.jsonPayload({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'record-key', maxLength: 512 }),\n ),\n validate: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n record: /*#__PURE__*/ l.unknownObject(),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n /*#__PURE__*/ l.jsonPayload({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n validationStatus: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n }),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"deleteRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/deleteRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AACvC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAA;AAE1C,QAAA,MAAM,KAAK,kCAAkC,CAAA;AAE7C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,iGAAiG;AACjG,QAAA,MAAM,IAAI;;;;;;;;;;;;;;8BA8BP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAi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AC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,iCAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM;;;;;;;;;;;;GAA2B,EACjC,OAAO;;GAA4B,CAAA"}
@@ -13,9 +13,8 @@ exports.$nsid = $nsid;
13
13
  const main =
14
14
  /*#__PURE__*/
15
15
  lex_schema_1.l.procedure($nsid,
16
- /*#__PURE__*/ lex_schema_1.l.params({}),
17
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
18
- /*#__PURE__*/ lex_schema_1.l.object({
16
+ /*#__PURE__*/ lex_schema_1.l.params(),
17
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
19
18
  repo: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-identifier' }),
20
19
  collection: /*#__PURE__*/ lex_schema_1.l.string({ format: 'nsid' }),
21
20
  rkey: /*#__PURE__*/ lex_schema_1.l.string({ format: 'record-key' }),
@@ -23,12 +22,11 @@ lex_schema_1.l.procedure($nsid,
23
22
  /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
24
23
  swapCommit: /*#__PURE__*/ lex_schema_1.l.optional(
25
24
  /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
26
- })),
27
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
28
- /*#__PURE__*/ lex_schema_1.l.object({
25
+ }),
26
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
29
27
  commit: /*#__PURE__*/ lex_schema_1.l.optional(
30
28
  /*#__PURE__*/ lex_schema_1.l.ref((() => RepoDefs.commitMeta))),
31
- })), ['InvalidSwap']);
29
+ }), ['InvalidSwap']);
32
30
  exports.main = main;
33
31
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$input = main.input, exports.$output = main.output;
34
32
  //# sourceMappingURL=deleteRecord.defs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"deleteRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/deleteRecord.defs.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AI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.deleteRecord'\n\nexport { $nsid }\n\n/** Delete a repository record, or ensure it doesn't exist. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params({}),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key' }),\n swapRecord: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n ),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n }),\n ),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
1
+ {"version":3,"file":"deleteRecord.defs.js","source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AAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.deleteRecord'\n\nexport { $nsid }\n\n/** Delete a repository record, or ensure it doesn't exist. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params(),\n /*#__PURE__*/ l.jsonPayload({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key' }),\n swapRecord: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n /*#__PURE__*/ l.jsonPayload({\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n }),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"getRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/getRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AAEvC,QAAA,MAAM,KAAK,+BAA+B,CAAA;AAE1C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,oEAAoE;AACpE,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;iCAqBP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,8BAA0B,EACzC,OAAO;;;;;;;;;;;EAAkB,EACzB,OAAO;;;;;;GAAc,CAAA"}
1
+ {"version":3,"file":"getRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/getRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AAEvC,QAAA,MAAM,KAAK,+BAA+B,CAAA;AAE1C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,oEAAoE;AACpE,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;iCAgBP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,8BAA0B,EACzC,OAAO;;;;;;;;;;;EAAkB,EACzB,OAAO;;;;;;GAAc,CAAA"}
@@ -17,13 +17,11 @@ lex_schema_1.l.query($nsid,
17
17
  rkey: /*#__PURE__*/ lex_schema_1.l.string({ format: 'record-key' }),
18
18
  cid: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
19
19
  }),
20
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
21
- /*#__PURE__*/ lex_schema_1.l.object({
20
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
22
21
  uri: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-uri' }),
23
- cid: /*#__PURE__*/ lex_schema_1.l.optional(
24
- /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
22
+ cid: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
25
23
  value: /*#__PURE__*/ lex_schema_1.l.unknownObject(),
26
- })), ['RecordNotFound']);
24
+ }), ['RecordNotFound']);
27
25
  exports.main = main;
28
26
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$output = main.output;
29
27
  //# sourceMappingURL=getRecord.defs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"getRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/getRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,oDAAuC;AAEvC,MAAM,KAAK,GAAG,4BAA4B,CAAA;AAEjC,sBAAK;AAEd,oEAAoE;AACpE,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,KAAK,CACL,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,eAAe,EAAE,CAAC;IACzD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACtD,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC;IACtD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC;CACzE,CAAC;AACF,aAAa,CAAC,cAAC,CAAC,OAAO,CACrB,kBAAkB;AAClB,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAC3B,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAC1C;IACD,KAAK,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;CACvC,CAAC,CACH,EACD,CAAC,gBAAgB,CAAC,CACnB,CAAA;AACM,oBAAI;AAMA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAG,IAAI,CAAC,UAAU,EACzB,QAAA,OAAO,GAAG,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.getRecord'\n\nexport { $nsid }\n\n/** Get a single record from a repository. Does not require auth. */\nconst main =\n /*#__PURE__*/\n l.query(\n $nsid,\n /*#__PURE__*/ l.params({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key' }),\n cid: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string({ format: 'cid' })),\n }),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n value: /*#__PURE__*/ l.unknownObject(),\n }),\n ),\n ['RecordNotFound'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = main.parameters,\n $output = main.output\n"]}
1
+ {"version":3,"file":"getRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/getRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,oDAAuC;AAEvC,MAAM,KAAK,GAAG,4BAA4B,CAAA;AAEjC,sBAAK;AAEd,oEAAoE;AACpE,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,KAAK,CACL,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,eAAe,EAAE,CAAC;IACzD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACtD,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC;IACtD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC;CACzE,CAAC;AACF,aAAa,CAAC,cAAC,CAAC,WAAW,CAAC;IAC1B,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC;IACxE,KAAK,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;CACvC,CAAC,EACF,CAAC,gBAAgB,CAAC,CACnB,CAAA;AACM,oBAAI;AAMA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAG,IAAI,CAAC,UAAU,EACzB,QAAA,OAAO,GAAG,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.getRecord'\n\nexport { $nsid }\n\n/** Get a single record from a repository. Does not require auth. */\nconst main =\n /*#__PURE__*/\n l.query(\n $nsid,\n /*#__PURE__*/ l.params({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key' }),\n cid: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string({ format: 'cid' })),\n }),\n /*#__PURE__*/ l.jsonPayload({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string({ format: 'cid' })),\n value: /*#__PURE__*/ l.unknownObject(),\n }),\n ['RecordNotFound'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = main.parameters,\n $output = main.output\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"listRecords.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/listRecords.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AAEvC,QAAA,MAAM,KAAK,iCAAiC,CAAA;AAE5C,OAAO,EAAE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AAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,gCAA0B,EACzC,OAAO;;;;;;;;;;EAAkB,EACzB,OAAO;;;GAAc,CAAA;AAEvB,KAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,qCAAqC,CAAA;IAC7C,GAAG,EAAE,CAAC,CAAC,WAAW,CAAA;IAClB,GAAG,EAAE,CAAC,CAAC,SAAS,CAAA;IAChB,KAAK,EAAE,CAAC,CAAC,aAAa,CAAA;CACvB,CAAA;AAED,YAAY,EAAE,KAAK,IAAI,SAAS,EAAE,CAAA;AAElC,QAAA,MAAM,KAAK,+FAQV,CAAA;AAED,OAAO,EAAE,KAAK,IAAI,MAAM,EAAE,CAAA"}
@@ -19,12 +19,11 @@ lex_schema_1.l.query($nsid,
19
19
  cursor: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string()),
20
20
  reverse: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.boolean()),
21
21
  }),
22
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
23
- /*#__PURE__*/ lex_schema_1.l.object({
22
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
24
23
  cursor: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string()),
25
24
  records: /*#__PURE__*/ lex_schema_1.l.array(
26
25
  /*#__PURE__*/ lex_schema_1.l.ref((() => def$0))),
27
- })));
26
+ }));
28
27
  exports.main = main;
29
28
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$output = main.output;
30
29
  const def$0 = /*#__PURE__*/ lex_schema_1.l.typedObject($nsid, 'record',
@@ -1 +1 @@
1
- {"version":3,"file":"listRecords.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/listR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AAG,IAAI,CAAC,UAAU,EACzB,QAAA,OAAO,GAAG,IAAI,CAAC,MAAM,CAAA;AAWvB,MAAM,KAAK,GAAG,aAAa,CAAC,cAAC,CAAC,WAAW,CACvC,KAAK,EACL,QAAQ;AACR,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC9C,KAAK,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;CACvC,CAAC,CACH,CAAA;AAEiB,uBAAM","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.listRecords'\n\nexport { $nsid }\n\n/** List a range of records in a repository, matching a specific collection. Does not require auth. */\nconst main =\n /*#__PURE__*/\n l.query(\n $nsid,\n /*#__PURE__*/ l.params({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n limit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.integer({ minimum: 1, maximum: 100, default: 50 }),\n ),\n cursor: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n reverse: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n }),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n cursor: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n records: /*#__PURE__*/ l.array(\n /*#__PURE__*/ l.ref<Def$0>((() => def$0) as any),\n ),\n }),\n ),\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = main.parameters,\n $output = main.output\n\ntype Def$0 = {\n $type?: 'com.atproto.repo.listRecords#record'\n uri: l.AtUriString\n cid: l.CidString\n value: l.UnknownObject\n}\n\nexport type { Def$0 as DefRecord }\n\nconst def$0 = /*#__PURE__*/ l.typedObject<Def$0>(\n $nsid,\n 'record',\n /*#__PURE__*/ l.object({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n value: /*#__PURE__*/ l.unknownObject(),\n }),\n)\n\nexport { def$0 as record }\n"]}
1
+ {"version":3,"file":"listRecords.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/listRecords.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,oDAAuC;AAEvC,MAAM,KAAK,GAAG,8BAA8B,CAAA;AAEnC,sBAAK;AAEd,sGAAsG;AACtG,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,KAAK,CACL,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,eAAe,EAAE,CAAC;IACzD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACtD,KAAK,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAC7B,aAAa,CAAC,cAAC,CAAC,OAAO,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,CACnE;IACD,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;IAC1D,OAAO,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,OAAO,EAAE,CAAC;CAC7D,CAAC;AACF,aAAa,CAAC,cAAC,CAAC,WAAW,CAAC;IAC1B,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;IAC1D,OAAO,EAAE,aAAa,CAAC,cAAC,CAAC,KAAK;IAC5B,aAAa,CAAC,cAAC,CAAC,GAAG,CAAQ,CAAC,GAAG,EAAE,CAAC,KAAK,CAAQ,CAAC,CACjD;CACF,CAAC,CACH,CAAA;AACM,oBAAI;AAMA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAG,IAAI,CAAC,UAAU,EACzB,QAAA,OAAO,GAAG,IAAI,CAAC,MAAM,CAAA;AAWvB,MAAM,KAAK,GAAG,aAAa,CAAC,cAAC,CAAC,WAAW,CACvC,KAAK,EACL,QAAQ;AACR,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC9C,KAAK,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;CACvC,CAAC,CACH,CAAA;AAEiB,uBAAM","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.listRecords'\n\nexport { $nsid }\n\n/** List a range of records in a repository, matching a specific collection. Does not require auth. */\nconst main =\n /*#__PURE__*/\n l.query(\n $nsid,\n /*#__PURE__*/ l.params({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n limit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.integer({ minimum: 1, maximum: 100, default: 50 }),\n ),\n cursor: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n reverse: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n }),\n /*#__PURE__*/ l.jsonPayload({\n cursor: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n records: /*#__PURE__*/ l.array(\n /*#__PURE__*/ l.ref<Def$0>((() => def$0) as any),\n ),\n }),\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = main.parameters,\n $output = main.output\n\ntype Def$0 = {\n $type?: 'com.atproto.repo.listRecords#record'\n uri: l.AtUriString\n cid: l.CidString\n value: l.UnknownObject\n}\n\nexport type { Def$0 as DefRecord }\n\nconst def$0 = /*#__PURE__*/ l.typedObject<Def$0>(\n $nsid,\n 'record',\n /*#__PURE__*/ l.object({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n value: /*#__PURE__*/ l.unknownObject(),\n }),\n)\n\nexport { def$0 as record }\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"putRecord.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/putRecord.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AACvC,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAA;AAE1C,QAAA,MAAM,KAAK,+BAA+B,CAAA;AAE1C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,uGAAuG;AACvG,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;8BAmCP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI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AC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,8BAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM;;;;;;;;;;;;;;;GAA2B,EACjC,OAAO;;;;;;;;;GAA4B,CAAA"}
@@ -13,9 +13,8 @@ exports.$nsid = $nsid;
13
13
  const main =
14
14
  /*#__PURE__*/
15
15
  lex_schema_1.l.procedure($nsid,
16
- /*#__PURE__*/ lex_schema_1.l.params({}),
17
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
18
- /*#__PURE__*/ lex_schema_1.l.object({
16
+ /*#__PURE__*/ lex_schema_1.l.params(),
17
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
19
18
  repo: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-identifier' }),
20
19
  collection: /*#__PURE__*/ lex_schema_1.l.string({ format: 'nsid' }),
21
20
  rkey: /*#__PURE__*/ lex_schema_1.l.string({ format: 'record-key', maxLength: 512 }),
@@ -25,15 +24,14 @@ lex_schema_1.l.procedure($nsid,
25
24
  /*#__PURE__*/ lex_schema_1.l.nullable(/*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' }))),
26
25
  swapCommit: /*#__PURE__*/ lex_schema_1.l.optional(
27
26
  /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' })),
28
- })),
29
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
30
- /*#__PURE__*/ lex_schema_1.l.object({
27
+ }),
28
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
31
29
  uri: /*#__PURE__*/ lex_schema_1.l.string({ format: 'at-uri' }),
32
30
  cid: /*#__PURE__*/ lex_schema_1.l.string({ format: 'cid' }),
33
31
  commit: /*#__PURE__*/ lex_schema_1.l.optional(
34
32
  /*#__PURE__*/ lex_schema_1.l.ref((() => RepoDefs.commitMeta))),
35
33
  validationStatus: /*#__PURE__*/ lex_schema_1.l.optional(/*#__PURE__*/ lex_schema_1.l.string()),
36
- })), ['InvalidSwap']);
34
+ }), ['InvalidSwap']);
37
35
  exports.main = main;
38
36
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$input = main.input, exports.$output = main.output;
39
37
  //# sourceMappingURL=putRecord.defs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"putRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/putRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;AAEH,oDAAuC;AACvC,iEAA0C;AAE1C,MAAM,KAAK,GAAG,4BAA4B,CAAA;AAEjC,sBAAK;AAEd,uGAAuG;AACvG,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,SAAS,CACT,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,CAAC;AAC1B,aAAa,CAAC,cAAC,CAAC,OAAO,CACrB,kBAAkB;AAClB,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,eAAe,EAAE,CAAC;IACzD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IACtD,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,GAAG,EAAE,CAAC;IACtE,QAAQ,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,OAAO,EAAE,CAAC;IAC7D,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,aAAa,EAAE;IACvC,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAClC,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAAC,CACpE;IACD,UAAU,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAClC,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,CAC1C;CACF,CAAC,CACH;AACD,aAAa,CAAC,cAAC,CAAC,OAAO,CACrB,kBAAkB;AAClB,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;IACjD,GAAG,EAAE,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IAC9C,MAAM,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ;IAC9B,aAAa,CAAC,cAAC,CAAC,GAAG,CACjB,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,UAAU,CAAQ,CACnC,CACF;IACD,gBAAgB,EAAE,aAAa,CAAC,cAAC,CAAC,QAAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;CACrE,CAAC,CACH,EACD,CAAC,aAAa,CAAC,CAChB,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.putRecord'\n\nexport { $nsid }\n\n/** Write a repository record, creating or updating it as needed. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params({}),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key', maxLength: 512 }),\n validate: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n record: /*#__PURE__*/ l.unknownObject(),\n swapRecord: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.nullable(/*#__PURE__*/ l.string({ format: 'cid' })),\n ),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n ),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n validationStatus: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n }),\n ),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
1
+ {"version":3,"file":"putRecord.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/putRecord.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;AAEH,oDAAuC;AACvC,iEAA0C;AAE1C,MAAM,KAAK,GAAG,4BAA4B,CAAA;AAEjC,sBAAK;AAEd,uGAAuG;AACvG,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,SAAS,CACT,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE;AACxB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AAQ,CAAC,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE,CAAC;CACrE,CAAC,EACF,CAAC,aAAa,CAAC,CAChB,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\nimport * as RepoDefs from './defs.defs.js'\n\nconst $nsid = 'com.atproto.repo.putRecord'\n\nexport { $nsid }\n\n/** Write a repository record, creating or updating it as needed. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params(),\n /*#__PURE__*/ l.jsonPayload({\n repo: /*#__PURE__*/ l.string({ format: 'at-identifier' }),\n collection: /*#__PURE__*/ l.string({ format: 'nsid' }),\n rkey: /*#__PURE__*/ l.string({ format: 'record-key', maxLength: 512 }),\n validate: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.boolean()),\n record: /*#__PURE__*/ l.unknownObject(),\n swapRecord: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.nullable(/*#__PURE__*/ l.string({ format: 'cid' })),\n ),\n swapCommit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.string({ format: 'cid' }),\n ),\n }),\n /*#__PURE__*/ l.jsonPayload({\n uri: /*#__PURE__*/ l.string({ format: 'at-uri' }),\n cid: /*#__PURE__*/ l.string({ format: 'cid' }),\n commit: /*#__PURE__*/ l.optional(\n /*#__PURE__*/ l.ref<RepoDefs.CommitMeta>(\n (() => RepoDefs.commitMeta) as any,\n ),\n ),\n validationStatus: /*#__PURE__*/ l.optional(/*#__PURE__*/ l.string()),\n }),\n ['InvalidSwap'],\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"uploadBlob.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/uploadBlob.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AAEvC,QAAA,MAAM,KAAK,gCAAgC,CAAA;AAE3C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,gRAAgR;AAChR,QAAA,MAAM,IAAI;;;;eAYP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,gBAAgB,CAAC,OAAO,IAAI,CAAC,CAAA;AACnD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,oBAAoB,CAAC,OAAO,IAAI,CAAC,CAAA;AAC3D,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,+BAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM,6BAA2B,EACjC,OAAO;;;;GAA4B,CAAA"}
1
+ {"version":3,"file":"uploadBlob.defs.d.ts","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/uploadBlob.defs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,qBAAqB,CAAA;AAEvC,QAAA,MAAM,KAAK,gCAAgC,CAAA;AAE3C,OAAO,EAAE,KAAK,EAAE,CAAA;AAEhB,gRAAgR;AAChR,QAAA,MAAM,IAAI;;;;eASP,CAAA;AACH,OAAO,EAAE,IAAI,EAAE,CAAA;AAEf,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,KAAK,GAAG,CAAC,CAAC,gBAAgB,CAAC,OAAO,IAAI,CAAC,CAAA;AACnD,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,oBAAoB,CAAC,OAAO,IAAI,CAAC,CAAA;AAC3D,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,iBAAiB,CAAC,OAAO,IAAI,CAAC,CAAA;AACrD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,qBAAqB,CAAC,OAAO,IAAI,CAAC,CAAA;AAE7D,eAAO,MAAM,IAAI,+BAA0B,EACzC,OAAO,oBAAgC,EACvC,MAAM,6BAA2B,EACjC,OAAO;;;;GAA4B,CAAA"}
@@ -11,12 +11,11 @@ exports.$nsid = $nsid;
11
11
  const main =
12
12
  /*#__PURE__*/
13
13
  lex_schema_1.l.procedure($nsid,
14
- /*#__PURE__*/ lex_schema_1.l.params({}),
14
+ /*#__PURE__*/ lex_schema_1.l.params(),
15
15
  /*#__PURE__*/ lex_schema_1.l.payload('*/*'),
16
- /*#__PURE__*/ lex_schema_1.l.payload('application/json',
17
- /*#__PURE__*/ lex_schema_1.l.object({
16
+ /*#__PURE__*/ lex_schema_1.l.jsonPayload({
18
17
  blob: /*#__PURE__*/ lex_schema_1.l.blob({ allowLegacy: false }),
19
- })));
18
+ }));
20
19
  exports.main = main;
21
20
  exports.$lxm = main.nsid, exports.$params = main.parameters, exports.$input = main.input, exports.$output = main.output;
22
21
  //# sourceMappingURL=uploadBlob.defs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"uploadBlob.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/uploadBlob.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,oDAAuC;AAEvC,MAAM,KAAK,GAAG,6BAA6B,CAAA;AAElC,sBAAK;AAEd,gRAAgR;AAChR,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,SAAS,CACT,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC,EAAE,CAAC;AAC1B,aAAa,CAAC,cAAC,CAAC,OAAO,CAAC,KAAK,CAAC;AAC9B,aAAa,CAAC,cAAC,CAAC,OAAO,CACrB,kBAAkB;AAClB,aAAa,CAAC,cAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,IAAI,CAAC,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC;CACnD,CAAC,CACH,CACF,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.uploadBlob'\n\nexport { $nsid }\n\n/** Upload a new blob, to be referenced from a repository record. The blob will be deleted if it is not referenced within a time window (eg, minutes). Blob restrictions (mimetype, size, etc) are enforced when the reference is created. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params({}),\n /*#__PURE__*/ l.payload('*/*'),\n /*#__PURE__*/ l.payload(\n 'application/json',\n /*#__PURE__*/ l.object({\n blob: /*#__PURE__*/ l.blob({ allowLegacy: false }),\n }),\n ),\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
1
+ {"version":3,"file":"uploadBlob.defs.js","sourceRoot":"","sources":["../../../../../src/lexicons/com/atproto/repo/uploadBlob.defs.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,oDAAuC;AAEvC,MAAM,KAAK,GAAG,6BAA6B,CAAA;AAElC,sBAAK;AAEd,gRAAgR;AAChR,MAAM,IAAI;AACR,aAAa;AACb,cAAC,CAAC,SAAS,CACT,KAAK;AACL,aAAa,CAAC,cAAC,CAAC,MAAM,EAAE;AACxB,aAAa,CAAC,cAAC,CAAC,OAAO,CAAC,KAAK,CAAC;AAC9B,aAAa,CAAC,cAAC,CAAC,WAAW,CAAC;IAC1B,IAAI,EAAE,aAAa,CAAC,cAAC,CAAC,IAAI,CAAC,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC;CACnD,CAAC,CACH,CAAA;AACM,oBAAI;AAQA,QAAA,IAAI,GAAiB,IAAI,CAAC,IAAI,EACzC,QAAA,OAAO,GAAiB,IAAI,CAAC,UAAU,EACvC,QAAA,MAAM,GAAiB,IAAI,CAAC,KAAK,EACjC,QAAA,OAAO,GAAiB,IAAI,CAAC,MAAM,CAAA","sourcesContent":["/*\n * THIS FILE WAS GENERATED BY \"@atproto/lex\". DO NOT EDIT.\n */\n\nimport { l } from '@atproto/lex-schema'\n\nconst $nsid = 'com.atproto.repo.uploadBlob'\n\nexport { $nsid }\n\n/** Upload a new blob, to be referenced from a repository record. The blob will be deleted if it is not referenced within a time window (eg, minutes). Blob restrictions (mimetype, size, etc) are enforced when the reference is created. Requires auth, implemented by PDS. */\nconst main =\n /*#__PURE__*/\n l.procedure(\n $nsid,\n /*#__PURE__*/ l.params(),\n /*#__PURE__*/ l.payload('*/*'),\n /*#__PURE__*/ l.jsonPayload({\n blob: /*#__PURE__*/ l.blob({ allowLegacy: false }),\n }),\n )\nexport { main }\n\nexport type Params = l.InferMethodParams<typeof main>\nexport type Input = l.InferMethodInput<typeof main>\nexport type InputBody = l.InferMethodInputBody<typeof main>\nexport type Output = l.InferMethodOutput<typeof main>\nexport type OutputBody = l.InferMethodOutputBody<typeof main>\n\nexport const $lxm = /*#__PURE__*/ main.nsid,\n $params = /*#__PURE__*/ main.parameters,\n $input = /*#__PURE__*/ main.input,\n $output = /*#__PURE__*/ main.output\n"]}
@@ -0,0 +1,2 @@
1
+ export * as com from './com.js';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/lexicons/index.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,GAAG,MAAM,UAAU,CAAA"}