@adobe/helix-admin-support 2.2.17 → 2.2.18

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 CHANGED
@@ -1,3 +1,10 @@
1
+ ## [2.2.18](https://github.com/adobe/helix-admin-support/compare/v2.2.17...v2.2.18) (2023-10-28)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * export types ([ed60cbe](https://github.com/adobe/helix-admin-support/commit/ed60cbe069e15f1189d24528797b69a96189f1f6))
7
+
1
8
  ## [2.2.17](https://github.com/adobe/helix-admin-support/compare/v2.2.16...v2.2.17) (2023-10-21)
2
9
 
3
10
 
@@ -0,0 +1,15 @@
1
+ # Untitled boolean in ProjectConfig Schema
2
+
3
+ ```txt
4
+ https://ns.adobe.com/helix/config/project#/properties/admin/properties/requireAuth/oneOf/0
5
+ ```
6
+
7
+
8
+
9
+ | Abstract | Extensible | Status | Identifiable | Custom Properties | Additional Properties | Access Restrictions | Defined In |
10
+ | :------------------ | :--------- | :------------- | :---------------------- | :---------------- | :-------------------- | :------------------ | :-------------------------------------------------------------------------------- |
11
+ | Can be instantiated | No | Unknown status | Unknown identifiability | Forbidden | Allowed | none | [project-config.schema.json\*](project-config.schema.json "open original schema") |
12
+
13
+ ## 0 Type
14
+
15
+ `boolean`
@@ -0,0 +1,23 @@
1
+ # Untitled string in ProjectConfig Schema
2
+
3
+ ```txt
4
+ https://ns.adobe.com/helix/config/project#/properties/admin/properties/requireAuth/oneOf/1
5
+ ```
6
+
7
+
8
+
9
+ | Abstract | Extensible | Status | Identifiable | Custom Properties | Additional Properties | Access Restrictions | Defined In |
10
+ | :------------------ | :--------- | :------------- | :---------------------- | :---------------- | :-------------------- | :------------------ | :-------------------------------------------------------------------------------- |
11
+ | Can be instantiated | No | Unknown status | Unknown identifiability | Forbidden | Allowed | none | [project-config.schema.json\*](project-config.schema.json "open original schema") |
12
+
13
+ ## 1 Type
14
+
15
+ `string`
16
+
17
+ ## 1 Constraints
18
+
19
+ **enum**: the value of this property must be equal to one of the following values:
20
+
21
+ | Value | Explanation |
22
+ | :------- | :---------- |
23
+ | `"auto"` | |
@@ -0,0 +1,29 @@
1
+ # Untitled undefined type in ProjectConfig Schema
2
+
3
+ ```txt
4
+ https://ns.adobe.com/helix/config/project#/properties/admin/properties/requireAuth
5
+ ```
6
+
7
+ Enforce authentication if set to true. If set to 'auto' it will enforce authentication if a role mapping is defined. defaults to 'auto'.
8
+
9
+ | Abstract | Extensible | Status | Identifiable | Custom Properties | Additional Properties | Access Restrictions | Defined In |
10
+ | :------------------ | :--------- | :------------- | :---------------------- | :---------------- | :-------------------- | :------------------ | :-------------------------------------------------------------------------------- |
11
+ | Can be instantiated | No | Unknown status | Unknown identifiability | Forbidden | Allowed | none | [project-config.schema.json\*](project-config.schema.json "open original schema") |
12
+
13
+ ## requireAuth Type
14
+
15
+ merged type ([Details](project-config-properties-adminconfig-properties-requireauth.md))
16
+
17
+ one (and only one) of
18
+
19
+ * [Untitled boolean in ProjectConfig](project-config-properties-adminconfig-properties-requireauth-oneof-0.md "check type definition")
20
+
21
+ * [Untitled string in ProjectConfig](project-config-properties-adminconfig-properties-requireauth-oneof-1.md "check type definition")
22
+
23
+ ## requireAuth Default Value
24
+
25
+ The default value is:
26
+
27
+ ```json
28
+ "auto"
29
+ ```
@@ -16,11 +16,12 @@ https://ns.adobe.com/helix/config/project#/properties/admin
16
16
 
17
17
  # admin Properties
18
18
 
