@fabrika/provider-contract 0.0.26 → 0.2.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.
- package/package.json +2 -2
- package/src/control.ts +12 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fabrika/provider-contract",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -26,6 +26,6 @@
|
|
|
26
26
|
"test": "bun test"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@fabrika/auth-core": "^0.0
|
|
29
|
+
"@fabrika/auth-core": "^0.2.0"
|
|
30
30
|
}
|
|
31
31
|
}
|
package/src/control.ts
CHANGED
|
@@ -164,6 +164,18 @@ export class ProviderNamespaceError extends Error {
|
|
|
164
164
|
}
|
|
165
165
|
}
|
|
166
166
|
|
|
167
|
+
/**
|
|
168
|
+
* A provider-managed secret write the provider refuses on the app's own terms — a value naming a
|
|
169
|
+
* service the app does not own, say. `message` carries the secret's name and the offending host,
|
|
170
|
+
* never the value, so core may hand it to the caller as a 4xx.
|
|
171
|
+
*/
|
|
172
|
+
export class ProviderSecretError extends Error {
|
|
173
|
+
constructor(message: string, readonly code: string) {
|
|
174
|
+
super(message)
|
|
175
|
+
this.name = 'ProviderSecretError'
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
167
179
|
/** Persist a canonical namespace target immediately after one external mutation succeeds. */
|
|
168
180
|
export interface ProviderNamespaceEvents {
|
|
169
181
|
checkpoint(namespace: ProviderDeploymentNamespace): Promise<void>
|