@constructive-io/sdk 1.11.2 → 1.11.3
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/admin/orm/client.js +11 -1
- package/agent/orm/client.js +11 -1
- package/agent/orm/input-types.d.ts +0 -3
- package/api/orm/client.js +11 -1
- package/api/orm/index.d.ts +66 -4
- package/api/orm/index.js +36 -4
- package/api/orm/input-types.d.ts +4946 -630
- package/api/orm/input-types.js +34 -6
- package/api/orm/models/apis.d.ts +54 -0
- package/api/orm/models/{api.js → apis.js} +27 -27
- package/api/orm/models/derive.d.ts +54 -0
- package/api/orm/models/derive.js +104 -0
- package/api/orm/models/fieldBehavior.d.ts +54 -0
- package/api/orm/models/fieldBehavior.js +104 -0
- package/api/orm/models/foreignKeyConstraintBehavior.d.ts +54 -0
- package/api/orm/models/foreignKeyConstraintBehavior.js +104 -0
- package/api/orm/models/index.d.ts +18 -2
- package/api/orm/models/index.js +38 -6
- package/api/orm/models/page.d.ts +54 -0
- package/api/orm/models/page.js +104 -0
- package/api/orm/models/platformApis.d.ts +54 -0
- package/api/orm/models/platformApis.js +104 -0
- package/api/orm/models/platformPage.d.ts +54 -0
- package/api/orm/models/platformPage.js +104 -0
- package/api/orm/models/platformSiteAppLink.d.ts +54 -0
- package/api/orm/models/platformSiteAppLink.js +104 -0
- package/api/orm/models/platformSiteDeepLink.d.ts +54 -0
- package/api/orm/models/platformSiteDeepLink.js +104 -0
- package/api/orm/models/platformSiteErrorPage.d.ts +54 -0
- package/api/orm/models/platformSiteErrorPage.js +104 -0
- package/api/orm/models/platformSiteWebConfig.d.ts +54 -0
- package/api/orm/models/platformSiteWebConfig.js +104 -0
- package/api/orm/models/siteAppLink.d.ts +54 -0
- package/api/orm/models/{platformApi.js → siteAppLink.js} +27 -27
- package/api/orm/models/siteDeepLink.d.ts +54 -0
- package/api/orm/models/siteDeepLink.js +104 -0
- package/api/orm/models/siteErrorPage.d.ts +54 -0
- package/api/orm/models/siteErrorPage.js +104 -0
- package/api/orm/models/siteWebConfig.d.ts +54 -0
- package/api/orm/models/siteWebConfig.js +104 -0
- package/api/orm/models/tableBehavior.d.ts +54 -0
- package/api/orm/models/tableBehavior.js +104 -0
- package/api/orm/models/uniqueConstraintBehavior.d.ts +54 -0
- package/api/orm/models/uniqueConstraintBehavior.js +104 -0
- package/api/orm/models/viewBehavior.d.ts +54 -0
- package/api/orm/models/viewBehavior.js +104 -0
- package/api/orm/mutation/index.d.ts +33 -1
- package/api/orm/mutation/index.js +48 -0
- package/api/orm/query/index.d.ts +17 -0
- package/api/orm/query/index.js +28 -0
- package/auth/orm/client.js +11 -1
- package/auth/orm/input-types.d.ts +166 -220
- package/auth/orm/input-types.js +6 -11
- package/compute/orm/client.js +11 -1
- package/compute/orm/index.d.ts +4 -0
- package/compute/orm/index.js +4 -0
- package/compute/orm/input-types.d.ts +539 -8
- package/compute/orm/input-types.js +2 -0
- package/compute/orm/models/functionCapabilityBinding.d.ts +54 -0
- package/compute/orm/models/functionCapabilityBinding.js +104 -0
- package/compute/orm/models/index.d.ts +2 -0
- package/compute/orm/models/index.js +6 -2
- package/compute/orm/models/platformFunctionCapabilityBinding.d.ts +54 -0
- package/compute/orm/models/platformFunctionCapabilityBinding.js +104 -0
- package/config/orm/client.js +11 -1
- package/config/orm/input-types.d.ts +53 -5
- package/esm/admin/orm/client.js +11 -1
- package/esm/agent/orm/client.js +11 -1
- package/esm/agent/orm/input-types.d.ts +0 -3
- package/esm/api/orm/client.js +11 -1
- package/esm/api/orm/index.d.ts +66 -4
- package/esm/api/orm/index.js +36 -4
- package/esm/api/orm/input-types.d.ts +4946 -630
- package/esm/api/orm/input-types.js +34 -6
- package/esm/api/orm/models/apis.d.ts +54 -0
- package/esm/api/orm/models/{api.js → apis.js} +25 -25
- package/esm/api/orm/models/derive.d.ts +54 -0
- package/esm/api/orm/models/derive.js +100 -0
- package/esm/api/orm/models/fieldBehavior.d.ts +54 -0
- package/esm/api/orm/models/fieldBehavior.js +100 -0
- package/esm/api/orm/models/foreignKeyConstraintBehavior.d.ts +54 -0
- package/esm/api/orm/models/foreignKeyConstraintBehavior.js +100 -0
- package/esm/api/orm/models/index.d.ts +18 -2
- package/esm/api/orm/models/index.js +18 -2
- package/esm/api/orm/models/page.d.ts +54 -0
- package/esm/api/orm/models/page.js +100 -0
- package/esm/api/orm/models/platformApis.d.ts +54 -0
- package/esm/api/orm/models/{platformApi.js → platformApis.js} +25 -25
- package/esm/api/orm/models/platformPage.d.ts +54 -0
- package/esm/api/orm/models/platformPage.js +100 -0
- package/esm/api/orm/models/platformSiteAppLink.d.ts +54 -0
- package/esm/api/orm/models/platformSiteAppLink.js +100 -0
- package/esm/api/orm/models/platformSiteDeepLink.d.ts +54 -0
- package/esm/api/orm/models/platformSiteDeepLink.js +100 -0
- package/esm/api/orm/models/platformSiteErrorPage.d.ts +54 -0
- package/esm/api/orm/models/platformSiteErrorPage.js +100 -0
- package/esm/api/orm/models/platformSiteWebConfig.d.ts +54 -0
- package/esm/api/orm/models/platformSiteWebConfig.js +100 -0
- package/esm/api/orm/models/siteAppLink.d.ts +54 -0
- package/esm/api/orm/models/siteAppLink.js +100 -0
- package/esm/api/orm/models/siteDeepLink.d.ts +54 -0
- package/esm/api/orm/models/siteDeepLink.js +100 -0
- package/esm/api/orm/models/siteErrorPage.d.ts +54 -0
- package/esm/api/orm/models/siteErrorPage.js +100 -0
- package/esm/api/orm/models/siteWebConfig.d.ts +54 -0
- package/esm/api/orm/models/siteWebConfig.js +100 -0
- package/esm/api/orm/models/tableBehavior.d.ts +54 -0
- package/esm/api/orm/models/tableBehavior.js +100 -0
- package/esm/api/orm/models/uniqueConstraintBehavior.d.ts +54 -0
- package/esm/api/orm/models/uniqueConstraintBehavior.js +100 -0
- package/esm/api/orm/models/viewBehavior.d.ts +54 -0
- package/esm/api/orm/models/viewBehavior.js +100 -0
- package/esm/api/orm/mutation/index.d.ts +33 -1
- package/esm/api/orm/mutation/index.js +48 -0
- package/esm/api/orm/query/index.d.ts +17 -0
- package/esm/api/orm/query/index.js +28 -0
- package/esm/auth/orm/client.js +11 -1
- package/esm/auth/orm/input-types.d.ts +166 -220
- package/esm/auth/orm/input-types.js +6 -11
- package/esm/compute/orm/client.js +11 -1
- package/esm/compute/orm/index.d.ts +4 -0
- package/esm/compute/orm/index.js +4 -0
- package/esm/compute/orm/input-types.d.ts +539 -8
- package/esm/compute/orm/input-types.js +2 -0
- package/esm/compute/orm/models/functionCapabilityBinding.d.ts +54 -0
- package/esm/compute/orm/models/functionCapabilityBinding.js +100 -0
- package/esm/compute/orm/models/index.d.ts +2 -0
- package/esm/compute/orm/models/index.js +2 -0
- package/esm/compute/orm/models/platformFunctionCapabilityBinding.d.ts +54 -0
- package/esm/compute/orm/models/platformFunctionCapabilityBinding.js +100 -0
- package/esm/config/orm/client.js +11 -1
- package/esm/config/orm/input-types.d.ts +53 -5
- package/esm/infra/orm/client.js +11 -1
- package/esm/modules/orm/client.js +11 -1
- package/esm/modules/orm/index.d.ts +2 -0
- package/esm/modules/orm/index.js +2 -0
- package/esm/modules/orm/input-types.d.ts +2116 -122
- package/esm/modules/orm/input-types.js +40 -0
- package/esm/modules/orm/models/index.d.ts +1 -0
- package/esm/modules/orm/models/index.js +1 -0
- package/esm/modules/orm/models/pagesModule.d.ts +54 -0
- package/esm/modules/orm/models/pagesModule.js +100 -0
- package/esm/objects/orm/client.js +11 -1
- package/esm/usage/orm/client.js +11 -1
- package/infra/orm/client.js +11 -1
- package/modules/orm/client.js +11 -1
- package/modules/orm/index.d.ts +2 -0
- package/modules/orm/index.js +2 -0
- package/modules/orm/input-types.d.ts +2116 -122
- package/modules/orm/input-types.js +40 -0
- package/modules/orm/models/index.d.ts +1 -0
- package/modules/orm/models/index.js +4 -2
- package/modules/orm/models/pagesModule.d.ts +54 -0
- package/modules/orm/models/pagesModule.js +104 -0
- package/objects/orm/client.js +11 -1
- package/package.json +5 -5
- package/usage/orm/client.js +11 -1
- package/api/orm/models/api.d.ts +0 -54
- package/api/orm/models/platformApi.d.ts +0 -54
- package/esm/api/orm/models/api.d.ts +0 -54
- package/esm/api/orm/models/platformApi.d.ts +0 -54
|
@@ -38,6 +38,42 @@ export function createMutationOperations(client) {
|
|
|
38
38
|
},
|
|
39
39
|
], connectionFieldsMap, 'CancelDatabaseTransferPayload'),
|
|
40
40
|
}),
|
|
41
|
+
domainsAssignSubdomain: (args, options) => new QueryBuilder({
|
|
42
|
+
client,
|
|
43
|
+
operation: 'mutation',
|
|
44
|
+
operationName: 'DomainsAssignSubdomain',
|
|
45
|
+
fieldName: 'domainsAssignSubdomain',
|
|
46
|
+
...buildCustomDocument('mutation', 'DomainsAssignSubdomain', 'domainsAssignSubdomain', options.select, args, [
|
|
47
|
+
{
|
|
48
|
+
name: 'input',
|
|
49
|
+
type: 'DomainsAssignSubdomainInput!',
|
|
50
|
+
},
|
|
51
|
+
], connectionFieldsMap, 'DomainsAssignSubdomainPayload'),
|
|
52
|
+
}),
|
|
53
|
+
platformDomainsAssignSubdomain: (args, options) => new QueryBuilder({
|
|
54
|
+
client,
|
|
55
|
+
operation: 'mutation',
|
|
56
|
+
operationName: 'PlatformDomainsAssignSubdomain',
|
|
57
|
+
fieldName: 'platformDomainsAssignSubdomain',
|
|
58
|
+
...buildCustomDocument('mutation', 'PlatformDomainsAssignSubdomain', 'platformDomainsAssignSubdomain', options.select, args, [
|
|
59
|
+
{
|
|
60
|
+
name: 'input',
|
|
61
|
+
type: 'PlatformDomainsAssignSubdomainInput!',
|
|
62
|
+
},
|
|
63
|
+
], connectionFieldsMap, 'PlatformDomainsAssignSubdomainPayload'),
|
|
64
|
+
}),
|
|
65
|
+
platformSitesProvisionStaticSite: (args, options) => new QueryBuilder({
|
|
66
|
+
client,
|
|
67
|
+
operation: 'mutation',
|
|
68
|
+
operationName: 'PlatformSitesProvisionStaticSite',
|
|
69
|
+
fieldName: 'platformSitesProvisionStaticSite',
|
|
70
|
+
...buildCustomDocument('mutation', 'PlatformSitesProvisionStaticSite', 'platformSitesProvisionStaticSite', options.select, args, [
|
|
71
|
+
{
|
|
72
|
+
name: 'input',
|
|
73
|
+
type: 'PlatformSitesProvisionStaticSiteInput!',
|
|
74
|
+
},
|
|
75
|
+
], connectionFieldsMap, 'PlatformSitesProvisionStaticSitePayload'),
|
|
76
|
+
}),
|
|
41
77
|
provisionBucket: (args, options) => new QueryBuilder({
|
|
42
78
|
client,
|
|
43
79
|
operation: 'mutation',
|
|
@@ -86,5 +122,17 @@ export function createMutationOperations(client) {
|
|
|
86
122
|
},
|
|
87
123
|
], connectionFieldsMap, 'SetFieldOrderPayload'),
|
|
88
124
|
}),
|
|
125
|
+
sitesProvisionStaticSite: (args, options) => new QueryBuilder({
|
|
126
|
+
client,
|
|
127
|
+
operation: 'mutation',
|
|
128
|
+
operationName: 'SitesProvisionStaticSite',
|
|
129
|
+
fieldName: 'sitesProvisionStaticSite',
|
|
130
|
+
...buildCustomDocument('mutation', 'SitesProvisionStaticSite', 'sitesProvisionStaticSite', options.select, args, [
|
|
131
|
+
{
|
|
132
|
+
name: 'input',
|
|
133
|
+
type: 'SitesProvisionStaticSiteInput!',
|
|
134
|
+
},
|
|
135
|
+
], connectionFieldsMap, 'SitesProvisionStaticSitePayload'),
|
|
136
|
+
}),
|
|
89
137
|
};
|
|
90
138
|
}
|
|
@@ -14,6 +14,10 @@ export interface ApplyRegistryDefaultsVariables {
|
|
|
14
14
|
data?: unknown;
|
|
15
15
|
nodeType?: string;
|
|
16
16
|
}
|
|
17
|
+
export interface ResolveDeepLinkVariables {
|
|
18
|
+
linkSlug?: string;
|
|
19
|
+
targetSiteId?: string;
|
|
20
|
+
}
|
|
17
21
|
export interface ResolveHttpRouteVariables {
|
|
18
22
|
requestHost?: string;
|
|
19
23
|
requestMethod?: string;
|
|
@@ -24,6 +28,9 @@ export interface ResolveRouteVariables {
|
|
|
24
28
|
requestMethod?: string;
|
|
25
29
|
requestPath?: string;
|
|
26
30
|
}
|
|
31
|
+
export interface ResolveSiteAppLinksVariables {
|
|
32
|
+
targetSiteId?: string;
|
|
33
|
+
}
|
|
27
34
|
export declare function createQueryOperations(client: OrmClient): {
|
|
28
35
|
apiSchemaNames: (args: ApiSchemaNamesVariables, options?: {
|
|
29
36
|
select?: Record<string, unknown>;
|
|
@@ -35,6 +42,11 @@ export declare function createQueryOperations(client: OrmClient): {
|
|
|
35
42
|
}) => QueryBuilder<{
|
|
36
43
|
applyRegistryDefaults: unknown | null;
|
|
37
44
|
}>;
|
|
45
|
+
resolveDeepLink: (args: ResolveDeepLinkVariables, options?: {
|
|
46
|
+
select?: Record<string, unknown>;
|
|
47
|
+
}) => QueryBuilder<{
|
|
48
|
+
resolveDeepLink: unknown | null;
|
|
49
|
+
}>;
|
|
38
50
|
resolveHttpRoute: <S extends ResolveHttpRouteRecordSelect>(args: ResolveHttpRouteVariables, options: {
|
|
39
51
|
select: S;
|
|
40
52
|
} & StrictSelect<S, ResolveHttpRouteRecordSelect>) => QueryBuilder<{
|
|
@@ -45,4 +57,9 @@ export declare function createQueryOperations(client: OrmClient): {
|
|
|
45
57
|
} & StrictSelect<S, ResolveRouteRecordSelect>) => QueryBuilder<{
|
|
46
58
|
resolveRoute: InferSelectResult<ResolveRouteRecord, S> | null;
|
|
47
59
|
}>;
|
|
60
|
+
resolveSiteAppLinks: (args: ResolveSiteAppLinksVariables, options?: {
|
|
61
|
+
select?: Record<string, unknown>;
|
|
62
|
+
}) => QueryBuilder<{
|
|
63
|
+
resolveSiteAppLinks: unknown | null;
|
|
64
|
+
}>;
|
|
48
65
|
};
|
|
@@ -30,6 +30,22 @@ export function createQueryOperations(client) {
|
|
|
30
30
|
},
|
|
31
31
|
], connectionFieldsMap, undefined),
|
|
32
32
|
}),
|
|
33
|
+
resolveDeepLink: (args, options) => new QueryBuilder({
|
|
34
|
+
client,
|
|
35
|
+
operation: 'query',
|
|
36
|
+
operationName: 'ResolveDeepLink',
|
|
37
|
+
fieldName: 'resolveDeepLink',
|
|
38
|
+
...buildCustomDocument('query', 'ResolveDeepLink', 'resolveDeepLink', options?.select, args, [
|
|
39
|
+
{
|
|
40
|
+
name: 'linkSlug',
|
|
41
|
+
type: 'String',
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
name: 'targetSiteId',
|
|
45
|
+
type: 'UUID',
|
|
46
|
+
},
|
|
47
|
+
], connectionFieldsMap, undefined),
|
|
48
|
+
}),
|
|
33
49
|
resolveHttpRoute: (args, options) => new QueryBuilder({
|
|
34
50
|
client,
|
|
35
51
|
operation: 'query',
|
|
@@ -70,5 +86,17 @@ export function createQueryOperations(client) {
|
|
|
70
86
|
},
|
|
71
87
|
], connectionFieldsMap, 'ResolveRouteRecord'),
|
|
72
88
|
}),
|
|
89
|
+
resolveSiteAppLinks: (args, options) => new QueryBuilder({
|
|
90
|
+
client,
|
|
91
|
+
operation: 'query',
|
|
92
|
+
operationName: 'ResolveSiteAppLinks',
|
|
93
|
+
fieldName: 'resolveSiteAppLinks',
|
|
94
|
+
...buildCustomDocument('query', 'ResolveSiteAppLinks', 'resolveSiteAppLinks', options?.select, args, [
|
|
95
|
+
{
|
|
96
|
+
name: 'targetSiteId',
|
|
97
|
+
type: 'UUID',
|
|
98
|
+
},
|
|
99
|
+
], connectionFieldsMap, undefined),
|
|
100
|
+
}),
|
|
73
101
|
};
|
|
74
102
|
}
|
package/esm/auth/orm/client.js
CHANGED
|
@@ -59,6 +59,16 @@ export class FetchAdapter {
|
|
|
59
59
|
return this.endpoint;
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* Describe a single GraphQL error, falling back to its `extensions.code` when
|
|
64
|
+
* the server omits `message` so the error never renders as an empty string.
|
|
65
|
+
*/
|
|
66
|
+
function describeGraphQLError(error) {
|
|
67
|
+
if (error.message)
|
|
68
|
+
return error.message;
|
|
69
|
+
const code = error.extensions?.code;
|
|
70
|
+
return typeof code === 'string' ? code : 'Unknown error';
|
|
71
|
+
}
|
|
62
72
|
/**
|
|
63
73
|
* Error thrown when GraphQL request fails
|
|
64
74
|
*/
|
|
@@ -66,7 +76,7 @@ export class GraphQLRequestError extends Error {
|
|
|
66
76
|
errors;
|
|
67
77
|
data;
|
|
68
78
|
constructor(errors, data = null) {
|
|
69
|
-
const messages = errors.map(
|
|
79
|
+
const messages = errors.map(describeGraphQLError).join('; ');
|
|
70
80
|
super(`GraphQL Error: ${messages}`);
|
|
71
81
|
this.errors = errors;
|
|
72
82
|
this.data = data;
|