@twin.org/api-tenant-processor 0.0.3-next.2 → 0.0.3-next.21
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/README.md +1 -1
- package/dist/es/entities/tenant.js +25 -1
- package/dist/es/entities/tenant.js.map +1 -1
- package/dist/es/index.js +10 -2
- package/dist/es/index.js.map +1 -1
- package/dist/es/models/api/ITenantCreateRequest.js +2 -0
- package/dist/es/models/api/ITenantCreateRequest.js.map +1 -0
- package/dist/es/models/api/ITenantGetByApiKeyRequest.js +4 -0
- package/dist/es/models/api/ITenantGetByApiKeyRequest.js.map +1 -0
- package/dist/es/models/api/ITenantGetByIdRequest.js +4 -0
- package/dist/es/models/api/ITenantGetByIdRequest.js.map +1 -0
- package/dist/es/models/api/ITenantGetByPublicOriginRequest.js +4 -0
- package/dist/es/models/api/ITenantGetByPublicOriginRequest.js.map +1 -0
- package/dist/es/models/api/ITenantGetResponse.js +2 -0
- package/dist/es/models/api/ITenantGetResponse.js.map +1 -0
- package/dist/es/models/api/ITenantListRequest.js +4 -0
- package/dist/es/models/api/ITenantListRequest.js.map +1 -0
- package/dist/es/models/api/ITenantListResponse.js +2 -0
- package/dist/es/models/api/ITenantListResponse.js.map +1 -0
- package/dist/es/models/api/ITenantRemoveRequest.js +4 -0
- package/dist/es/models/api/ITenantRemoveRequest.js.map +1 -0
- package/dist/es/models/api/ITenantUpdateRequest.js +2 -0
- package/dist/es/models/api/ITenantUpdateRequest.js.map +1 -0
- package/dist/es/restEntryPoints.js +10 -0
- package/dist/es/restEntryPoints.js.map +1 -0
- package/dist/es/tenantAdminService.js +112 -15
- package/dist/es/tenantAdminService.js.map +1 -1
- package/dist/es/tenantIdContextIdHandler.js +8 -1
- package/dist/es/tenantIdContextIdHandler.js.map +1 -1
- package/dist/es/tenantProcessor.js +26 -21
- package/dist/es/tenantProcessor.js.map +1 -1
- package/dist/es/tenantRoutes.js +396 -0
- package/dist/es/tenantRoutes.js.map +1 -0
- package/dist/es/utils/tenantIdHelper.js +3 -3
- package/dist/es/utils/tenantIdHelper.js.map +1 -1
- package/dist/types/entities/tenant.d.ts +12 -0
- package/dist/types/index.d.ts +10 -2
- package/dist/types/models/api/ITenantCreateRequest.d.ts +12 -0
- package/dist/types/models/api/ITenantGetByApiKeyRequest.d.ts +14 -0
- package/dist/types/models/api/ITenantGetByIdRequest.d.ts +14 -0
- package/dist/types/models/api/ITenantGetByPublicOriginRequest.d.ts +14 -0
- package/dist/types/models/api/ITenantGetResponse.d.ts +10 -0
- package/dist/types/models/api/ITenantListRequest.d.ts +18 -0
- package/dist/types/models/api/ITenantListResponse.d.ts +17 -0
- package/dist/types/models/api/ITenantRemoveRequest.d.ts +14 -0
- package/dist/types/models/api/ITenantUpdateRequest.d.ts +19 -0
- package/dist/types/restEntryPoints.d.ts +2 -0
- package/dist/types/tenantAdminService.d.ts +30 -10
- package/dist/types/tenantIdContextIdHandler.d.ts +5 -0
- package/dist/types/tenantRoutes.d.ts +77 -0
- package/docs/changelog.md +293 -1
- package/docs/examples.md +81 -1
- package/docs/reference/classes/Tenant.md +24 -0
- package/docs/reference/classes/TenantAdminService.md +93 -19
- package/docs/reference/classes/TenantIdContextIdHandler.md +18 -0
- package/docs/reference/functions/generateRestRoutesTenants.md +25 -0
- package/docs/reference/functions/tenantByApiKey.md +31 -0
- package/docs/reference/functions/tenantById.md +31 -0
- package/docs/reference/functions/tenantByPublicOrigin.md +31 -0
- package/docs/reference/functions/tenantCreate.md +31 -0
- package/docs/reference/functions/tenantList.md +31 -0
- package/docs/reference/functions/tenantRemove.md +31 -0
- package/docs/reference/functions/tenantUpdate.md +31 -0
- package/docs/reference/index.md +21 -2
- package/docs/reference/interfaces/ITenantAdminServiceConstructorOptions.md +0 -6
- package/docs/reference/interfaces/ITenantCreateRequest.md +17 -0
- package/docs/reference/interfaces/ITenantGetByApiKeyRequest.md +17 -0
- package/docs/reference/interfaces/ITenantGetByIdRequest.md +17 -0
- package/docs/reference/interfaces/ITenantGetByPublicOriginRequest.md +17 -0
- package/docs/reference/interfaces/ITenantGetResponse.md +11 -0
- package/docs/reference/interfaces/ITenantListRequest.md +23 -0
- package/docs/reference/interfaces/ITenantListResponse.md +23 -0
- package/docs/reference/interfaces/ITenantProcessorConfig.md +0 -6
- package/docs/reference/interfaces/ITenantProcessorConstructorOptions.md +0 -6
- package/docs/reference/interfaces/ITenantRemoveRequest.md +17 -0
- package/docs/reference/interfaces/ITenantUpdateRequest.md +25 -0
- package/docs/reference/variables/tagsTenants.md +5 -0
- package/locales/en.json +4 -0
- package/package.json +3 -3
- package/dist/es/models/ITenant.js +0 -4
- package/dist/es/models/ITenant.js.map +0 -1
- package/dist/es/models/ITenantAdminComponent.js +0 -2
- package/dist/es/models/ITenantAdminComponent.js.map +0 -1
- package/dist/types/models/ITenant.d.ts +0 -21
- package/dist/types/models/ITenantAdminComponent.d.ts +0 -41
- package/docs/reference/interfaces/ITenant.md +0 -35
- package/docs/reference/interfaces/ITenantAdminComponent.md +0 -123
|
@@ -4,7 +4,7 @@ Service for performing email messaging operations to a connector.
|
|
|
4
4
|
|
|
5
5
|
## Implements
|
|
6
6
|
|
|
7
|
-
-
|
|
7
|
+
- `ITenantAdminComponent`
|
|
8
8
|
|
|
9
9
|
## Constructors
|
|
10
10
|
|
|
@@ -56,7 +56,7 @@ The class name of the component.
|
|
|
56
56
|
|
|
57
57
|
### get()
|
|
58
58
|
|
|
59
|
-
> **get**(`tenantId`): `Promise
|
|
59
|
+
> **get**(`tenantId`): `Promise`\<`ITenant`\>
|
|
60
60
|
|
|
61
61
|
Get a tenant by its id.
|
|
62
62
|
|
|
@@ -70,19 +70,23 @@ The id of the tenant.
|
|
|
70
70
|
|
|
71
71
|
#### Returns
|
|
72
72
|
|
|
73
|
-
`Promise
|
|
73
|
+
`Promise`\<`ITenant`\>
|
|
74
74
|
|
|
75
|
-
The tenant
|
|
75
|
+
The tenant.
|
|
76
|
+
|
|
77
|
+
#### Throws
|
|
78
|
+
|
|
79
|
+
Error if the tenant is not found.
|
|
76
80
|
|
|
77
81
|
#### Implementation of
|
|
78
82
|
|
|
79
|
-
|
|
83
|
+
`ITenantAdminComponent.get`
|
|
80
84
|
|
|
81
85
|
***
|
|
82
86
|
|
|
83
87
|
### getByApiKey()
|
|
84
88
|
|
|
85
|
-
> **getByApiKey**(`apiKey`): `Promise
|
|
89
|
+
> **getByApiKey**(`apiKey`): `Promise`\<`ITenant`\>
|
|
86
90
|
|
|
87
91
|
Get a tenant by its api key.
|
|
88
92
|
|
|
@@ -96,39 +100,99 @@ The api key of the tenant.
|
|
|
96
100
|
|
|
97
101
|
#### Returns
|
|
98
102
|
|
|
99
|
-
`Promise
|
|
103
|
+
`Promise`\<`ITenant`\>
|
|
104
|
+
|
|
105
|
+
The tenant.
|
|
106
|
+
|
|
107
|
+
#### Throws
|
|
100
108
|
|
|
101
|
-
|
|
109
|
+
Error if the tenant is not found.
|
|
102
110
|
|
|
103
111
|
#### Implementation of
|
|
104
112
|
|
|
105
|
-
|
|
113
|
+
`ITenantAdminComponent.getByApiKey`
|
|
106
114
|
|
|
107
115
|
***
|
|
108
116
|
|
|
109
|
-
###
|
|
117
|
+
### getByPublicOrigin()
|
|
110
118
|
|
|
111
|
-
> **
|
|
119
|
+
> **getByPublicOrigin**(`publicOrigin`): `Promise`\<`ITenant`\>
|
|
112
120
|
|
|
113
|
-
|
|
121
|
+
Get a tenant by its public origin.
|
|
122
|
+
|
|
123
|
+
#### Parameters
|
|
124
|
+
|
|
125
|
+
##### publicOrigin
|
|
126
|
+
|
|
127
|
+
`string`
|
|
128
|
+
|
|
129
|
+
The origin of the tenant.
|
|
130
|
+
|
|
131
|
+
#### Returns
|
|
132
|
+
|
|
133
|
+
`Promise`\<`ITenant`\>
|
|
134
|
+
|
|
135
|
+
The tenant.
|
|
136
|
+
|
|
137
|
+
#### Throws
|
|
138
|
+
|
|
139
|
+
Error if the tenant is not found.
|
|
140
|
+
|
|
141
|
+
#### Implementation of
|
|
142
|
+
|
|
143
|
+
`ITenantAdminComponent.getByPublicOrigin`
|
|
144
|
+
|
|
145
|
+
***
|
|
146
|
+
|
|
147
|
+
### create()
|
|
148
|
+
|
|
149
|
+
> **create**(`tenant`): `Promise`\<`string`\>
|
|
150
|
+
|
|
151
|
+
Create a tenant.
|
|
114
152
|
|
|
115
153
|
#### Parameters
|
|
116
154
|
|
|
117
155
|
##### tenant
|
|
118
156
|
|
|
119
|
-
|
|
157
|
+
`Omit`\<`ITenant`, `"id"` \| `"dateCreated"` \| `"dateModified"`\> & `object`
|
|
120
158
|
|
|
121
159
|
The tenant to store.
|
|
122
160
|
|
|
123
161
|
#### Returns
|
|
124
162
|
|
|
163
|
+
`Promise`\<`string`\>
|
|
164
|
+
|
|
165
|
+
The tenant id.
|
|
166
|
+
|
|
167
|
+
#### Implementation of
|
|
168
|
+
|
|
169
|
+
`ITenantAdminComponent.create`
|
|
170
|
+
|
|
171
|
+
***
|
|
172
|
+
|
|
173
|
+
### update()
|
|
174
|
+
|
|
175
|
+
> **update**(`tenant`): `Promise`\<`void`\>
|
|
176
|
+
|
|
177
|
+
Update a tenant.
|
|
178
|
+
|
|
179
|
+
#### Parameters
|
|
180
|
+
|
|
181
|
+
##### tenant
|
|
182
|
+
|
|
183
|
+
`Partial`\<`Omit`\<`ITenant`, `"dateCreated"` \| `"dateModified"`\>\>
|
|
184
|
+
|
|
185
|
+
The tenant to update.
|
|
186
|
+
|
|
187
|
+
#### Returns
|
|
188
|
+
|
|
125
189
|
`Promise`\<`void`\>
|
|
126
190
|
|
|
127
|
-
|
|
191
|
+
The nothing.
|
|
128
192
|
|
|
129
193
|
#### Implementation of
|
|
130
194
|
|
|
131
|
-
|
|
195
|
+
`ITenantAdminComponent.update`
|
|
132
196
|
|
|
133
197
|
***
|
|
134
198
|
|
|
@@ -154,18 +218,28 @@ Nothing.
|
|
|
154
218
|
|
|
155
219
|
#### Implementation of
|
|
156
220
|
|
|
157
|
-
|
|
221
|
+
`ITenantAdminComponent.remove`
|
|
158
222
|
|
|
159
223
|
***
|
|
160
224
|
|
|
161
225
|
### query()
|
|
162
226
|
|
|
163
|
-
> **query**(`cursor?`, `limit?`): `Promise`\<\{ `tenants`:
|
|
227
|
+
> **query**(`options?`, `cursor?`, `limit?`): `Promise`\<\{ `tenants`: `ITenant`[]; `cursor?`: `string`; \}\>
|
|
164
228
|
|
|
165
229
|
Query tenants with pagination.
|
|
166
230
|
|
|
167
231
|
#### Parameters
|
|
168
232
|
|
|
233
|
+
##### options?
|
|
234
|
+
|
|
235
|
+
Optional query options.
|
|
236
|
+
|
|
237
|
+
###### isNodeTenant?
|
|
238
|
+
|
|
239
|
+
`boolean`
|
|
240
|
+
|
|
241
|
+
Whether to filter for node admin tenants.
|
|
242
|
+
|
|
169
243
|
##### cursor?
|
|
170
244
|
|
|
171
245
|
`string`
|
|
@@ -180,10 +254,10 @@ The maximum number of tenants to return.
|
|
|
180
254
|
|
|
181
255
|
#### Returns
|
|
182
256
|
|
|
183
|
-
`Promise`\<\{ `tenants`:
|
|
257
|
+
`Promise`\<\{ `tenants`: `ITenant`[]; `cursor?`: `string`; \}\>
|
|
184
258
|
|
|
185
259
|
The tenants and the next cursor if more tenants are available.
|
|
186
260
|
|
|
187
261
|
#### Implementation of
|
|
188
262
|
|
|
189
|
-
|
|
263
|
+
`ITenantAdminComponent.query`
|
|
@@ -26,6 +26,24 @@ Runtime name for the class.
|
|
|
26
26
|
|
|
27
27
|
## Methods
|
|
28
28
|
|
|
29
|
+
### className()
|
|
30
|
+
|
|
31
|
+
> **className**(): `string`
|
|
32
|
+
|
|
33
|
+
The class name of the component.
|
|
34
|
+
|
|
35
|
+
#### Returns
|
|
36
|
+
|
|
37
|
+
`string`
|
|
38
|
+
|
|
39
|
+
The class name.
|
|
40
|
+
|
|
41
|
+
#### Implementation of
|
|
42
|
+
|
|
43
|
+
`IContextIdHandler.className`
|
|
44
|
+
|
|
45
|
+
***
|
|
46
|
+
|
|
29
47
|
### short()
|
|
30
48
|
|
|
31
49
|
> **short**(`value`): `string`
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Function: generateRestRoutesTenants()
|
|
2
|
+
|
|
3
|
+
> **generateRestRoutesTenants**(`baseRouteName`, `componentName`): `IRestRoute`\<`any`, `any`\>[]
|
|
4
|
+
|
|
5
|
+
The REST routes for tenant management.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### baseRouteName
|
|
10
|
+
|
|
11
|
+
`string`
|
|
12
|
+
|
|
13
|
+
Prefix to prepend to the paths.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes stored in the ComponentFactory.
|
|
20
|
+
|
|
21
|
+
## Returns
|
|
22
|
+
|
|
23
|
+
`IRestRoute`\<`any`, `any`\>[]
|
|
24
|
+
|
|
25
|
+
The generated routes.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantByApiKey()
|
|
2
|
+
|
|
3
|
+
> **tenantByApiKey**(`httpRequestContext`, `componentName`, `request`): `Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
4
|
+
|
|
5
|
+
Get the tenant by api key.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantGetByApiKeyRequest`](../interfaces/ITenantGetByApiKeyRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantById()
|
|
2
|
+
|
|
3
|
+
> **tenantById**(`httpRequestContext`, `componentName`, `request`): `Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
4
|
+
|
|
5
|
+
Get the tenant by id.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantGetByIdRequest`](../interfaces/ITenantGetByIdRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantByPublicOrigin()
|
|
2
|
+
|
|
3
|
+
> **tenantByPublicOrigin**(`httpRequestContext`, `componentName`, `request`): `Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
4
|
+
|
|
5
|
+
Get the tenant by public origin.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantGetByPublicOriginRequest`](../interfaces/ITenantGetByPublicOriginRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<[`ITenantGetResponse`](../interfaces/ITenantGetResponse.md)\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantCreate()
|
|
2
|
+
|
|
3
|
+
> **tenantCreate**(`httpRequestContext`, `componentName`, `request`): `Promise`\<`ICreatedResponse`\>
|
|
4
|
+
|
|
5
|
+
Create the tenant.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantCreateRequest`](../interfaces/ITenantCreateRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<`ICreatedResponse`\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantList()
|
|
2
|
+
|
|
3
|
+
> **tenantList**(`httpRequestContext`, `componentName`, `request`): `Promise`\<[`ITenantListResponse`](../interfaces/ITenantListResponse.md)\>
|
|
4
|
+
|
|
5
|
+
Get the list of tenants.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantListRequest`](../interfaces/ITenantListRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<[`ITenantListResponse`](../interfaces/ITenantListResponse.md)\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantRemove()
|
|
2
|
+
|
|
3
|
+
> **tenantRemove**(`httpRequestContext`, `componentName`, `request`): `Promise`\<`INoContentResponse`\>
|
|
4
|
+
|
|
5
|
+
Remove the tenant by id.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantRemoveRequest`](../interfaces/ITenantRemoveRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<`INoContentResponse`\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Function: tenantUpdate()
|
|
2
|
+
|
|
3
|
+
> **tenantUpdate**(`httpRequestContext`, `componentName`, `request`): `Promise`\<`INoContentResponse`\>
|
|
4
|
+
|
|
5
|
+
Update the tenant.
|
|
6
|
+
|
|
7
|
+
## Parameters
|
|
8
|
+
|
|
9
|
+
### httpRequestContext
|
|
10
|
+
|
|
11
|
+
`IHttpRequestContext`
|
|
12
|
+
|
|
13
|
+
The request context for the API.
|
|
14
|
+
|
|
15
|
+
### componentName
|
|
16
|
+
|
|
17
|
+
`string`
|
|
18
|
+
|
|
19
|
+
The name of the component to use in the routes.
|
|
20
|
+
|
|
21
|
+
### request
|
|
22
|
+
|
|
23
|
+
[`ITenantUpdateRequest`](../interfaces/ITenantUpdateRequest.md)
|
|
24
|
+
|
|
25
|
+
The request.
|
|
26
|
+
|
|
27
|
+
## Returns
|
|
28
|
+
|
|
29
|
+
`Promise`\<`INoContentResponse`\>
|
|
30
|
+
|
|
31
|
+
The response object with additional http response properties.
|
package/docs/reference/index.md
CHANGED
|
@@ -10,13 +10,32 @@
|
|
|
10
10
|
|
|
11
11
|
## Interfaces
|
|
12
12
|
|
|
13
|
-
- [ITenant](interfaces/ITenant.md)
|
|
14
|
-
- [ITenantAdminComponent](interfaces/ITenantAdminComponent.md)
|
|
15
13
|
- [ITenantAdminServiceConfig](interfaces/ITenantAdminServiceConfig.md)
|
|
16
14
|
- [ITenantAdminServiceConstructorOptions](interfaces/ITenantAdminServiceConstructorOptions.md)
|
|
17
15
|
- [ITenantProcessorConfig](interfaces/ITenantProcessorConfig.md)
|
|
18
16
|
- [ITenantProcessorConstructorOptions](interfaces/ITenantProcessorConstructorOptions.md)
|
|
17
|
+
- [ITenantCreateRequest](interfaces/ITenantCreateRequest.md)
|
|
18
|
+
- [ITenantGetByApiKeyRequest](interfaces/ITenantGetByApiKeyRequest.md)
|
|
19
|
+
- [ITenantGetByIdRequest](interfaces/ITenantGetByIdRequest.md)
|
|
20
|
+
- [ITenantGetByPublicOriginRequest](interfaces/ITenantGetByPublicOriginRequest.md)
|
|
21
|
+
- [ITenantGetResponse](interfaces/ITenantGetResponse.md)
|
|
22
|
+
- [ITenantListRequest](interfaces/ITenantListRequest.md)
|
|
23
|
+
- [ITenantListResponse](interfaces/ITenantListResponse.md)
|
|
24
|
+
- [ITenantRemoveRequest](interfaces/ITenantRemoveRequest.md)
|
|
25
|
+
- [ITenantUpdateRequest](interfaces/ITenantUpdateRequest.md)
|
|
26
|
+
|
|
27
|
+
## Variables
|
|
28
|
+
|
|
29
|
+
- [tagsTenants](variables/tagsTenants.md)
|
|
19
30
|
|
|
20
31
|
## Functions
|
|
21
32
|
|
|
22
33
|
- [initSchema](functions/initSchema.md)
|
|
34
|
+
- [generateRestRoutesTenants](functions/generateRestRoutesTenants.md)
|
|
35
|
+
- [tenantList](functions/tenantList.md)
|
|
36
|
+
- [tenantById](functions/tenantById.md)
|
|
37
|
+
- [tenantByApiKey](functions/tenantByApiKey.md)
|
|
38
|
+
- [tenantByPublicOrigin](functions/tenantByPublicOrigin.md)
|
|
39
|
+
- [tenantRemove](functions/tenantRemove.md)
|
|
40
|
+
- [tenantCreate](functions/tenantCreate.md)
|
|
41
|
+
- [tenantUpdate](functions/tenantUpdate.md)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Interface: ITenantCreateRequest
|
|
2
|
+
|
|
3
|
+
The tenant to create.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### body
|
|
8
|
+
|
|
9
|
+
> **body**: `Omit`\<`ITenant`, `"id"` \| `"dateCreated"` \| `"dateModified"`\> & `object`
|
|
10
|
+
|
|
11
|
+
The tenant to create.
|
|
12
|
+
|
|
13
|
+
#### Type Declaration
|
|
14
|
+
|
|
15
|
+
##### id?
|
|
16
|
+
|
|
17
|
+
> `optional` **id**: `string`
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Interface: ITenantGetByApiKeyRequest
|
|
2
|
+
|
|
3
|
+
The tenant to get by API key.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### pathParams
|
|
8
|
+
|
|
9
|
+
> **pathParams**: `object`
|
|
10
|
+
|
|
11
|
+
The path parameters.
|
|
12
|
+
|
|
13
|
+
#### apiKey
|
|
14
|
+
|
|
15
|
+
> **apiKey**: `string`
|
|
16
|
+
|
|
17
|
+
The API key of the tenant to get.
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Interface: ITenantGetByPublicOriginRequest
|
|
2
|
+
|
|
3
|
+
The tenant to get by public origin.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### pathParams
|
|
8
|
+
|
|
9
|
+
> **pathParams**: `object`
|
|
10
|
+
|
|
11
|
+
The path parameters.
|
|
12
|
+
|
|
13
|
+
#### publicOrigin
|
|
14
|
+
|
|
15
|
+
> **publicOrigin**: `string`
|
|
16
|
+
|
|
17
|
+
The public origin of the tenant to get.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Interface: ITenantListRequest
|
|
2
|
+
|
|
3
|
+
The list of tenants.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### query
|
|
8
|
+
|
|
9
|
+
> **query**: `object`
|
|
10
|
+
|
|
11
|
+
The query parameters.
|
|
12
|
+
|
|
13
|
+
#### cursor?
|
|
14
|
+
|
|
15
|
+
> `optional` **cursor**: `string`
|
|
16
|
+
|
|
17
|
+
The cursor to get the next chunk of tenants.
|
|
18
|
+
|
|
19
|
+
#### limit?
|
|
20
|
+
|
|
21
|
+
> `optional` **limit**: `string`
|
|
22
|
+
|
|
23
|
+
The number of tenants to return.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Interface: ITenantListResponse
|
|
2
|
+
|
|
3
|
+
The list of tenants.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
### headers?
|
|
8
|
+
|
|
9
|
+
> `optional` **headers**: `object`
|
|
10
|
+
|
|
11
|
+
The headers which can be used to include the cursor.
|
|
12
|
+
|
|
13
|
+
#### link?
|
|
14
|
+
|
|
15
|
+
> `optional` **link**: `string` \| `string`[]
|
|
16
|
+
|
|
17
|
+
***
|
|
18
|
+
|
|
19
|
+
### body
|
|
20
|
+
|
|
21
|
+
> **body**: `ITenant`[]
|
|
22
|
+
|
|
23
|
+
The list of tenants.
|