@oxy.so/contracts 6.17.0 → 6.18.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.
|
@@ -128,4 +128,11 @@ exports.IDENTITY_ERROR_CODES = {
|
|
|
128
128
|
* the previous phrase, so it is never silently replaced.
|
|
129
129
|
*/
|
|
130
130
|
backupSuperseded: 'IDENTITY_BACKUP_SUPERSEDED',
|
|
131
|
+
/**
|
|
132
|
+
* `POST /identity/backup`: the person deleted their encrypted backup, and
|
|
133
|
+
* the upload is not their explicit choice to create one again (`optIn`). A
|
|
134
|
+
* key rotation, a re-seal or another device never re-uploads a backup the
|
|
135
|
+
* person deleted (owner's decision, 2026-11-07).
|
|
136
|
+
*/
|
|
137
|
+
backupOptedOut: 'IDENTITY_BACKUP_OPTED_OUT',
|
|
131
138
|
};
|
package/dist/cjs/keyRecovery.js
CHANGED
|
@@ -115,6 +115,17 @@ exports.backupUploadRequestSchema = backupEnvelopeFields.extend({
|
|
|
115
115
|
* when the stored backup is current or there is none.
|
|
116
116
|
*/
|
|
117
117
|
replacesLookupId: exports.backupLookupIdSchema.optional(),
|
|
118
|
+
/**
|
|
119
|
+
* The person's explicit choice to have a backup (owner's decision,
|
|
120
|
+
* 2026-11-07). A person who deleted their backup (`status.optedOut`) gets a
|
|
121
|
+
* new one only with it: an upload without it is refused (409
|
|
122
|
+
* `IDENTITY_BACKUP_OPTED_OUT`), so a key rotation, a re-seal or another
|
|
123
|
+
* device never re-uploads silently. An accepted upload with it clears the
|
|
124
|
+
* deletion in the same transaction. Ignored when the person never deleted
|
|
125
|
+
* one. Clients send it only from a control the person pressed ("Create
|
|
126
|
+
* backup", or the rotation's "Create a backup" choice).
|
|
127
|
+
*/
|
|
128
|
+
optIn: zod_1.z.boolean().optional(),
|
|
118
129
|
});
|
|
119
130
|
/**
|
|
120
131
|
* Response of `GET /identity/backup/status` (and the write/delete acks): whether
|
|
@@ -130,6 +141,16 @@ exports.backupStatusResponseSchema = zod_1.z.object({
|
|
|
130
141
|
* replaces it only with `replacesLookupId`. Absent otherwise.
|
|
131
142
|
*/
|
|
132
143
|
superseded: zod_1.z.boolean().optional(),
|
|
144
|
+
/**
|
|
145
|
+
* `true` when the PERSON deleted their backup (`DELETE /identity/backup`)
|
|
146
|
+
* and has not chosen to create one since (owner's decision, 2026-11-07):
|
|
147
|
+
* `exists` is `false`. Told apart from "never had one" (absent) and from a
|
|
148
|
+
* rotation's `superseded`. Recorded on the account, so every device reads
|
|
149
|
+
* it: no client re-uploads a backup without the person's explicit opt-in
|
|
150
|
+
* (`optIn` on the upload). Without a backup, keys a rotation retired are
|
|
151
|
+
* recoverable off this phone only with their own recovery phrases.
|
|
152
|
+
*/
|
|
153
|
+
optedOut: zod_1.z.boolean().optional(),
|
|
133
154
|
publicKeyHint: zod_1.z.string().optional(),
|
|
134
155
|
createdAt: zod_1.z.string().optional(),
|
|
135
156
|
});
|
|
@@ -123,4 +123,11 @@ export const IDENTITY_ERROR_CODES = {
|
|
|
123
123
|
* the previous phrase, so it is never silently replaced.
|
|
124
124
|
*/
|
|
125
125
|
backupSuperseded: 'IDENTITY_BACKUP_SUPERSEDED',
|
|
126
|
+
/**
|
|
127
|
+
* `POST /identity/backup`: the person deleted their encrypted backup, and
|
|
128
|
+
* the upload is not their explicit choice to create one again (`optIn`). A
|
|
129
|
+
* key rotation, a re-seal or another device never re-uploads a backup the
|
|
130
|
+
* person deleted (owner's decision, 2026-11-07).
|
|
131
|
+
*/
|
|
132
|
+
backupOptedOut: 'IDENTITY_BACKUP_OPTED_OUT',
|
|
126
133
|
};
|
package/dist/esm/keyRecovery.js
CHANGED
|
@@ -112,6 +112,17 @@ export const backupUploadRequestSchema = backupEnvelopeFields.extend({
|
|
|
112
112
|
* when the stored backup is current or there is none.
|
|
113
113
|
*/
|
|
114
114
|
replacesLookupId: backupLookupIdSchema.optional(),
|
|
115
|
+
/**
|
|
116
|
+
* The person's explicit choice to have a backup (owner's decision,
|
|
117
|
+
* 2026-11-07). A person who deleted their backup (`status.optedOut`) gets a
|
|
118
|
+
* new one only with it: an upload without it is refused (409
|
|
119
|
+
* `IDENTITY_BACKUP_OPTED_OUT`), so a key rotation, a re-seal or another
|
|
120
|
+
* device never re-uploads silently. An accepted upload with it clears the
|
|
121
|
+
* deletion in the same transaction. Ignored when the person never deleted
|
|
122
|
+
* one. Clients send it only from a control the person pressed ("Create
|
|
123
|
+
* backup", or the rotation's "Create a backup" choice).
|
|
124
|
+
*/
|
|
125
|
+
optIn: z.boolean().optional(),
|
|
115
126
|
});
|
|
116
127
|
/**
|
|
117
128
|
* Response of `GET /identity/backup/status` (and the write/delete acks): whether
|
|
@@ -127,6 +138,16 @@ export const backupStatusResponseSchema = z.object({
|
|
|
127
138
|
* replaces it only with `replacesLookupId`. Absent otherwise.
|
|
128
139
|
*/
|
|
129
140
|
superseded: z.boolean().optional(),
|
|
141
|
+
/**
|
|
142
|
+
* `true` when the PERSON deleted their backup (`DELETE /identity/backup`)
|
|
143
|
+
* and has not chosen to create one since (owner's decision, 2026-11-07):
|
|
144
|
+
* `exists` is `false`. Told apart from "never had one" (absent) and from a
|
|
145
|
+
* rotation's `superseded`. Recorded on the account, so every device reads
|
|
146
|
+
* it: no client re-uploads a backup without the person's explicit opt-in
|
|
147
|
+
* (`optIn` on the upload). Without a backup, keys a rotation retired are
|
|
148
|
+
* recoverable off this phone only with their own recovery phrases.
|
|
149
|
+
*/
|
|
150
|
+
optedOut: z.boolean().optional(),
|
|
130
151
|
publicKeyHint: z.string().optional(),
|
|
131
152
|
createdAt: z.string().optional(),
|
|
132
153
|
});
|
|
@@ -91,5 +91,12 @@ export declare const IDENTITY_ERROR_CODES: {
|
|
|
91
91
|
* the previous phrase, so it is never silently replaced.
|
|
92
92
|
*/
|
|
93
93
|
readonly backupSuperseded: "IDENTITY_BACKUP_SUPERSEDED";
|
|
94
|
+
/**
|
|
95
|
+
* `POST /identity/backup`: the person deleted their encrypted backup, and
|
|
96
|
+
* the upload is not their explicit choice to create one again (`optIn`). A
|
|
97
|
+
* key rotation, a re-seal or another device never re-uploads a backup the
|
|
98
|
+
* person deleted (owner's decision, 2026-11-07).
|
|
99
|
+
*/
|
|
100
|
+
readonly backupOptedOut: "IDENTITY_BACKUP_OPTED_OUT";
|
|
94
101
|
};
|
|
95
102
|
export type IdentityErrorCode = (typeof IDENTITY_ERROR_CODES)[keyof typeof IDENTITY_ERROR_CODES];
|
|
@@ -71,6 +71,7 @@ export declare const backupUploadRequestSchema: z.ZodObject<{
|
|
|
71
71
|
version: z.ZodNumber;
|
|
72
72
|
lookupId: z.ZodString;
|
|
73
73
|
replacesLookupId: z.ZodOptional<z.ZodString>;
|
|
74
|
+
optIn: z.ZodOptional<z.ZodBoolean>;
|
|
74
75
|
}, z.core.$strip>;
|
|
75
76
|
export type BackupUploadRequest = z.infer<typeof backupUploadRequestSchema>;
|
|
76
77
|
/**
|
|
@@ -81,6 +82,7 @@ export type BackupUploadRequest = z.infer<typeof backupUploadRequestSchema>;
|
|
|
81
82
|
export declare const backupStatusResponseSchema: z.ZodObject<{
|
|
82
83
|
exists: z.ZodBoolean;
|
|
83
84
|
superseded: z.ZodOptional<z.ZodBoolean>;
|
|
85
|
+
optedOut: z.ZodOptional<z.ZodBoolean>;
|
|
84
86
|
publicKeyHint: z.ZodOptional<z.ZodString>;
|
|
85
87
|
createdAt: z.ZodOptional<z.ZodString>;
|
|
86
88
|
}, z.core.$strip>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oxy.so/contracts",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.18.0",
|
|
4
4
|
"description": "OxyHQ API contracts — single source of truth for request/response Zod schemas and inferred types, shared by the backend and the client SDKs",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|