app-settings-js 0.1.0

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.
@@ -0,0 +1,204 @@
1
+ /**
2
+ * Wire types for the App Settings HTTP API.
3
+ *
4
+ * Every shape here mirrors what the Go server actually emits, so a response can
5
+ * be handed straight to these types without a translation layer.
6
+ */
7
+ /** A value stored against a setting. Everything is JSONB, so JSON is the "any". */
8
+ export type SettingValue = unknown;
9
+ /** The declared type of a setting. */
10
+ export type SettingType = "BOOLEAN" | "NUMBER" | "STRING" | "DATETIME" | "SELECT" | "JSON";
11
+ /** The highest layer a setting's value may live in. */
12
+ export type SettingScope = "PERSONAL" | "INTERMEDIATE" | "SERVER";
13
+ /** The layer an effective value came from. */
14
+ export type ValueSource = "UNSET" | "DEFAULT" | "SERVER" | "INTERMEDIATE" | "PERSONAL";
15
+ /** One capability an API key may hold. `*` grants all of them. */
16
+ export type Scope = "*" | "resolve" | "settings:read" | "settings:write" | "values:read" | "values:write" | "groups:read" | "groups:write" | "taxonomy:read" | "taxonomy:write" | "keys:read" | "keys:write";
17
+ /** A stable, machine-readable error identifier from the server. */
18
+ export type ErrorCode = "invalid_request" | "unauthorized" | "forbidden" | "not_found" | "conflict" | "internal_error" | "unavailable";
19
+ /** One choice of a SELECT, on the wire as a `[label, value]` tuple. */
20
+ export type SelectOption = [label: string, value: SettingValue];
21
+ /**
22
+ * The rules attached to a setting's type. Only the fields relevant to the
23
+ * setting's own type are consulted by the server.
24
+ */
25
+ export interface TypeConfig {
26
+ /** SELECT: the scalar type its options are drawn from. */
27
+ type?: Exclude<SettingType, "SELECT" | "JSON">;
28
+ /** SELECT: the available choices. */
29
+ options?: SelectOption[];
30
+ /** SELECT: whether the value is an array of options rather than one. */
31
+ multiple?: boolean;
32
+ /** NUMBER bounds, inclusive. */
33
+ min?: number;
34
+ max?: number;
35
+ /** NUMBER: reject values with a fractional part. */
36
+ integer?: boolean;
37
+ /** STRING length bounds, inclusive. */
38
+ min_length?: number;
39
+ max_length?: number;
40
+ /** STRING: RE2 syntax, anchored to the whole value. */
41
+ pattern?: string;
42
+ }
43
+ /** A setting definition. */
44
+ export interface Setting {
45
+ id: string;
46
+ name: string;
47
+ description: string;
48
+ type: SettingType;
49
+ type_config: TypeConfig;
50
+ role: string;
51
+ scope: SettingScope;
52
+ platform: string;
53
+ environment: string;
54
+ default_value: SettingValue;
55
+ created_at: string;
56
+ created_by: string;
57
+ updated_at: string;
58
+ updated_by: string;
59
+ }
60
+ /** A group override that shaped an effective value. */
61
+ export interface Override {
62
+ group_id: string;
63
+ /** An enforced override beats the user's own value; an advisory one yields to it. */
64
+ enforced: boolean;
65
+ /** When false, the user is not meant to observe that anything was overridden. */
66
+ visible: boolean;
67
+ /** The user's own value that an enforced override pushed aside, if there was one. */
68
+ replaced_value?: SettingValue;
69
+ }
70
+ /** One setting collapsed to a single effective value. */
71
+ export interface ResolvedSetting {
72
+ id: string;
73
+ name: string;
74
+ description?: string;
75
+ type: SettingType;
76
+ type_config?: TypeConfig;
77
+ role: string;
78
+ scope: SettingScope;
79
+ platform: string;
80
+ environment: string;
81
+ /** The effective value, or null when `source` is `UNSET`. */
82
+ value: SettingValue;
83
+ source: ValueSource;
84
+ override?: Override;
85
+ }
86
+ /** The body of a resolution response. */
87
+ export interface ResolveResponse {
88
+ environment: string;
89
+ platforms?: string[];
90
+ user_id?: string;
91
+ role: string;
92
+ settings: ResolvedSetting[];
93
+ resolved_at: string;
94
+ }
95
+ /** A stored value in the server layer. */
96
+ export interface ServerValue {
97
+ id: string;
98
+ setting_id: string;
99
+ value: SettingValue;
100
+ created_at: string;
101
+ created_by: string;
102
+ updated_at: string;
103
+ updated_by: string;
104
+ }
105
+ /** A stored value in the personal layer. */
106
+ export interface PersonalValue extends ServerValue {
107
+ user_id: string;
108
+ }
109
+ /** A stored value in the intermediate layer. */
110
+ export interface IntermediateValue extends ServerValue {
111
+ group_id: string;
112
+ visible: boolean;
113
+ is_enforced: boolean;
114
+ }
115
+ /** A group of users carrying the intermediate layer. */
116
+ export interface Group {
117
+ id: string;
118
+ name: string;
119
+ description: string;
120
+ /** null means the group applies across every environment. */
121
+ environment: string | null;
122
+ /** Higher priority wins when two groups override the same setting. */
123
+ priority: number;
124
+ is_ephemeral: boolean;
125
+ created_at: string;
126
+ created_by: string;
127
+ updated_at: string;
128
+ updated_by: string;
129
+ }
130
+ /** One membership row. */
131
+ export interface GroupMember {
132
+ group_id: string;
133
+ user_id: string;
134
+ created_at: string;
135
+ created_by: string;
136
+ }
137
+ /** An API key, as returned by the server. The token itself is never included. */
138
+ export interface ApiKey {
139
+ id: string;
140
+ name: string;
141
+ prefix: string;
142
+ scopes: Scope[];
143
+ /** Empty means every environment. */
144
+ environments: string[];
145
+ /** Empty means every platform. */
146
+ platforms: string[];
147
+ role: string;
148
+ is_bootstrap: boolean;
149
+ expires_at: string | null;
150
+ revoked_at: string | null;
151
+ last_used_at: string | null;
152
+ created_at: string;
153
+ created_by: string;
154
+ }
155
+ /** The one and only time a new key's token is available. */
156
+ export interface CreatedApiKey {
157
+ key: ApiKey;
158
+ /** The full token. It is not recoverable: only its hash is kept. */
159
+ token: string;
160
+ warning: string;
161
+ }
162
+ /** A role. Rank orders roles; a setting is visible to every role at or above its own. */
163
+ export interface Role {
164
+ name: string;
165
+ description: string;
166
+ rank: number;
167
+ is_system: boolean;
168
+ created_at: string;
169
+ updated_at: string;
170
+ }
171
+ /** A platform a setting may apply to. */
172
+ export interface Platform {
173
+ name: string;
174
+ description: string;
175
+ is_system: boolean;
176
+ created_at: string;
177
+ updated_at: string;
178
+ }
179
+ /** An environment a setting may be scoped to. */
180
+ export interface Environment {
181
+ name: string;
182
+ description: string;
183
+ is_system: boolean;
184
+ created_at: string;
185
+ updated_at: string;
186
+ }
187
+ /** A description of the calling key. */
188
+ export interface WhoAmI {
189
+ key_id: string;
190
+ name: string;
191
+ /** The key with its secret masked, safe to display. */
192
+ key: string;
193
+ scopes: Scope[];
194
+ environments: string[];
195
+ platforms: string[];
196
+ role: string;
197
+ is_bootstrap: boolean;
198
+ }
199
+ /** The health endpoint's body. */
200
+ export interface Health {
201
+ status: "ok" | "degraded";
202
+ database?: string;
203
+ cache?: string;
204
+ }
@@ -0,0 +1,205 @@
1
+ /**
2
+ * Wire types for the App Settings HTTP API.
3
+ *
4
+ * Every shape here mirrors what the Go server actually emits, so a response can
5
+ * be handed straight to these types without a translation layer.
6
+ */
7
+ /** A value stored against a setting. Everything is JSONB, so JSON is the "any". */
8
+ export type SettingValue = unknown;
9
+ /** The declared type of a setting. */
10
+ export type SettingType = "BOOLEAN" | "NUMBER" | "STRING" | "DATETIME" | "SELECT" | "JSON";
11
+ /** The highest layer a setting's value may live in. */
12
+ export type SettingScope = "PERSONAL" | "INTERMEDIATE" | "SERVER";
13
+ /** The layer an effective value came from. */
14
+ export type ValueSource = "UNSET" | "DEFAULT" | "SERVER" | "INTERMEDIATE" | "PERSONAL";
15
+ /** One capability an API key may hold. `*` grants all of them. */
16
+ export type Scope = "*" | "resolve" | "settings:read" | "settings:write" | "values:read" | "values:write" | "groups:read" | "groups:write" | "taxonomy:read" | "taxonomy:write" | "keys:read" | "keys:write";
17
+ /** A stable, machine-readable error identifier from the server. */
18
+ export type ErrorCode = "invalid_request" | "unauthorized" | "forbidden" | "not_found" | "conflict" | "internal_error" | "unavailable";
19
+ /** One choice of a SELECT, on the wire as a `[label, value]` tuple. */
20
+ export type SelectOption = [label: string, value: SettingValue];
21
+ /**
22
+ * The rules attached to a setting's type. Only the fields relevant to the
23
+ * setting's own type are consulted by the server.
24
+ */
25
+ export interface TypeConfig {
26
+ /** SELECT: the scalar type its options are drawn from. */
27
+ type?: Exclude<SettingType, "SELECT" | "JSON">;
28
+ /** SELECT: the available choices. */
29
+ options?: SelectOption[];
30
+ /** SELECT: whether the value is an array of options rather than one. */
31
+ multiple?: boolean;
32
+ /** NUMBER bounds, inclusive. */
33
+ min?: number;
34
+ max?: number;
35
+ /** NUMBER: reject values with a fractional part. */
36
+ integer?: boolean;
37
+ /** STRING length bounds, inclusive. */
38
+ min_length?: number;
39
+ max_length?: number;
40
+ /** STRING: RE2 syntax, anchored to the whole value. */
41
+ pattern?: string;
42
+ }
43
+ /** A setting definition. */
44
+ export interface Setting {
45
+ id: string;
46
+ name: string;
47
+ description: string;
48
+ type: SettingType;
49
+ type_config: TypeConfig;
50
+ role: string;
51
+ scope: SettingScope;
52
+ platform: string;
53
+ environment: string;
54
+ default_value: SettingValue;
55
+ created_at: string;
56
+ created_by: string;
57
+ updated_at: string;
58
+ updated_by: string;
59
+ }
60
+ /** A group override that shaped an effective value. */
61
+ export interface Override {
62
+ group_id: string;
63
+ /** An enforced override beats the user's own value; an advisory one yields to it. */
64
+ enforced: boolean;
65
+ /** When false, the user is not meant to observe that anything was overridden. */
66
+ visible: boolean;
67
+ /** The user's own value that an enforced override pushed aside, if there was one. */
68
+ replaced_value?: SettingValue;
69
+ }
70
+ /** One setting collapsed to a single effective value. */
71
+ export interface ResolvedSetting {
72
+ id: string;
73
+ name: string;
74
+ description?: string;
75
+ type: SettingType;
76
+ type_config?: TypeConfig;
77
+ role: string;
78
+ scope: SettingScope;
79
+ platform: string;
80
+ environment: string;
81
+ /** The effective value, or null when `source` is `UNSET`. */
82
+ value: SettingValue;
83
+ source: ValueSource;
84
+ override?: Override;
85
+ }
86
+ /** The body of a resolution response. */
87
+ export interface ResolveResponse {
88
+ environment: string;
89
+ platforms?: string[];
90
+ user_id?: string;
91
+ role: string;
92
+ settings: ResolvedSetting[];
93
+ resolved_at: string;
94
+ }
95
+ /** A stored value in the server layer. */
96
+ export interface ServerValue {
97
+ id: string;
98
+ setting_id: string;
99
+ value: SettingValue;
100
+ created_at: string;
101
+ created_by: string;
102
+ updated_at: string;
103
+ updated_by: string;
104
+ }
105
+ /** A stored value in the personal layer. */
106
+ export interface PersonalValue extends ServerValue {
107
+ user_id: string;
108
+ }
109
+ /** A stored value in the intermediate layer. */
110
+ export interface IntermediateValue extends ServerValue {
111
+ group_id: string;
112
+ visible: boolean;
113
+ is_enforced: boolean;
114
+ }
115
+ /** A group of users carrying the intermediate layer. */
116
+ export interface Group {
117
+ id: string;
118
+ name: string;
119
+ description: string;
120
+ /** null means the group applies across every environment. */
121
+ environment: string | null;
122
+ /** Higher priority wins when two groups override the same setting. */
123
+ priority: number;
124
+ is_ephemeral: boolean;
125
+ created_at: string;
126
+ created_by: string;
127
+ updated_at: string;
128
+ updated_by: string;
129
+ }
130
+ /** One membership row. */
131
+ export interface GroupMember {
132
+ group_id: string;
133
+ user_id: string;
134
+ created_at: string;
135
+ created_by: string;
136
+ }
137
+ /** An API key, as returned by the server. The token itself is never included. */
138
+ export interface ApiKey {
139
+ id: string;
140
+ name: string;
141
+ prefix: string;
142
+ scopes: Scope[];
143
+ /** Empty means every environment. */
144
+ environments: string[];
145
+ /** Empty means every platform. */
146
+ platforms: string[];
147
+ role: string;
148
+ is_bootstrap: boolean;
149
+ expires_at: string | null;
150
+ revoked_at: string | null;
151
+ last_used_at: string | null;
152
+ created_at: string;
153
+ created_by: string;
154
+ }
155
+ /** The one and only time a new key's token is available. */
156
+ export interface CreatedApiKey {
157
+ key: ApiKey;
158
+ /** The full token. It is not recoverable: only its hash is kept. */
159
+ token: string;
160
+ warning: string;
161
+ }
162
+ /** A role. Rank orders roles; a setting is visible to every role at or above its own. */
163
+ export interface Role {
164
+ name: string;
165
+ description: string;
166
+ rank: number;
167
+ is_system: boolean;
168
+ created_at: string;
169
+ updated_at: string;
170
+ }
171
+ /** A platform a setting may apply to. */
172
+ export interface Platform {
173
+ name: string;
174
+ description: string;
175
+ is_system: boolean;
176
+ created_at: string;
177
+ updated_at: string;
178
+ }
179
+ /** An environment a setting may be scoped to. */
180
+ export interface Environment {
181
+ name: string;
182
+ description: string;
183
+ is_system: boolean;
184
+ created_at: string;
185
+ updated_at: string;
186
+ }
187
+ /** A description of the calling key. */
188
+ export interface WhoAmI {
189
+ key_id: string;
190
+ name: string;
191
+ /** The key with its secret masked, safe to display. */
192
+ key: string;
193
+ scopes: Scope[];
194
+ environments: string[];
195
+ platforms: string[];
196
+ role: string;
197
+ is_bootstrap: boolean;
198
+ }
199
+ /** The health endpoint's body. */
200
+ export interface Health {
201
+ status: "ok" | "degraded";
202
+ database?: string;
203
+ cache?: string;
204
+ }
205
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,mFAAmF;AACnF,MAAM,MAAM,YAAY,GAAG,OAAO,CAAC;AAEnC,sCAAsC;AACtC,MAAM,MAAM,WAAW,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,CAAC;AAE3F,uDAAuD;AACvD,MAAM,MAAM,YAAY,GAAG,UAAU,GAAG,cAAc,GAAG,QAAQ,CAAC;AAElE,8CAA8C;AAC9C,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,GAAG,cAAc,GAAG,UAAU,CAAC;AAEvF,kEAAkE;AAClE,MAAM,MAAM,KAAK,GACb,GAAG,GACH,SAAS,GACT,eAAe,GACf,gBAAgB,GAChB,aAAa,GACb,cAAc,GACd,aAAa,GACb,cAAc,GACd,eAAe,GACf,gBAAgB,GAChB,WAAW,GACX,YAAY,CAAC;AAEjB,mEAAmE;AACnE,MAAM,MAAM,SAAS,GACjB,iBAAiB,GACjB,cAAc,GACd,WAAW,GACX,WAAW,GACX,UAAU,GACV,gBAAgB,GAChB,aAAa,CAAC;AAElB,uEAAuE;AACvE,MAAM,MAAM,YAAY,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,CAAC,CAAC;AAEhE;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB,0DAA0D;IAC1D,IAAI,CAAC,EAAE,OAAO,CAAC,WAAW,EAAE,QAAQ,GAAG,MAAM,CAAC,CAAC;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ED,yCAAyC;AACzC,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,iDAAiD;AACjD,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,wCAAwC;AACxC,MAAM,WAAW,MAAM;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,uDAAuD;IACvD,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,KAAK,EAAE,CAAC;IAChB,YAAY,EAAE,MAAM,EAAE,CAAC;IACvB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,OAAO,CAAC;CACvB;AAED,kCAAkC;AAClC,MAAM,WAAW,MAAM;IACrB,MAAM,EAAE,IAAI,GAAG,UAAU,CAAC;IAC1B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB"}
package/package.json ADDED
@@ -0,0 +1,72 @@
1
+ {
2
+ "name": "app-settings-js",
3
+ "version": "0.1.0",
4
+ "description": "TypeScript SDK for the App Settings API: role-based, layered application settings. No dependencies; runs in browsers, Node, Bun and Deno.",
5
+ "keywords": [
6
+ "app-settings",
7
+ "settings",
8
+ "preferences",
9
+ "feature-flags",
10
+ "configuration",
11
+ "remote-config",
12
+ "sdk",
13
+ "typescript",
14
+ "isomorphic"
15
+ ],
16
+ "homepage": "https://github.com/connordoman/app-settings/tree/main/app-settings-js#readme",
17
+ "bugs": {
18
+ "url": "https://github.com/connordoman/app-settings/issues"
19
+ },
20
+ "repository": {
21
+ "type": "git",
22
+ "url": "git+https://github.com/connordoman/app-settings.git",
23
+ "directory": "app-settings-js"
24
+ },
25
+ "license": "MIT",
26
+ "author": "Connor Doman <connor@connordoman.dev>",
27
+ "type": "module",
28
+ "main": "./dist/index.cjs",
29
+ "module": "./dist/index.js",
30
+ "types": "./dist/index.d.ts",
31
+ "unpkg": "./dist/index.js",
32
+ "jsdelivr": "./dist/index.js",
33
+ "exports": {
34
+ ".": {
35
+ "import": {
36
+ "types": "./dist/index.d.ts",
37
+ "default": "./dist/index.js"
38
+ },
39
+ "require": {
40
+ "types": "./dist/index.d.cts",
41
+ "default": "./dist/index.cjs"
42
+ }
43
+ },
44
+ "./package.json": "./package.json"
45
+ },
46
+ "files": [
47
+ "dist",
48
+ "src",
49
+ "README.md",
50
+ "LICENSE",
51
+ "CHANGELOG.md"
52
+ ],
53
+ "engines": {
54
+ "node": ">=18"
55
+ },
56
+ "publishConfig": {
57
+ "access": "public"
58
+ },
59
+ "scripts": {
60
+ "build": "bun run scripts/build.ts",
61
+ "clean": "rm -rf dist",
62
+ "test": "bun test",
63
+ "typecheck": "tsc --noEmit -p tsconfig.json",
64
+ "check": "bun run typecheck && bun test",
65
+ "pack": "bun run build && bun pm pack --dry-run",
66
+ "prepublishOnly": "bun run check && bun run build"
67
+ },
68
+ "devDependencies": {
69
+ "@types/bun": "latest",
70
+ "typescript": "^7.0.2"
71
+ }
72
+ }