@xata.io/client 0.0.0-alpha.vf9d4e41 → 0.0.0-alpha.vfaf51aa
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/CHANGELOG.md +82 -0
- package/README.md +265 -1
- package/Usage.md +380 -0
- package/dist/index.cjs +212 -78
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +299 -51
- package/dist/index.mjs +210 -79
- package/dist/index.mjs.map +1 -1
- package/package.json +7 -3
package/dist/index.d.ts
CHANGED
@@ -6,6 +6,9 @@ declare type FetchImpl = (url: string, init?: {
|
|
6
6
|
ok: boolean;
|
7
7
|
status: number;
|
8
8
|
json(): Promise<any>;
|
9
|
+
headers?: {
|
10
|
+
get(name: string): string | null;
|
11
|
+
};
|
9
12
|
}>;
|
10
13
|
declare type WorkspaceApiUrlBuilder = (path: string, pathParams: Record<string, string>) => string;
|
11
14
|
declare type FetcherExtraProps = {
|
@@ -268,6 +271,17 @@ declare type SortExpression = string[] | {
|
|
268
271
|
[key: string]: SortOrder;
|
269
272
|
}[];
|
270
273
|
declare type SortOrder = 'asc' | 'desc';
|
274
|
+
/**
|
275
|
+
* Maximum [Levenshtein distance](https://en.wikipedia.org/wiki/Levenshtein_distance) for the search terms. The Levenshtein
|
276
|
+
* distance is the number of one charcter changes needed to make two strings equal. The default is 1, meaning that single
|
277
|
+
* character typos per word are tollerated by search. You can set it to 0 to remove the typo tollerance or set it to 2
|
278
|
+
* to allow two typos in a word.
|
279
|
+
*
|
280
|
+
* @default 1
|
281
|
+
* @maximum 2
|
282
|
+
* @minimum 0
|
283
|
+
*/
|
284
|
+
declare type FuzzinessExpression = number;
|
271
285
|
/**
|
272
286
|
* @minProperties 1
|
273
287
|
*/
|
@@ -281,6 +295,10 @@ declare type FilterExpression = {
|
|
281
295
|
} & {
|
282
296
|
[key: string]: FilterColumn;
|
283
297
|
};
|
298
|
+
declare type HighlightExpression = {
|
299
|
+
enabled?: boolean;
|
300
|
+
encodeHTML?: boolean;
|
301
|
+
};
|
284
302
|
declare type FilterList = FilterExpression | FilterExpression[];
|
285
303
|
declare type FilterColumn = FilterColumnIncludes | FilterPredicate | FilterList;
|
286
304
|
/**
|
@@ -366,6 +384,11 @@ declare type XataRecord$1 = {
|
|
366
384
|
xata: {
|
367
385
|
version: number;
|
368
386
|
table?: string;
|
387
|
+
highlight?: {
|
388
|
+
[key: string]: string[] | {
|
389
|
+
[key: string]: any;
|
390
|
+
};
|
391
|
+
};
|
369
392
|
warnings?: string[];
|
370
393
|
};
|
371
394
|
} & {
|
@@ -409,7 +432,9 @@ type schemas_TableMigration = TableMigration;
|
|
409
432
|
type schemas_ColumnMigration = ColumnMigration;
|
410
433
|
type schemas_SortExpression = SortExpression;
|
411
434
|
type schemas_SortOrder = SortOrder;
|
435
|
+
type schemas_FuzzinessExpression = FuzzinessExpression;
|
412
436
|
type schemas_FilterExpression = FilterExpression;
|
437
|
+
type schemas_HighlightExpression = HighlightExpression;
|
413
438
|
type schemas_FilterList = FilterList;
|
414
439
|
type schemas_FilterColumn = FilterColumn;
|
415
440
|
type schemas_FilterColumnIncludes = FilterColumnIncludes;
|
@@ -462,7 +487,9 @@ declare namespace schemas {
|
|
462
487
|
schemas_ColumnMigration as ColumnMigration,
|
463
488
|
schemas_SortExpression as SortExpression,
|
464
489
|
schemas_SortOrder as SortOrder,
|
490
|
+
schemas_FuzzinessExpression as FuzzinessExpression,
|
465
491
|
schemas_FilterExpression as FilterExpression,
|
492
|
+
schemas_HighlightExpression as HighlightExpression,
|
466
493
|
schemas_FilterList as FilterList,
|
467
494
|
schemas_FilterColumn as FilterColumn,
|
468
495
|
schemas_FilterColumnIncludes as FilterColumnIncludes,
|
@@ -2262,12 +2289,18 @@ declare type QueryTableVariables = {
|
|
2262
2289
|
* {
|
2263
2290
|
* "filter": {
|
2264
2291
|
* "<column_name>": {
|
2265
|
-
* "$pattern": "v*
|
2292
|
+
* "$pattern": "v*alu?"
|
2266
2293
|
* }
|
2267
2294
|
* }
|
2268
2295
|
* }
|
2269
2296
|
* ```
|
2270
2297
|
*
|
2298
|
+
* The `$pattern` operator accepts two wildcard characters:
|
2299
|
+
* * `*` matches zero or more characters
|
2300
|
+
* * `?` matches exactly one character
|
2301
|
+
*
|
2302
|
+
* If you want to match a string that contains a wildcard character, you can escape them using a backslash (`\`). You can escape a backslash by usign another backslash.
|
2303
|
+
*
|
2271
2304
|
* We could also have `$endsWith` and `$startsWith` operators:
|
2272
2305
|
*
|
2273
2306
|
* ```json
|
@@ -2574,6 +2607,39 @@ declare type QueryTableVariables = {
|
|
2574
2607
|
* ```
|
2575
2608
|
*/
|
2576
2609
|
declare const queryTable: (variables: QueryTableVariables) => Promise<QueryResponse>;
|
2610
|
+
declare type SearchTablePathParams = {
|
2611
|
+
dbBranchName: DBBranchName;
|
2612
|
+
tableName: TableName;
|
2613
|
+
workspace: string;
|
2614
|
+
};
|
2615
|
+
declare type SearchTableError = ErrorWrapper<{
|
2616
|
+
status: 400;
|
2617
|
+
payload: BadRequestError;
|
2618
|
+
} | {
|
2619
|
+
status: 401;
|
2620
|
+
payload: AuthError;
|
2621
|
+
} | {
|
2622
|
+
status: 404;
|
2623
|
+
payload: SimpleError;
|
2624
|
+
}>;
|
2625
|
+
declare type SearchTableRequestBody = {
|
2626
|
+
query: string;
|
2627
|
+
fuzziness?: FuzzinessExpression;
|
2628
|
+
filter?: FilterExpression;
|
2629
|
+
highlight?: HighlightExpression;
|
2630
|
+
};
|
2631
|
+
declare type SearchTableVariables = {
|
2632
|
+
body: SearchTableRequestBody;
|
2633
|
+
pathParams: SearchTablePathParams;
|
2634
|
+
} & FetcherExtraProps;
|
2635
|
+
/**
|
2636
|
+
* Run a free text search operation in a particular table.
|
2637
|
+
*
|
2638
|
+
* The endpoint accepts a `query` parameter that is used for the free text search and a set of structured filters (via the `filter` parameter) that are applied before the search. The `filter` parameter uses the same syntax as the [query endpoint](/api-reference/db/db_branch_name/tables/table_name/) with the following exceptions:
|
2639
|
+
* * filters `$contains`, `$startsWith`, `$endsWith` don't work on columns of type `text`
|
2640
|
+
* * filtering on columns of type `multiple` is currently unsupported
|
2641
|
+
*/
|
2642
|
+
declare const searchTable: (variables: SearchTableVariables) => Promise<SearchResponse>;
|
2577
2643
|
declare type SearchBranchPathParams = {
|
2578
2644
|
dbBranchName: DBBranchName;
|
2579
2645
|
workspace: string;
|
@@ -2589,9 +2655,13 @@ declare type SearchBranchError = ErrorWrapper<{
|
|
2589
2655
|
payload: SimpleError;
|
2590
2656
|
}>;
|
2591
2657
|
declare type SearchBranchRequestBody = {
|
2592
|
-
tables?: string
|
2658
|
+
tables?: (string | {
|
2659
|
+
table: string;
|
2660
|
+
filter?: FilterExpression;
|
2661
|
+
})[];
|
2593
2662
|
query: string;
|
2594
|
-
fuzziness?:
|
2663
|
+
fuzziness?: FuzzinessExpression;
|
2664
|
+
highlight?: HighlightExpression;
|
2595
2665
|
};
|
2596
2666
|
declare type SearchBranchVariables = {
|
2597
2667
|
body: SearchBranchRequestBody;
|
@@ -2666,6 +2736,7 @@ declare const operationsByTag: {
|
|
2666
2736
|
getRecord: (variables: GetRecordVariables) => Promise<XataRecord$1>;
|
2667
2737
|
bulkInsertTableRecords: (variables: BulkInsertTableRecordsVariables) => Promise<BulkInsertTableRecordsResponse>;
|
2668
2738
|
queryTable: (variables: QueryTableVariables) => Promise<QueryResponse>;
|
2739
|
+
searchTable: (variables: SearchTableVariables) => Promise<SearchResponse>;
|
2669
2740
|
searchBranch: (variables: SearchBranchVariables) => Promise<SearchResponse>;
|
2670
2741
|
};
|
2671
2742
|
};
|
@@ -2730,7 +2801,7 @@ declare class DatabaseApi {
|
|
2730
2801
|
getGitBranchesMapping(workspace: WorkspaceID, dbName: DBName): Promise<ListGitBranchesResponse>;
|
2731
2802
|
addGitBranchesEntry(workspace: WorkspaceID, dbName: DBName, body: AddGitBranchesEntryRequestBody): Promise<AddGitBranchesEntryResponse>;
|
2732
2803
|
removeGitBranchesEntry(workspace: WorkspaceID, dbName: DBName, gitBranch: string): Promise<void>;
|
2733
|
-
resolveBranch(workspace: WorkspaceID, dbName: DBName, gitBranch
|
2804
|
+
resolveBranch(workspace: WorkspaceID, dbName: DBName, gitBranch?: string, fallbackBranch?: string): Promise<ResolveBranchResponse>;
|
2734
2805
|
}
|
2735
2806
|
declare class BranchApi {
|
2736
2807
|
private extraProps;
|
@@ -2771,6 +2842,7 @@ declare class RecordsApi {
|
|
2771
2842
|
getRecord(workspace: WorkspaceID, database: DBName, branch: BranchName, tableName: TableName, recordId: RecordID, options?: GetRecordRequestBody): Promise<XataRecord$1>;
|
2772
2843
|
bulkInsertTableRecords(workspace: WorkspaceID, database: DBName, branch: BranchName, tableName: TableName, records: Record<string, any>[]): Promise<BulkInsertTableRecordsResponse>;
|
2773
2844
|
queryTable(workspace: WorkspaceID, database: DBName, branch: BranchName, tableName: TableName, query: QueryTableRequestBody): Promise<QueryResponse>;
|
2845
|
+
searchTable(workspace: WorkspaceID, database: DBName, branch: BranchName, tableName: TableName, query: SearchTableRequestBody): Promise<SearchResponse>;
|
2774
2846
|
searchBranch(workspace: WorkspaceID, database: DBName, branch: BranchName, query: SearchBranchRequestBody): Promise<SearchResponse>;
|
2775
2847
|
}
|
2776
2848
|
|
@@ -2798,14 +2870,14 @@ declare type SelectableColumn<O, RecursivePath extends any[] = []> = '*' | 'id'
|
|
2798
2870
|
declare type SelectedPick<O extends XataRecord, Key extends SelectableColumn<O>[]> = XataRecord & UnionToIntersection<Values<{
|
2799
2871
|
[K in Key[number]]: NestedValueAtColumn<O, K> & XataRecord;
|
2800
2872
|
}>>;
|
2801
|
-
declare type ValueAtColumn<O, P extends SelectableColumn<O>> = P extends '*' ? Values<O> : P extends 'id' ? string : P extends keyof O ? O[P] : P extends `${infer K}.${infer V}` ? K extends keyof O ? Values<O[K] extends
|
2802
|
-
V: ValueAtColumn<
|
2803
|
-
} : never
|
2873
|
+
declare type ValueAtColumn<O, P extends SelectableColumn<O>> = P extends '*' ? Values<O> : P extends 'id' ? string : P extends keyof O ? O[P] : P extends `${infer K}.${infer V}` ? K extends keyof O ? Values<NonNullable<O[K]> extends infer Item ? Item extends Record<string, any> ? V extends SelectableColumn<Item> ? {
|
2874
|
+
V: ValueAtColumn<Item, V>;
|
2875
|
+
} : never : O[K] : never> : never : never;
|
2804
2876
|
declare type MAX_RECURSION = 5;
|
2805
2877
|
declare type NestedColumns<O, RecursivePath extends any[]> = RecursivePath['length'] extends MAX_RECURSION ? never : If<IsObject<O>, Values<{
|
2806
|
-
[K in DataProps<O>]:
|
2807
|
-
If<IsObject<
|
2808
|
-
K
|
2878
|
+
[K in DataProps<O>]: NonNullable<O[K]> extends infer Item ? If<IsArray<Item>, K, // If the property is an array, we stop recursion. We don't support object arrays yet
|
2879
|
+
If<IsObject<Item>, Item extends XataRecord ? SelectableColumn<Item, [...RecursivePath, Item]> extends infer Column ? Column extends string ? K | `${K}.${Column}` : never : never : Item extends Date ? K : `${K}.${StringKeys<Item> | '*'}`, // This allows usage of objects that are not links
|
2880
|
+
K>> : never;
|
2809
2881
|
}>, never>;
|
2810
2882
|
declare type DataProps<O> = Exclude<StringKeys<O>, StringKeys<XataRecord>>;
|
2811
2883
|
declare type NestedValueAtColumn<O, Key extends SelectableColumn<O>> = Key extends `${infer N}.${infer M}` ? N extends DataProps<O> ? {
|
@@ -2832,16 +2904,11 @@ interface BaseData {
|
|
2832
2904
|
/**
|
2833
2905
|
* Represents a persisted record from the database.
|
2834
2906
|
*/
|
2835
|
-
interface XataRecord extends Identifiable {
|
2907
|
+
interface XataRecord<ExtraMetadata extends Record<string, unknown> = Record<string, unknown>> extends Identifiable {
|
2836
2908
|
/**
|
2837
|
-
*
|
2909
|
+
* Get metadata of this record.
|
2838
2910
|
*/
|
2839
|
-
|
2840
|
-
/**
|
2841
|
-
* Number that is increased every time the record is updated.
|
2842
|
-
*/
|
2843
|
-
version: number;
|
2844
|
-
};
|
2911
|
+
getMetadata(): XataRecordMetadata & ExtraMetadata;
|
2845
2912
|
/**
|
2846
2913
|
* Retrieves a refreshed copy of the current record from the database.
|
2847
2914
|
*/
|
@@ -2849,7 +2916,7 @@ interface XataRecord extends Identifiable {
|
|
2849
2916
|
/**
|
2850
2917
|
* Performs a partial update of the current record. On success a new object is
|
2851
2918
|
* returned and the current object is not mutated.
|
2852
|
-
* @param
|
2919
|
+
* @param partialUpdate The columns and their values that have to be updated.
|
2853
2920
|
* @returns A new record containing the latest values for all the columns of the current record.
|
2854
2921
|
*/
|
2855
2922
|
update(partialUpdate: Partial<EditableData<Omit<this, keyof XataRecord>>>): Promise<Readonly<SelectedPick<this, ['*']>>>;
|
@@ -2868,19 +2935,26 @@ declare type Link<Record extends XataRecord> = Omit<XataRecord, 'read' | 'update
|
|
2868
2935
|
/**
|
2869
2936
|
* Performs a partial update of the current record. On success a new object is
|
2870
2937
|
* returned and the current object is not mutated.
|
2871
|
-
* @param
|
2938
|
+
* @param partialUpdate The columns and their values that have to be updated.
|
2872
2939
|
* @returns A new record containing the latest values for all the columns of the current record.
|
2873
2940
|
*/
|
2874
2941
|
update(partialUpdate: Partial<EditableData<Omit<Record, keyof XataRecord>>>): Promise<Readonly<SelectedPick<Record, ['*']>>>;
|
2875
2942
|
};
|
2943
|
+
declare type XataRecordMetadata = {
|
2944
|
+
/**
|
2945
|
+
* Number that is increased every time the record is updated.
|
2946
|
+
*/
|
2947
|
+
version: number;
|
2948
|
+
warnings?: string[];
|
2949
|
+
};
|
2876
2950
|
declare function isIdentifiable(x: any): x is Identifiable & Record<string, unknown>;
|
2877
2951
|
declare function isXataRecord(x: any): x is XataRecord & Record<string, unknown>;
|
2878
2952
|
declare type EditableData<O extends BaseData> = {
|
2879
2953
|
[K in keyof O]: O[K] extends XataRecord ? {
|
2880
2954
|
id: string;
|
2881
|
-
} : NonNullable<O[K]> extends XataRecord ? {
|
2955
|
+
} | string : NonNullable<O[K]> extends XataRecord ? {
|
2882
2956
|
id: string;
|
2883
|
-
} | null | undefined : O[K];
|
2957
|
+
} | string | null | undefined : O[K];
|
2884
2958
|
};
|
2885
2959
|
|
2886
2960
|
/**
|
@@ -2956,8 +3030,8 @@ declare type ValueTypeFilters<T> = T | T extends string ? StringTypeFilter : T e
|
|
2956
3030
|
],
|
2957
3031
|
}
|
2958
3032
|
*/
|
2959
|
-
declare type AggregatorFilter<
|
2960
|
-
[key in '$all' | '$any' | '$not' | '$none']?: SingleOrArray<Filter<
|
3033
|
+
declare type AggregatorFilter<T> = {
|
3034
|
+
[key in '$all' | '$any' | '$not' | '$none']?: SingleOrArray<Filter<T>>;
|
2961
3035
|
};
|
2962
3036
|
/**
|
2963
3037
|
* Existance filter
|
@@ -2972,10 +3046,10 @@ declare type BaseApiFilter<Record> = PropertyAccessFilter<Record> | AggregatorFi
|
|
2972
3046
|
* Injects the Api filters on nested properties
|
2973
3047
|
* Example: { filter: { settings: { plan: { $any: ['free', 'trial'] } } } }
|
2974
3048
|
*/
|
2975
|
-
declare type NestedApiFilter<T> =
|
3049
|
+
declare type NestedApiFilter<T> = {
|
2976
3050
|
[key in keyof T]?: T[key] extends Record<string, any> ? SingleOrArray<Filter<T[key]>> : PropertyFilter<T[key]>;
|
2977
|
-
}
|
2978
|
-
declare type Filter<
|
3051
|
+
};
|
3052
|
+
declare type Filter<T> = T extends Record<string, any> ? BaseApiFilter<T> | NestedApiFilter<T> : PropertyFilter<T>;
|
2979
3053
|
|
2980
3054
|
declare type SortDirection = 'asc' | 'desc';
|
2981
3055
|
declare type SortFilterExtended<T extends XataRecord> = {
|
@@ -3011,8 +3085,8 @@ declare type QueryOptions<T extends XataRecord> = BaseOptions<T> & (CursorQueryO
|
|
3011
3085
|
declare class Query<Record extends XataRecord, Result extends XataRecord = Record> implements Paginable<Record, Result> {
|
3012
3086
|
#private;
|
3013
3087
|
readonly meta: PaginationQueryMeta;
|
3014
|
-
readonly records: Result
|
3015
|
-
constructor(repository: Repository<Record> | null, table: string, data: Partial<QueryOptions<Record>>,
|
3088
|
+
readonly records: RecordArray<Result>;
|
3089
|
+
constructor(repository: Repository<Record> | null, table: string, data: Partial<QueryOptions<Record>>, rawParent?: Partial<QueryOptions<Record>>);
|
3016
3090
|
getQueryOptions(): QueryOptions<Record>;
|
3017
3091
|
key(): string;
|
3018
3092
|
/**
|
@@ -3044,18 +3118,28 @@ declare class Query<Record extends XataRecord, Result extends XataRecord = Recor
|
|
3044
3118
|
*
|
3045
3119
|
* ```
|
3046
3120
|
* query.filter("columnName", columnValue)
|
3047
|
-
* query.filter(
|
3048
|
-
*
|
3049
|
-
*
|
3121
|
+
* query.filter("columnName", operator(columnValue)) // Use gt, gte, lt, lte, startsWith,...
|
3122
|
+
* ```
|
3123
|
+
*
|
3124
|
+
* @param column The name of the column to filter.
|
3125
|
+
* @param value The value to filter.
|
3126
|
+
* @returns A new Query object.
|
3127
|
+
*/
|
3128
|
+
filter<F extends SelectableColumn<Record>>(column: F, value: Filter<ValueAtColumn<Record, F>>): Query<Record, Result>;
|
3129
|
+
/**
|
3130
|
+
* Builds a new query object adding one or more constraints. Examples:
|
3131
|
+
*
|
3132
|
+
* ```
|
3133
|
+
* query.filter({ "columnName": columnValue })
|
3050
3134
|
* query.filter({
|
3051
3135
|
* "columnName": operator(columnValue) // Use gt, gte, lt, lte, startsWith,...
|
3052
3136
|
* })
|
3053
3137
|
* ```
|
3054
3138
|
*
|
3139
|
+
* @param filters A filter object
|
3055
3140
|
* @returns A new Query object.
|
3056
3141
|
*/
|
3057
3142
|
filter(filters: Filter<Record>): Query<Record, Result>;
|
3058
|
-
filter<F extends SelectableColumn<Record>>(column: F, value: Filter<ValueAtColumn<Record, F>>): Query<Record, Result>;
|
3059
3143
|
/**
|
3060
3144
|
* Builds a new query with a new sort option.
|
3061
3145
|
* @param column The column name.
|
@@ -3069,45 +3153,114 @@ declare class Query<Record extends XataRecord, Result extends XataRecord = Recor
|
|
3069
3153
|
* @returns A new Query object.
|
3070
3154
|
*/
|
3071
3155
|
select<K extends SelectableColumn<Record>>(columns: NonEmptyArray<K>): Query<Record, SelectedPick<Record, NonEmptyArray<K>>>;
|
3156
|
+
/**
|
3157
|
+
* Get paginated results
|
3158
|
+
*
|
3159
|
+
* @returns A page of results
|
3160
|
+
*/
|
3072
3161
|
getPaginated(): Promise<Page<Record, Result>>;
|
3162
|
+
/**
|
3163
|
+
* Get paginated results
|
3164
|
+
*
|
3165
|
+
* @param options Pagination options
|
3166
|
+
* @returns A page of results
|
3167
|
+
*/
|
3073
3168
|
getPaginated(options: OmitBy<QueryOptions<Record>, 'columns'>): Promise<Page<Record, Result>>;
|
3169
|
+
/**
|
3170
|
+
* Get paginated results
|
3171
|
+
*
|
3172
|
+
* @param options Pagination options
|
3173
|
+
* @returns A page of results
|
3174
|
+
*/
|
3074
3175
|
getPaginated<Options extends RequiredBy<QueryOptions<Record>, 'columns'>>(options: Options): Promise<Page<Record, SelectedPick<Record, typeof options['columns']>>>;
|
3176
|
+
/**
|
3177
|
+
* Get results in an iterator
|
3178
|
+
*
|
3179
|
+
* @async
|
3180
|
+
* @returns Async interable of results
|
3181
|
+
*/
|
3075
3182
|
[Symbol.asyncIterator](): AsyncIterableIterator<Result>;
|
3183
|
+
/**
|
3184
|
+
* Build an iterator of results
|
3185
|
+
*
|
3186
|
+
* @returns Async generator of results array
|
3187
|
+
*/
|
3076
3188
|
getIterator(): AsyncGenerator<Result[]>;
|
3189
|
+
/**
|
3190
|
+
* Build an iterator of results
|
3191
|
+
*
|
3192
|
+
* @param options Pagination options with batchSize
|
3193
|
+
* @returns Async generator of results array
|
3194
|
+
*/
|
3077
3195
|
getIterator(options: OmitBy<QueryOptions<Record>, 'columns' | 'pagination'> & {
|
3078
3196
|
batchSize?: number;
|
3079
3197
|
}): AsyncGenerator<Result[]>;
|
3198
|
+
/**
|
3199
|
+
* Build an iterator of results
|
3200
|
+
*
|
3201
|
+
* @param options Pagination options with batchSize
|
3202
|
+
* @returns Async generator of results array
|
3203
|
+
*/
|
3080
3204
|
getIterator<Options extends RequiredBy<OmitBy<QueryOptions<Record>, 'pagination'>, 'columns'> & {
|
3081
3205
|
batchSize?: number;
|
3082
3206
|
}>(options: Options): AsyncGenerator<SelectedPick<Record, typeof options['columns']>[]>;
|
3207
|
+
/**
|
3208
|
+
* Performs the query in the database and returns a set of results.
|
3209
|
+
* @returns An array of records from the database.
|
3210
|
+
*/
|
3211
|
+
getMany(): Promise<RecordArray<Result>>;
|
3083
3212
|
/**
|
3084
3213
|
* Performs the query in the database and returns a set of results.
|
3085
3214
|
* @param options Additional options to be used when performing the query.
|
3086
3215
|
* @returns An array of records from the database.
|
3087
3216
|
*/
|
3088
|
-
getMany(): Promise<Result
|
3089
|
-
|
3090
|
-
|
3217
|
+
getMany(options: OmitBy<QueryOptions<Record>, 'columns'>): Promise<RecordArray<Result>>;
|
3218
|
+
/**
|
3219
|
+
* Performs the query in the database and returns a set of results.
|
3220
|
+
* @param options Additional options to be used when performing the query.
|
3221
|
+
* @returns An array of records from the database.
|
3222
|
+
*/
|
3223
|
+
getMany<Options extends RequiredBy<QueryOptions<Record>, 'columns'>>(options: Options): Promise<RecordArray<SelectedPick<Record, typeof options['columns']>>>;
|
3091
3224
|
/**
|
3092
3225
|
* Performs the query in the database and returns all the results.
|
3093
3226
|
* Warning: If there are a large number of results, this method can have performance implications.
|
3094
|
-
* @param options Additional options to be used when performing the query.
|
3095
3227
|
* @returns An array of records from the database.
|
3096
3228
|
*/
|
3097
3229
|
getAll(): Promise<Result[]>;
|
3230
|
+
/**
|
3231
|
+
* Performs the query in the database and returns all the results.
|
3232
|
+
* Warning: If there are a large number of results, this method can have performance implications.
|
3233
|
+
* @param options Additional options to be used when performing the query.
|
3234
|
+
* @returns An array of records from the database.
|
3235
|
+
*/
|
3098
3236
|
getAll(options: OmitBy<QueryOptions<Record>, 'columns' | 'pagination'> & {
|
3099
3237
|
batchSize?: number;
|
3100
3238
|
}): Promise<Result[]>;
|
3239
|
+
/**
|
3240
|
+
* Performs the query in the database and returns all the results.
|
3241
|
+
* Warning: If there are a large number of results, this method can have performance implications.
|
3242
|
+
* @param options Additional options to be used when performing the query.
|
3243
|
+
* @returns An array of records from the database.
|
3244
|
+
*/
|
3101
3245
|
getAll<Options extends RequiredBy<OmitBy<QueryOptions<Record>, 'pagination'>, 'columns'> & {
|
3102
3246
|
batchSize?: number;
|
3103
3247
|
}>(options: Options): Promise<SelectedPick<Record, typeof options['columns']>[]>;
|
3104
3248
|
/**
|
3105
3249
|
* Performs the query in the database and returns the first result.
|
3106
|
-
* @param options Additional options to be used when performing the query.
|
3107
3250
|
* @returns The first record that matches the query, or null if no record matched the query.
|
3108
3251
|
*/
|
3109
3252
|
getFirst(): Promise<Result | null>;
|
3253
|
+
/**
|
3254
|
+
* Performs the query in the database and returns the first result.
|
3255
|
+
* @param options Additional options to be used when performing the query.
|
3256
|
+
* @returns The first record that matches the query, or null if no record matched the query.
|
3257
|
+
*/
|
3110
3258
|
getFirst(options: OmitBy<QueryOptions<Record>, 'columns' | 'pagination'>): Promise<Result | null>;
|
3259
|
+
/**
|
3260
|
+
* Performs the query in the database and returns the first result.
|
3261
|
+
* @param options Additional options to be used when performing the query.
|
3262
|
+
* @returns The first record that matches the query, or null if no record matched the query.
|
3263
|
+
*/
|
3111
3264
|
getFirst<Options extends RequiredBy<OmitBy<QueryOptions<Record>, 'pagination'>, 'columns'>>(options: Options): Promise<SelectedPick<Record, typeof options['columns']> | null>;
|
3112
3265
|
/**
|
3113
3266
|
* Builds a new query object adding a cache TTL in milliseconds.
|
@@ -3115,10 +3268,33 @@ declare class Query<Record extends XataRecord, Result extends XataRecord = Recor
|
|
3115
3268
|
* @returns A new Query object.
|
3116
3269
|
*/
|
3117
3270
|
cache(ttl: number): Query<Record, Result>;
|
3271
|
+
/**
|
3272
|
+
* Retrieve next page of records
|
3273
|
+
*
|
3274
|
+
* @returns A new page object.
|
3275
|
+
*/
|
3118
3276
|
nextPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3277
|
+
/**
|
3278
|
+
* Retrieve previous page of records
|
3279
|
+
*
|
3280
|
+
* @returns A new page object
|
3281
|
+
*/
|
3119
3282
|
previousPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3283
|
+
/**
|
3284
|
+
* Retrieve first page of records
|
3285
|
+
*
|
3286
|
+
* @returns A new page object
|
3287
|
+
*/
|
3120
3288
|
firstPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3289
|
+
/**
|
3290
|
+
* Retrieve last page of records
|
3291
|
+
*
|
3292
|
+
* @returns A new page object
|
3293
|
+
*/
|
3121
3294
|
lastPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3295
|
+
/**
|
3296
|
+
* @returns Boolean indicating if there is a next page
|
3297
|
+
*/
|
3122
3298
|
hasNextPage(): boolean;
|
3123
3299
|
}
|
3124
3300
|
|
@@ -3130,7 +3306,7 @@ declare type PaginationQueryMeta = {
|
|
3130
3306
|
};
|
3131
3307
|
interface Paginable<Record extends XataRecord, Result extends XataRecord = Record> {
|
3132
3308
|
meta: PaginationQueryMeta;
|
3133
|
-
records: Result
|
3309
|
+
records: RecordArray<Result>;
|
3134
3310
|
nextPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3135
3311
|
previousPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
3136
3312
|
firstPage(size?: number, offset?: number): Promise<Page<Record, Result>>;
|
@@ -3150,7 +3326,7 @@ declare class Page<Record extends XataRecord, Result extends XataRecord = Record
|
|
3150
3326
|
/**
|
3151
3327
|
* The set of results for this page.
|
3152
3328
|
*/
|
3153
|
-
readonly records: Result
|
3329
|
+
readonly records: RecordArray<Result>;
|
3154
3330
|
constructor(query: Query<Record, Result>, meta: PaginationQueryMeta, records?: Result[]);
|
3155
3331
|
/**
|
3156
3332
|
* Retrieves the next page of results.
|
@@ -3199,9 +3375,42 @@ declare type OffsetNavigationOptions = {
|
|
3199
3375
|
offset?: number;
|
3200
3376
|
};
|
3201
3377
|
declare const PAGINATION_MAX_SIZE = 200;
|
3202
|
-
declare const PAGINATION_DEFAULT_SIZE =
|
3378
|
+
declare const PAGINATION_DEFAULT_SIZE = 20;
|
3203
3379
|
declare const PAGINATION_MAX_OFFSET = 800;
|
3204
3380
|
declare const PAGINATION_DEFAULT_OFFSET = 0;
|
3381
|
+
declare function isCursorPaginationOptions(options: Record<string, unknown> | undefined | null): options is CursorNavigationOptions;
|
3382
|
+
declare class RecordArray<Result extends XataRecord> extends Array<Result> {
|
3383
|
+
#private;
|
3384
|
+
constructor(page: Paginable<any, Result>, overrideRecords?: Result[]);
|
3385
|
+
/**
|
3386
|
+
* Retrieve next page of records
|
3387
|
+
*
|
3388
|
+
* @returns A new array of objects
|
3389
|
+
*/
|
3390
|
+
nextPage(size?: number, offset?: number): Promise<RecordArray<Result>>;
|
3391
|
+
/**
|
3392
|
+
* Retrieve previous page of records
|
3393
|
+
*
|
3394
|
+
* @returns A new array of objects
|
3395
|
+
*/
|
3396
|
+
previousPage(size?: number, offset?: number): Promise<RecordArray<Result>>;
|
3397
|
+
/**
|
3398
|
+
* Retrieve first page of records
|
3399
|
+
*
|
3400
|
+
* @returns A new array of objects
|
3401
|
+
*/
|
3402
|
+
firstPage(size?: number, offset?: number): Promise<RecordArray<Result>>;
|
3403
|
+
/**
|
3404
|
+
* Retrieve last page of records
|
3405
|
+
*
|
3406
|
+
* @returns A new array of objects
|
3407
|
+
*/
|
3408
|
+
lastPage(size?: number, offset?: number): Promise<RecordArray<Result>>;
|
3409
|
+
/**
|
3410
|
+
* @returns Boolean indicating if there is a next page
|
3411
|
+
*/
|
3412
|
+
hasNextPage(): boolean;
|
3413
|
+
}
|
3205
3414
|
|
3206
3415
|
/**
|
3207
3416
|
* Common interface for performing operations on a table.
|
@@ -3227,6 +3436,24 @@ declare abstract class Repository<Data extends BaseData, Record extends XataReco
|
|
3227
3436
|
* @returns The persisted record for the given id or null if the record could not be found.
|
3228
3437
|
*/
|
3229
3438
|
abstract read(id: string): Promise<Readonly<SelectedPick<Record, ['*']> | null>>;
|
3439
|
+
/**
|
3440
|
+
* Queries multiple records from the table given their unique id.
|
3441
|
+
* @param ids The unique ids array.
|
3442
|
+
* @returns The persisted records for the given ids (if a record could not be found it is not returned).
|
3443
|
+
*/
|
3444
|
+
abstract read(ids: string[]): Promise<Array<Readonly<SelectedPick<Record, ['*']>>>>;
|
3445
|
+
/**
|
3446
|
+
* Queries a single record from the table by the id in the object.
|
3447
|
+
* @param object Object containing the id of the record.
|
3448
|
+
* @returns The persisted record for the given id or null if the record could not be found.
|
3449
|
+
*/
|
3450
|
+
abstract read(object: Identifiable): Promise<Readonly<SelectedPick<Record, ['*']> | null>>;
|
3451
|
+
/**
|
3452
|
+
* Queries multiple records from the table by the ids in the objects.
|
3453
|
+
* @param objects Array of objects containing the ids of the records.
|
3454
|
+
* @returns The persisted records for the given ids (if a record could not be found it is not returned).
|
3455
|
+
*/
|
3456
|
+
abstract read(objects: Identifiable[]): Promise<Array<Readonly<SelectedPick<Record, ['*']>>>>;
|
3230
3457
|
/**
|
3231
3458
|
* Partially update a single record.
|
3232
3459
|
* @param object An object with its id and the columns to be updated.
|
@@ -3299,7 +3526,9 @@ declare abstract class Repository<Data extends BaseData, Record extends XataReco
|
|
3299
3526
|
* @returns The found records.
|
3300
3527
|
*/
|
3301
3528
|
abstract search(query: string, options?: {
|
3302
|
-
fuzziness?:
|
3529
|
+
fuzziness?: FuzzinessExpression;
|
3530
|
+
highlight?: HighlightExpression;
|
3531
|
+
filter?: Filter<Record>;
|
3303
3532
|
}): Promise<SelectedPick<Record, ['*']>[]>;
|
3304
3533
|
abstract query<Result extends XataRecord>(query: Query<Record, Result>): Promise<Page<Record, Result>>;
|
3305
3534
|
}
|
@@ -3315,6 +3544,9 @@ declare class RestRepository<Data extends BaseData, Record extends XataRecord =
|
|
3315
3544
|
create(recordId: string, object: EditableData<Data>): Promise<SelectedPick<Record, ['*']>>;
|
3316
3545
|
create(objects: EditableData<Data>[]): Promise<SelectedPick<Record, ['*']>[]>;
|
3317
3546
|
read(recordId: string): Promise<SelectedPick<Record, ['*']> | null>;
|
3547
|
+
read(recordIds: string[]): Promise<Array<Readonly<SelectedPick<Record, ['*']>>>>;
|
3548
|
+
read(object: Identifiable): Promise<SelectedPick<Record, ['*']> | null>;
|
3549
|
+
read(objects: Identifiable[]): Promise<Array<Readonly<SelectedPick<Record, ['*']>>>>;
|
3318
3550
|
update(object: Partial<EditableData<Data>> & Identifiable): Promise<SelectedPick<Record, ['*']>>;
|
3319
3551
|
update(recordId: string, object: Partial<EditableData<Data>>): Promise<SelectedPick<Record, ['*']>>;
|
3320
3552
|
update(objects: Array<Partial<EditableData<Data>> & Identifiable>): Promise<SelectedPick<Record, ['*']>[]>;
|
@@ -3323,7 +3555,9 @@ declare class RestRepository<Data extends BaseData, Record extends XataRecord =
|
|
3323
3555
|
createOrUpdate(objects: EditableData<Data>[]): Promise<SelectedPick<Record, ['*']>[]>;
|
3324
3556
|
delete(a: string | Identifiable | Array<string | Identifiable>): Promise<void>;
|
3325
3557
|
search(query: string, options?: {
|
3326
|
-
fuzziness?:
|
3558
|
+
fuzziness?: FuzzinessExpression;
|
3559
|
+
highlight?: HighlightExpression;
|
3560
|
+
filter?: Filter<Record>;
|
3327
3561
|
}): Promise<SelectedPick<Record, ['*']>[]>;
|
3328
3562
|
query<Result extends XataRecord>(query: Query<Record, Result>): Promise<Page<Record, Result>>;
|
3329
3563
|
}
|
@@ -3417,18 +3651,24 @@ declare class SchemaPlugin<Schemas extends Record<string, BaseData>> extends Xat
|
|
3417
3651
|
}
|
3418
3652
|
|
3419
3653
|
declare type SearchOptions<Schemas extends Record<string, BaseData>, Tables extends StringKeys<Schemas>> = {
|
3420
|
-
fuzziness?:
|
3421
|
-
|
3654
|
+
fuzziness?: FuzzinessExpression;
|
3655
|
+
highlight?: HighlightExpression;
|
3656
|
+
tables?: Array<Tables | Values<{
|
3657
|
+
[Model in GetArrayInnerType<NonNullable<Tables[]>>]: {
|
3658
|
+
table: Model;
|
3659
|
+
filter?: Filter<SelectedPick<Schemas[Model] & SearchXataRecord, ['*']>>;
|
3660
|
+
};
|
3661
|
+
}>>;
|
3422
3662
|
};
|
3423
3663
|
declare type SearchPluginResult<Schemas extends Record<string, BaseData>> = {
|
3424
3664
|
all: <Tables extends StringKeys<Schemas>>(query: string, options?: SearchOptions<Schemas, Tables>) => Promise<Values<{
|
3425
|
-
[Model in GetArrayInnerType<NonNullable<NonNullable<typeof options>['tables']
|
3665
|
+
[Model in ExtractTables<Schemas, Tables, GetArrayInnerType<NonNullable<NonNullable<typeof options>['tables']>>>]: {
|
3426
3666
|
table: Model;
|
3427
3667
|
record: Awaited<SelectedPick<Schemas[Model] & SearchXataRecord, ['*']>>;
|
3428
3668
|
};
|
3429
3669
|
}>[]>;
|
3430
3670
|
byTable: <Tables extends StringKeys<Schemas>>(query: string, options?: SearchOptions<Schemas, Tables>) => Promise<{
|
3431
|
-
[Model in GetArrayInnerType<NonNullable<NonNullable<typeof options>['tables']
|
3671
|
+
[Model in ExtractTables<Schemas, Tables, GetArrayInnerType<NonNullable<NonNullable<typeof options>['tables']>>>]?: Awaited<SelectedPick<Schemas[Model] & SearchXataRecord, ['*']>[]>;
|
3432
3672
|
}>;
|
3433
3673
|
};
|
3434
3674
|
declare class SearchPlugin<Schemas extends Record<string, BaseData>> extends XataPlugin {
|
@@ -3437,11 +3677,19 @@ declare class SearchPlugin<Schemas extends Record<string, BaseData>> extends Xat
|
|
3437
3677
|
constructor(db: SchemaPluginResult<Schemas>);
|
3438
3678
|
build({ getFetchProps }: XataPluginOptions): SearchPluginResult<Schemas>;
|
3439
3679
|
}
|
3440
|
-
declare type SearchXataRecord = XataRecord
|
3441
|
-
|
3442
|
-
|
3680
|
+
declare type SearchXataRecord = XataRecord<SearchExtraProperties>;
|
3681
|
+
declare type SearchExtraProperties = {
|
3682
|
+
table: string;
|
3683
|
+
highlight?: {
|
3684
|
+
[key: string]: string[] | {
|
3685
|
+
[key: string]: any;
|
3686
|
+
};
|
3443
3687
|
};
|
3444
3688
|
};
|
3689
|
+
declare type ReturnTable<Table, Tables> = Table extends Tables ? Table : never;
|
3690
|
+
declare type ExtractTables<Schemas extends Record<string, BaseData>, Tables extends StringKeys<Schemas>, TableOptions extends GetArrayInnerType<NonNullable<NonNullable<SearchOptions<Schemas, Tables>>['tables']>>> = TableOptions extends `${infer Table}` ? ReturnTable<Table, Tables> : TableOptions extends {
|
3691
|
+
table: infer Table;
|
3692
|
+
} ? ReturnTable<Table, Tables> : never;
|
3445
3693
|
|
3446
3694
|
declare type BranchStrategyValue = string | undefined | null;
|
3447
3695
|
declare type BranchStrategyBuilder = () => BranchStrategyValue | Promise<BranchStrategyValue>;
|
@@ -3484,4 +3732,4 @@ declare class XataError extends Error {
|
|
3484
3732
|
constructor(message: string, status: number);
|
3485
3733
|
}
|
3486
3734
|
|
3487
|
-
export { AcceptWorkspaceMemberInviteError, AcceptWorkspaceMemberInvitePathParams, AcceptWorkspaceMemberInviteVariables, AddGitBranchesEntryError, AddGitBranchesEntryPathParams, AddGitBranchesEntryRequestBody, AddGitBranchesEntryResponse, AddGitBranchesEntryVariables, AddTableColumnError, AddTableColumnPathParams, AddTableColumnVariables, BaseClient, BaseClientOptions, BaseData, BulkInsertTableRecordsError, BulkInsertTableRecordsPathParams, BulkInsertTableRecordsRequestBody, BulkInsertTableRecordsResponse, BulkInsertTableRecordsVariables, CacheImpl, CancelWorkspaceMemberInviteError, CancelWorkspaceMemberInvitePathParams, CancelWorkspaceMemberInviteVariables, ClientConstructor, CreateBranchError, CreateBranchPathParams, CreateBranchQueryParams, CreateBranchRequestBody, CreateBranchVariables, CreateDatabaseError, CreateDatabasePathParams, CreateDatabaseRequestBody, CreateDatabaseResponse, CreateDatabaseVariables, CreateTableError, CreateTablePathParams, CreateTableVariables, CreateUserAPIKeyError, CreateUserAPIKeyPathParams, CreateUserAPIKeyResponse, CreateUserAPIKeyVariables, CreateWorkspaceError, CreateWorkspaceVariables, CursorNavigationOptions, DeleteBranchError, DeleteBranchPathParams, DeleteBranchVariables, DeleteColumnError, DeleteColumnPathParams, DeleteColumnVariables, DeleteDatabaseError, DeleteDatabasePathParams, DeleteDatabaseVariables, DeleteRecordError, DeleteRecordPathParams, DeleteRecordVariables, DeleteTableError, DeleteTablePathParams, DeleteTableVariables, DeleteUserAPIKeyError, DeleteUserAPIKeyPathParams, DeleteUserAPIKeyVariables, DeleteUserError, DeleteUserVariables, DeleteWorkspaceError, DeleteWorkspacePathParams, DeleteWorkspaceVariables, EditableData, ExecuteBranchMigrationPlanError, ExecuteBranchMigrationPlanPathParams, ExecuteBranchMigrationPlanRequestBody, ExecuteBranchMigrationPlanVariables, FetchImpl, FetcherExtraProps, GetBranchDetailsError, GetBranchDetailsPathParams, GetBranchDetailsVariables, GetBranchListError, GetBranchListPathParams, GetBranchListVariables, GetBranchMetadataError, GetBranchMetadataPathParams, GetBranchMetadataVariables, GetBranchMigrationHistoryError, GetBranchMigrationHistoryPathParams, GetBranchMigrationHistoryRequestBody, GetBranchMigrationHistoryResponse, GetBranchMigrationHistoryVariables, GetBranchMigrationPlanError, GetBranchMigrationPlanPathParams, GetBranchMigrationPlanVariables, GetBranchStatsError, GetBranchStatsPathParams, GetBranchStatsResponse, GetBranchStatsVariables, GetColumnError, GetColumnPathParams, GetColumnVariables, GetDatabaseListError, GetDatabaseListPathParams, GetDatabaseListVariables, GetGitBranchesMappingError, GetGitBranchesMappingPathParams, GetGitBranchesMappingVariables, GetRecordError, GetRecordPathParams, GetRecordRequestBody, GetRecordVariables, GetTableColumnsError, GetTableColumnsPathParams, GetTableColumnsResponse, GetTableColumnsVariables, GetTableSchemaError, GetTableSchemaPathParams, GetTableSchemaResponse, GetTableSchemaVariables, GetUserAPIKeysError, GetUserAPIKeysResponse, GetUserAPIKeysVariables, GetUserError, GetUserVariables, GetWorkspaceError, GetWorkspaceMembersListError, GetWorkspaceMembersListPathParams, GetWorkspaceMembersListVariables, GetWorkspacePathParams, GetWorkspaceVariables, GetWorkspacesListError, GetWorkspacesListResponse, GetWorkspacesListVariables, Identifiable, InsertRecordError, InsertRecordPathParams, InsertRecordResponse, InsertRecordVariables, InsertRecordWithIDError, InsertRecordWithIDPathParams, InsertRecordWithIDQueryParams, InsertRecordWithIDVariables, InviteWorkspaceMemberError, InviteWorkspaceMemberPathParams, InviteWorkspaceMemberRequestBody, InviteWorkspaceMemberVariables, OffsetNavigationOptions, operationsByTag as Operations, PAGINATION_DEFAULT_OFFSET, PAGINATION_DEFAULT_SIZE, PAGINATION_MAX_OFFSET, PAGINATION_MAX_SIZE, Page, Paginable, PaginationQueryMeta, Query, QueryTableError, QueryTablePathParams, QueryTableRequestBody, QueryTableVariables, RemoveGitBranchesEntryError, RemoveGitBranchesEntryPathParams, RemoveGitBranchesEntryQueryParams, RemoveGitBranchesEntryVariables, RemoveWorkspaceMemberError, RemoveWorkspaceMemberPathParams, RemoveWorkspaceMemberVariables, Repository, ResendWorkspaceMemberInviteError, ResendWorkspaceMemberInvitePathParams, ResendWorkspaceMemberInviteVariables, ResolveBranchError, ResolveBranchPathParams, ResolveBranchQueryParams, ResolveBranchResponse, ResolveBranchVariables, responses as Responses, RestRepository, SchemaDefinition, SchemaPlugin, SchemaPluginResult, schemas as Schemas, SearchBranchError, SearchBranchPathParams, SearchBranchRequestBody, SearchBranchVariables, SearchOptions, SearchPlugin, SearchPluginResult, SelectableColumn, SelectedPick, SetTableSchemaError, SetTableSchemaPathParams, SetTableSchemaRequestBody, SetTableSchemaVariables, SimpleCache, SimpleCacheOptions, UpdateBranchMetadataError, UpdateBranchMetadataPathParams, UpdateBranchMetadataVariables, UpdateColumnError, UpdateColumnPathParams, UpdateColumnRequestBody, UpdateColumnVariables, UpdateRecordWithIDError, UpdateRecordWithIDPathParams, UpdateRecordWithIDQueryParams, UpdateRecordWithIDVariables, UpdateTableError, UpdateTablePathParams, UpdateTableRequestBody, UpdateTableVariables, UpdateUserError, UpdateUserVariables, UpdateWorkspaceError, UpdateWorkspaceMemberRoleError, UpdateWorkspaceMemberRolePathParams, UpdateWorkspaceMemberRoleRequestBody, UpdateWorkspaceMemberRoleVariables, UpdateWorkspacePathParams, UpdateWorkspaceVariables, UpsertRecordWithIDError, UpsertRecordWithIDPathParams, UpsertRecordWithIDQueryParams, UpsertRecordWithIDVariables, ValueAtColumn, XataApiClient, XataApiClientOptions, XataApiPlugin, XataError, XataPlugin, XataPluginOptions, XataRecord, acceptWorkspaceMemberInvite, addGitBranchesEntry, addTableColumn, buildClient, bulkInsertTableRecords, cancelWorkspaceMemberInvite, contains, createBranch, createDatabase, createTable, createUserAPIKey, createWorkspace, deleteBranch, deleteColumn, deleteDatabase, deleteRecord, deleteTable, deleteUser, deleteUserAPIKey, deleteWorkspace, endsWith, executeBranchMigrationPlan, exists, ge, getAPIKey, getBranchDetails, getBranchList, getBranchMetadata, getBranchMigrationHistory, getBranchMigrationPlan, getBranchStats, getColumn, getCurrentBranchDetails, getCurrentBranchName, getDatabaseList, getDatabaseURL, getGitBranchesMapping, getRecord, getTableColumns, getTableSchema, getUser, getUserAPIKeys, getWorkspace, getWorkspaceMembersList, getWorkspacesList, gt, gte, includes, includesAll, includesAny, includesNone, insertRecord, insertRecordWithID, inviteWorkspaceMember, is, isIdentifiable, isNot, isXataRecord, le, lt, lte, notExists, operationsByTag, pattern, queryTable, removeGitBranchesEntry, removeWorkspaceMember, resendWorkspaceMemberInvite, resolveBranch, searchBranch, setTableSchema, startsWith, updateBranchMetadata, updateColumn, updateRecordWithID, updateTable, updateUser, updateWorkspace, updateWorkspaceMemberRole, upsertRecordWithID };
|
3735
|
+
export { AcceptWorkspaceMemberInviteError, AcceptWorkspaceMemberInvitePathParams, AcceptWorkspaceMemberInviteVariables, AddGitBranchesEntryError, AddGitBranchesEntryPathParams, AddGitBranchesEntryRequestBody, AddGitBranchesEntryResponse, AddGitBranchesEntryVariables, AddTableColumnError, AddTableColumnPathParams, AddTableColumnVariables, BaseClient, BaseClientOptions, BaseData, BulkInsertTableRecordsError, BulkInsertTableRecordsPathParams, BulkInsertTableRecordsRequestBody, BulkInsertTableRecordsResponse, BulkInsertTableRecordsVariables, CacheImpl, CancelWorkspaceMemberInviteError, CancelWorkspaceMemberInvitePathParams, CancelWorkspaceMemberInviteVariables, ClientConstructor, CreateBranchError, CreateBranchPathParams, CreateBranchQueryParams, CreateBranchRequestBody, CreateBranchVariables, CreateDatabaseError, CreateDatabasePathParams, CreateDatabaseRequestBody, CreateDatabaseResponse, CreateDatabaseVariables, CreateTableError, CreateTablePathParams, CreateTableVariables, CreateUserAPIKeyError, CreateUserAPIKeyPathParams, CreateUserAPIKeyResponse, CreateUserAPIKeyVariables, CreateWorkspaceError, CreateWorkspaceVariables, CursorNavigationOptions, DeleteBranchError, DeleteBranchPathParams, DeleteBranchVariables, DeleteColumnError, DeleteColumnPathParams, DeleteColumnVariables, DeleteDatabaseError, DeleteDatabasePathParams, DeleteDatabaseVariables, DeleteRecordError, DeleteRecordPathParams, DeleteRecordVariables, DeleteTableError, DeleteTablePathParams, DeleteTableVariables, DeleteUserAPIKeyError, DeleteUserAPIKeyPathParams, DeleteUserAPIKeyVariables, DeleteUserError, DeleteUserVariables, DeleteWorkspaceError, DeleteWorkspacePathParams, DeleteWorkspaceVariables, EditableData, ExecuteBranchMigrationPlanError, ExecuteBranchMigrationPlanPathParams, ExecuteBranchMigrationPlanRequestBody, ExecuteBranchMigrationPlanVariables, FetchImpl, FetcherExtraProps, GetBranchDetailsError, GetBranchDetailsPathParams, GetBranchDetailsVariables, GetBranchListError, GetBranchListPathParams, GetBranchListVariables, GetBranchMetadataError, GetBranchMetadataPathParams, GetBranchMetadataVariables, GetBranchMigrationHistoryError, GetBranchMigrationHistoryPathParams, GetBranchMigrationHistoryRequestBody, GetBranchMigrationHistoryResponse, GetBranchMigrationHistoryVariables, GetBranchMigrationPlanError, GetBranchMigrationPlanPathParams, GetBranchMigrationPlanVariables, GetBranchStatsError, GetBranchStatsPathParams, GetBranchStatsResponse, GetBranchStatsVariables, GetColumnError, GetColumnPathParams, GetColumnVariables, GetDatabaseListError, GetDatabaseListPathParams, GetDatabaseListVariables, GetGitBranchesMappingError, GetGitBranchesMappingPathParams, GetGitBranchesMappingVariables, GetRecordError, GetRecordPathParams, GetRecordRequestBody, GetRecordVariables, GetTableColumnsError, GetTableColumnsPathParams, GetTableColumnsResponse, GetTableColumnsVariables, GetTableSchemaError, GetTableSchemaPathParams, GetTableSchemaResponse, GetTableSchemaVariables, GetUserAPIKeysError, GetUserAPIKeysResponse, GetUserAPIKeysVariables, GetUserError, GetUserVariables, GetWorkspaceError, GetWorkspaceMembersListError, GetWorkspaceMembersListPathParams, GetWorkspaceMembersListVariables, GetWorkspacePathParams, GetWorkspaceVariables, GetWorkspacesListError, GetWorkspacesListResponse, GetWorkspacesListVariables, Identifiable, InsertRecordError, InsertRecordPathParams, InsertRecordResponse, InsertRecordVariables, InsertRecordWithIDError, InsertRecordWithIDPathParams, InsertRecordWithIDQueryParams, InsertRecordWithIDVariables, InviteWorkspaceMemberError, InviteWorkspaceMemberPathParams, InviteWorkspaceMemberRequestBody, InviteWorkspaceMemberVariables, OffsetNavigationOptions, operationsByTag as Operations, PAGINATION_DEFAULT_OFFSET, PAGINATION_DEFAULT_SIZE, PAGINATION_MAX_OFFSET, PAGINATION_MAX_SIZE, Page, Paginable, PaginationQueryMeta, Query, QueryTableError, QueryTablePathParams, QueryTableRequestBody, QueryTableVariables, RecordArray, RemoveGitBranchesEntryError, RemoveGitBranchesEntryPathParams, RemoveGitBranchesEntryQueryParams, RemoveGitBranchesEntryVariables, RemoveWorkspaceMemberError, RemoveWorkspaceMemberPathParams, RemoveWorkspaceMemberVariables, Repository, ResendWorkspaceMemberInviteError, ResendWorkspaceMemberInvitePathParams, ResendWorkspaceMemberInviteVariables, ResolveBranchError, ResolveBranchPathParams, ResolveBranchQueryParams, ResolveBranchResponse, ResolveBranchVariables, responses as Responses, RestRepository, SchemaDefinition, SchemaPlugin, SchemaPluginResult, schemas as Schemas, SearchBranchError, SearchBranchPathParams, SearchBranchRequestBody, SearchBranchVariables, SearchOptions, SearchPlugin, SearchPluginResult, SearchTableError, SearchTablePathParams, SearchTableRequestBody, SearchTableVariables, SelectableColumn, SelectedPick, SetTableSchemaError, SetTableSchemaPathParams, SetTableSchemaRequestBody, SetTableSchemaVariables, SimpleCache, SimpleCacheOptions, UpdateBranchMetadataError, UpdateBranchMetadataPathParams, UpdateBranchMetadataVariables, UpdateColumnError, UpdateColumnPathParams, UpdateColumnRequestBody, UpdateColumnVariables, UpdateRecordWithIDError, UpdateRecordWithIDPathParams, UpdateRecordWithIDQueryParams, UpdateRecordWithIDVariables, UpdateTableError, UpdateTablePathParams, UpdateTableRequestBody, UpdateTableVariables, UpdateUserError, UpdateUserVariables, UpdateWorkspaceError, UpdateWorkspaceMemberRoleError, UpdateWorkspaceMemberRolePathParams, UpdateWorkspaceMemberRoleRequestBody, UpdateWorkspaceMemberRoleVariables, UpdateWorkspacePathParams, UpdateWorkspaceVariables, UpsertRecordWithIDError, UpsertRecordWithIDPathParams, UpsertRecordWithIDQueryParams, UpsertRecordWithIDVariables, ValueAtColumn, XataApiClient, XataApiClientOptions, XataApiPlugin, XataError, XataPlugin, XataPluginOptions, XataRecord, acceptWorkspaceMemberInvite, addGitBranchesEntry, addTableColumn, buildClient, bulkInsertTableRecords, cancelWorkspaceMemberInvite, contains, createBranch, createDatabase, createTable, createUserAPIKey, createWorkspace, deleteBranch, deleteColumn, deleteDatabase, deleteRecord, deleteTable, deleteUser, deleteUserAPIKey, deleteWorkspace, endsWith, executeBranchMigrationPlan, exists, ge, getAPIKey, getBranchDetails, getBranchList, getBranchMetadata, getBranchMigrationHistory, getBranchMigrationPlan, getBranchStats, getColumn, getCurrentBranchDetails, getCurrentBranchName, getDatabaseList, getDatabaseURL, getGitBranchesMapping, getRecord, getTableColumns, getTableSchema, getUser, getUserAPIKeys, getWorkspace, getWorkspaceMembersList, getWorkspacesList, gt, gte, includes, includesAll, includesAny, includesNone, insertRecord, insertRecordWithID, inviteWorkspaceMember, is, isCursorPaginationOptions, isIdentifiable, isNot, isXataRecord, le, lt, lte, notExists, operationsByTag, pattern, queryTable, removeGitBranchesEntry, removeWorkspaceMember, resendWorkspaceMemberInvite, resolveBranch, searchBranch, searchTable, setTableSchema, startsWith, updateBranchMetadata, updateColumn, updateRecordWithID, updateTable, updateUser, updateWorkspace, updateWorkspaceMemberRole, upsertRecordWithID };
|