19
- | Property | Type | Required | Nullable | Defined by |
20
- | :-------------------- | :------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------- |
21
- | [role](#role) | `object` | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-role.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/role") |
22
- | [apiKeyId](#apikeyid) | Merged | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-apikeyid.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/apiKeyId") |
23
- | [events](#events) | `object` | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-events.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/events") |
19
+ | Property | Type | Required | Nullable | Defined by |
20
+ | :-------------------------- | :------- | :------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
21
+ | [role](#role) | `object` | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-role.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/role") |
22
+ | [requireAuth](#requireauth) | Merged | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-requireauth.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/requireAuth") |
23
+ | [apiKeyId](#apikeyid) | Merged | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-apikeyid.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/apiKeyId") |
24
+ | [events](#events) | `object` | Optional | cannot be null | [ProjectConfig](project-config-properties-adminconfig-properties-events.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/events") |
24
25
 
25
26
  ## role
26
27
 
@@ -40,6 +41,38 @@ https://ns.adobe.com/helix/config/project#/properties/admin
40
41
 
41
42
  `object` ([Role](project-config-properties-adminconfig-properties-role.md))
42
43
 
44
+ ## requireAuth
45
+
46
+ Enforce authentication if set to true. If set to 'auto' it will enforce authentication if a role mapping is defined. defaults to 'auto'.
47
+
48
+ `requireAuth`
49
+
50
+ * is optional
51
+
52
+ * Type: merged type ([Details](project-config-properties-adminconfig-properties-requireauth.md))
53
+
54
+ * cannot be null
55
+
56
+ * defined in: [ProjectConfig](project-config-properties-adminconfig-properties-requireauth.md "https://ns.adobe.com/helix/config/project#/properties/admin/properties/requireAuth")
57
+
58
+ ### requireAuth Type
59
+
60
+ merged type ([Details](project-config-properties-adminconfig-properties-requireauth.md))
61
+
62
+ one (and only one) of
63
+
64
+ * [Untitled boolean in ProjectConfig](project-config-properties-adminconfig-properties-requireauth-oneof-0.md "check type definition")
65
+
66
+ * [Untitled string in ProjectConfig](project-config-properties-adminconfig-properties-requireauth-oneof-1.md "check type definition")
67
+
68
+ ### requireAuth Default Value
69
+
70
+ The default value is:
71
+
72
+ ```json
73
+ "auto"
74
+ ```
75
+
43
76
  ## apiKeyId
44
77
 
45
78
  the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.
@@ -1 +1 @@
1
- {"meta:license":["Copyright 2023 Adobe. All rights reserved.","This file is licensed to you under the Apache License, Version 2.0 (the \"License\");","you may not use this file except in compliance with the License. You may obtain a copy","of the License at http://www.apache.org/licenses/LICENSE-2.0","","Unless required by applicable law or agreed to in writing, software distributed under","the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS","OF ANY KIND, either express or implied. See the License for the specific language","governing permissions and limitations under the License."],"$id":"https://ns.adobe.com/helix/config/project","$schema":"http://json-schema.org/draft-07/schema#","$defs":{"emailglob":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"matches one or several users or group of users"}},"title":"ProjectConfig","type":"object","properties":{"name":{"type":"string","description":"Name of the project used by the slack bot when reporting."},"project":{"type":"string","description":"Name of the project used by the sidekick."},"timezone":{"type":"string","description":"Timezone to be used by the slack bot when reporting times.","examples":["Europe/Zurich"]},"host":{"type":"string","description":"Production host use by the slack bot to display project information."},"blueprint":{"type":"string","description":"configuration blueprint repository in the owner/repo format.","examples":["adobe/helix-website"]},"slack":{"description":"the slack teamId/channelID(s) where the slack bot is used.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"metadata":{"description":"source paths for metadata.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"cdn":{"description":"The CDN config","$ref":"./project-config-cdn.schema.json"},"access":{"type":"object","title":"SiteAccessConfig","properties":{"allow":{"description":"The email glob of the users that are allowed.","$ref":"#/$defs/emailglob"},"apiKeyId":{"description":"the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"require":{"type":"object","properties":{"repository":{"description":"The list of owner/repo pointers to projects that are allowed to use this content.","examples":["adobe/*","hlxsites/wknd"],"$ref":"#/$defs/emailglob"}},"required":["repository"],"additionalProperties":false}},"required":["allow"],"additionalProperties":false},"admin":{"title":"AdminConfig","type":"object","properties":{"role":{"title":"Role","type":"object","properties":{"author":{"description":"The email glob of the users with author role.","$ref":"#/$defs/emailglob"},"publish":{"description":"The email glob of the users with publish role.","$ref":"#/$defs/emailglob"}},"required":["role"],"additionalProperties":false},"apiKeyId":{"description":"the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"events":{"description":"Events that are triggered by the admin.","type":"object","additionalProperties":false,"properties":{"github":{"description":"Github configuration for admin events.","type":"object","additionalProperties":false,"properties":{"target":{"title":"Github Event Notification Target Owner/Repository","description":"The target github owner and repository to which the event is to be sent in the owner/repo format. For e.g. hlxsites/target-repo","type":"string","additionalProperties":false}}}}}},"additionalProperties":false}},"additionalProperties":false}
1
+ {"meta:license":["Copyright 2023 Adobe. All rights reserved.","This file is licensed to you under the Apache License, Version 2.0 (the \"License\");","you may not use this file except in compliance with the License. You may obtain a copy","of the License at http://www.apache.org/licenses/LICENSE-2.0","","Unless required by applicable law or agreed to in writing, software distributed under","the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS","OF ANY KIND, either express or implied. See the License for the specific language","governing permissions and limitations under the License."],"$id":"https://ns.adobe.com/helix/config/project","$schema":"http://json-schema.org/draft-07/schema#","$defs":{"emailglob":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"matches one or several users or group of users"}},"title":"ProjectConfig","type":"object","properties":{"name":{"type":"string","description":"Name of the project used by the slack bot when reporting."},"project":{"type":"string","description":"Name of the project used by the sidekick."},"timezone":{"type":"string","description":"Timezone to be used by the slack bot when reporting times.","examples":["Europe/Zurich"]},"host":{"type":"string","description":"Production host use by the slack bot to display project information."},"blueprint":{"type":"string","description":"configuration blueprint repository in the owner/repo format.","examples":["adobe/helix-website"]},"slack":{"description":"the slack teamId/channelID(s) where the slack bot is used.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"metadata":{"description":"source paths for metadata.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"cdn":{"description":"The CDN config","$ref":"./project-config-cdn.schema.json"},"access":{"type":"object","title":"SiteAccessConfig","properties":{"allow":{"description":"The email glob of the users that are allowed.","$ref":"#/$defs/emailglob"},"apiKeyId":{"description":"the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"require":{"type":"object","properties":{"repository":{"description":"The list of owner/repo pointers to projects that are allowed to use this content.","examples":["adobe/*","hlxsites/wknd"],"$ref":"#/$defs/emailglob"}},"required":["repository"],"additionalProperties":false}},"required":["allow"],"additionalProperties":false},"admin":{"title":"AdminConfig","type":"object","properties":{"role":{"title":"Role","type":"object","properties":{"author":{"description":"The email glob of the users with author role.","$ref":"#/$defs/emailglob"},"publish":{"description":"The email glob of the users with publish role.","$ref":"#/$defs/emailglob"}},"required":["role"],"additionalProperties":false},"requireAuth":{"description":"Enforce authentication if set to true. If set to 'auto' it will enforce authentication if a role mapping is defined. defaults to 'auto'.","default":"auto","oneOf":[{"type":"boolean"},{"type":"string","enum":["auto"]}]},"apiKeyId":{"description":"the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.","oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}]},"events":{"description":"Events that are triggered by the admin.","type":"object","additionalProperties":false,"properties":{"github":{"description":"Github configuration for admin events.","type":"object","additionalProperties":false,"properties":{"target":{"title":"Github Event Notification Target Owner/Repository","description":"The target github owner and repository to which the event is to be sent in the owner/repo format. For e.g. hlxsites/target-repo","type":"string","additionalProperties":false}}}}}},"additionalProperties":false}},"additionalProperties":false}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adobe/helix-admin-support",
3
- "version": "2.2.17",
3
+ "version": "2.2.18",
4
4
  "description": "Helix Admin Support Library",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
package/src/index.d.ts CHANGED
@@ -11,8 +11,8 @@
11
11
  */
12
12
  import { OneDrive } from '@adobe/helix-onedrive-support';
13
13
  import { UniversalContext } from '@adobe/helix-universal';
14
- import { ProjectConfig } from './fetch-config';
15
- import { ConfigAll } from "./fetch-config-all";
14
+ import { ProjectConfig } from '../types/project-config';
15
+ import { ConfigAll } from "../types/project-config-all";
16
16
  import {HelixConfig} from "../types/helix-config";
17
17
 
18
18
  declare interface AuthInfo {}
@@ -33,6 +33,9 @@ export * from './fetch-s3';
33
33
  export * from './fetch-sitemap';
34
34
  export * from './flatJson2Object';
35
35
  export * from './BatchedQueueClient';
36
+ export * from '../types/helix-config';
37
+ export * from '../types/project-config';
38
+ export * from '../types/project-config-all';
36
39
 
37
40
  export declare interface ErrorResponse {
38
41
  /**
@@ -143,6 +143,19 @@
143
143
  "required": ["role"],
144
144
  "additionalProperties": false
145
145
  },
146
+ "requireAuth": {
147
+ "description": "Enforce authentication if set to true. If set to 'auto' it will enforce authentication if a role mapping is defined. defaults to 'auto'.",
148
+ "default": "auto",
149
+ "oneOf": [
150
+ {
151
+ "type": "boolean"
152
+ },
153
+ {
154
+ "type": "string",
155
+ "enum": ["auto"]
156
+ }
157
+ ]
158
+ },
146
159
  "apiKeyId": {
147
160
  "description": "the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.",
148
161
  "oneOf": [
@@ -149,6 +149,10 @@ export interface SiteAccessConfig {
149
149
  }
150
150
  export interface AdminConfig {
151
151
  role?: Role;
152
+ /**
153
+ * Enforce authentication if set to true. If set to 'auto' it will enforce authentication if a role mapping is defined. defaults to 'auto'.
154
+ */
155
+ requireAuth?: boolean | 'auto';
152
156
  /**
153
157
  * the id of the API key(s). this is used to validate the API KEYS and allows to invalidate them.
154
158
  */