@budibase/types 3.2.37 → 3.2.39

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.
@@ -38,6 +38,10 @@ export interface ExecuteQueryRequest {
38
38
  export type ExecuteV1QueryResponse = Record<string, any>[];
39
39
  export interface ExecuteV2QueryResponse {
40
40
  data: Record<string, any>[];
41
+ pagination?: {
42
+ page: number;
43
+ cursor: string;
44
+ };
41
45
  }
42
46
  export interface DeleteQueryResponse {
43
47
  message: string;
@@ -14,5 +14,5 @@ export interface GetGlobalSelfResponse extends User {
14
14
  license: License;
15
15
  budibaseAccess: boolean;
16
16
  accountPortalAccess: boolean;
17
- csrfToken: boolean;
17
+ csrfToken: string;
18
18
  }
@@ -20,4 +20,5 @@ export interface PaginationRequest extends BasicPaginationRequest {
20
20
  export interface PaginationResponse {
21
21
  bookmark: string | number | undefined;
22
22
  hasNextPage?: boolean;
23
+ totalRows?: number;
23
24
  }
@@ -1,4 +1,5 @@
1
1
  import { Document } from "../document";
2
+ import { Row } from "./row";
2
3
  export interface QuerySchema {
3
4
  name?: string;
4
5
  type: string;
@@ -11,6 +12,7 @@ export interface Query extends Document {
11
12
  fields: RestQueryFields | any;
12
13
  transformer: string | null;
13
14
  schema: Record<string, QuerySchema | string>;
15
+ nestedSchemaFields?: Record<string, Record<string, QuerySchema | string>>;
14
16
  readable: boolean;
15
17
  queryVerb: string;
16
18
  nullDefaultSupport?: boolean;
@@ -23,7 +25,7 @@ export interface QueryParameter {
23
25
  default: string;
24
26
  }
25
27
  export interface QueryResponse {
26
- rows: any[];
28
+ rows: Row[];
27
29
  keys: string[];
28
30
  info: any;
29
31
  extra: any;
@@ -26,7 +26,5 @@ export interface ScreenRoutesViewOutput extends Document {
26
26
  routing: ScreenRouting;
27
27
  }
28
28
  export type ScreenRoutingJson = Record<string, {
29
- subpaths: Record<string, {
30
- screens: Record<string, string>;
31
- }>;
29
+ subpaths: Record<string, any>;
32
30
  }>;
@@ -87,7 +87,7 @@ export interface AIFieldMetadata extends BaseFieldSchema {
87
87
  operation: AIOperationEnum;
88
88
  columns?: string[];
89
89
  column?: string;
90
- categories?: string[];
90
+ categories?: string;
91
91
  prompt?: string;
92
92
  language?: string;
93
93
  }
@@ -160,7 +160,7 @@ interface BaseFieldSchema extends UIFieldMetadata {
160
160
  subtype?: never;
161
161
  }
162
162
  interface OtherFieldMetadata extends BaseFieldSchema {
163
- type: Exclude<FieldType, FieldType.DATETIME | FieldType.LINK | FieldType.AUTO | FieldType.FORMULA | FieldType.AI | FieldType.NUMBER | FieldType.LONGFORM | FieldType.BB_REFERENCE | FieldType.BB_REFERENCE_SINGLE | FieldType.ATTACHMENTS | FieldType.STRING | FieldType.ARRAY | FieldType.OPTIONS | FieldType.BOOLEAN | FieldType.BIGINT>;
163
+ type: Exclude<FieldType, FieldType.DATETIME | FieldType.LINK | FieldType.AUTO | FieldType.FORMULA | FieldType.AI | FieldType.NUMBER | FieldType.LONGFORM | FieldType.BB_REFERENCE | FieldType.BB_REFERENCE_SINGLE | FieldType.ATTACHMENTS | FieldType.STRING | FieldType.ARRAY | FieldType.OPTIONS | FieldType.BOOLEAN | FieldType.BIGINT | FieldType.JSON>;
164
164
  }
165
165
  export type FieldSchema = OtherFieldMetadata | DateFieldMetadata | RelationshipFieldMetadata | AutoColumnFieldMetadata | FormulaFieldMetadata | AIFieldMetadata | NumberFieldMetadata | LongFormFieldMetadata | StringFieldMetadata | BBReferenceFieldMetadata | JsonFieldMetadata | AttachmentFieldMetadata | BBReferenceSingleFieldMetadata | ArrayFieldMetadata | OptionsFieldMetadata | BooleanFieldMetadata | BigIntFieldMetadata;
166
166
  export interface TableSchema {
@@ -36,6 +36,7 @@ export interface SettingsInnerConfig {
36
36
  platformUrl?: string;
37
37
  company?: string;
38
38
  logoUrl?: string;
39
+ docsUrl?: string;
39
40
  logoUrlEtag?: string;
40
41
  uniqueTenantId?: string;
41
42
  analyticsEnabled?: boolean;
package/dist/index.js CHANGED
@@ -847,19 +847,14 @@ var TenantResolutionStrategy = /* @__PURE__ */ ((TenantResolutionStrategy2) => {
847
847
 
848
848
  // src/sdk/featureFlag.ts
849
849
  var FeatureFlag = /* @__PURE__ */ ((FeatureFlag2) => {
850
- FeatureFlag2["AUTOMATION_BRANCHING"] = "AUTOMATION_BRANCHING";
851
- FeatureFlag2["AI_CUSTOM_CONFIGS"] = "AI_CUSTOM_CONFIGS";
852
- FeatureFlag2["DEFAULT_VALUES"] = "DEFAULT_VALUES";
853
- FeatureFlag2["BUDIBASE_AI"] = "BUDIBASE_AI";
854
850
  FeatureFlag2["USE_ZOD_VALIDATOR"] = "USE_ZOD_VALIDATOR";
851
+ FeatureFlag2["DIRECT_LOGIN_TO_ACCOUNT_PORTAL"] = "DIRECT_LOGIN_TO_ACCOUNT_PORTAL";
855
852
  return FeatureFlag2;
856
853
  })(FeatureFlag || {});
857
854
  var FeatureFlagDefaults = {
858
- ["DEFAULT_VALUES" /* DEFAULT_VALUES */]: true,
859
- ["AUTOMATION_BRANCHING" /* AUTOMATION_BRANCHING */]: true,
860
- ["AI_CUSTOM_CONFIGS" /* AI_CUSTOM_CONFIGS */]: true,
861
- ["BUDIBASE_AI" /* BUDIBASE_AI */]: true,
862
- ["USE_ZOD_VALIDATOR" /* USE_ZOD_VALIDATOR */]: false
855
+ ["USE_ZOD_VALIDATOR" /* USE_ZOD_VALIDATOR */]: false,
856
+ // Account-portal
857
+ ["DIRECT_LOGIN_TO_ACCOUNT_PORTAL" /* DIRECT_LOGIN_TO_ACCOUNT_PORTAL */]: false
863
858
  };
864
859
 
865
860
  // src/sdk/environmentVariables.ts
@@ -1166,7 +1161,8 @@ var GroupByTypes = [
1166
1161
  "number" /* NUMBER */,
1167
1162
  "boolean" /* BOOLEAN */,
1168
1163
  "datetime" /* DATETIME */,
1169
- "bigint" /* BIGINT */
1164
+ "bigint" /* BIGINT */,
1165
+ "ai" /* AI */
1170
1166
  ];
1171
1167
  function canGroupBy(type) {
1172
1168
  return GroupByTypes.includes(type);