@zyphr-dev/node-sdk 0.1.49 → 0.1.50
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/dist/index.cjs +21 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +33 -5
- package/dist/index.d.ts +33 -5
- package/dist/index.js +19 -5
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/src/models/ApplicationSelf.ts +19 -1
- package/src/src/models/SetSelfApplicationTestRecipientsRequest.ts +23 -5
package/package.json
CHANGED
|
@@ -48,11 +48,17 @@ export interface ApplicationSelf {
|
|
|
48
48
|
*/
|
|
49
49
|
signingAlgorithm: ApplicationSelfSigningAlgorithmEnum;
|
|
50
50
|
/**
|
|
51
|
-
* The auth-email
|
|
51
|
+
* The auth-email allowlist. In `allowlist` mode, only these addresses receive auth emails; in `unrestricted` mode it is ignored. Settable via PATCH /auth/application (sc-7600).
|
|
52
52
|
* @type {Array<string>}
|
|
53
53
|
* @memberof ApplicationSelf
|
|
54
54
|
*/
|
|
55
55
|
testRecipients: Array<string>;
|
|
56
|
+
/**
|
|
57
|
+
* Explicit auth-email gate mode (sc-7673). `unrestricted` sends auth emails to everyone. `allowlist` restricts auth email to `test_recipients` — and an EMPTY allowlist in this mode fails CLOSED (blocks all auth email). This replaces the previous behavior where the gate was inferred from whether `test_recipients` was empty. Defaults to `unrestricted`.
|
|
58
|
+
* @type {string}
|
|
59
|
+
* @memberof ApplicationSelf
|
|
60
|
+
*/
|
|
61
|
+
authEmailMode: ApplicationSelfAuthEmailModeEnum;
|
|
56
62
|
}
|
|
57
63
|
|
|
58
64
|
|
|
@@ -75,6 +81,15 @@ export const ApplicationSelfSigningAlgorithmEnum = {
|
|
|
75
81
|
} as const;
|
|
76
82
|
export type ApplicationSelfSigningAlgorithmEnum = typeof ApplicationSelfSigningAlgorithmEnum[keyof typeof ApplicationSelfSigningAlgorithmEnum];
|
|
77
83
|
|
|
84
|
+
/**
|
|
85
|
+
* @export
|
|
86
|
+
*/
|
|
87
|
+
export const ApplicationSelfAuthEmailModeEnum = {
|
|
88
|
+
ALLOWLIST: 'allowlist',
|
|
89
|
+
UNRESTRICTED: 'unrestricted'
|
|
90
|
+
} as const;
|
|
91
|
+
export type ApplicationSelfAuthEmailModeEnum = typeof ApplicationSelfAuthEmailModeEnum[keyof typeof ApplicationSelfAuthEmailModeEnum];
|
|
92
|
+
|
|
78
93
|
|
|
79
94
|
/**
|
|
80
95
|
* Check if a given object implements the ApplicationSelf interface.
|
|
@@ -85,6 +100,7 @@ export function instanceOfApplicationSelf(value: object): value is ApplicationSe
|
|
|
85
100
|
if (!('environment' in value) || value['environment'] === undefined) return false;
|
|
86
101
|
if (!('signingAlgorithm' in value) || value['signingAlgorithm'] === undefined) return false;
|
|
87
102
|
if (!('testRecipients' in value) || value['testRecipients'] === undefined) return false;
|
|
103
|
+
if (!('authEmailMode' in value) || value['authEmailMode'] === undefined) return false;
|
|
88
104
|
return true;
|
|
89
105
|
}
|
|
90
106
|
|
|
@@ -103,6 +119,7 @@ export function ApplicationSelfFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
103
119
|
'environment': json['environment'],
|
|
104
120
|
'signingAlgorithm': json['signing_algorithm'],
|
|
105
121
|
'testRecipients': json['test_recipients'],
|
|
122
|
+
'authEmailMode': json['auth_email_mode'],
|
|
106
123
|
};
|
|
107
124
|
}
|
|
108
125
|
|
|
@@ -122,6 +139,7 @@ export function ApplicationSelfToJSONTyped(value?: ApplicationSelf | null, ignor
|
|
|
122
139
|
'environment': value['environment'],
|
|
123
140
|
'signing_algorithm': value['signingAlgorithm'],
|
|
124
141
|
'test_recipients': value['testRecipients'],
|
|
142
|
+
'auth_email_mode': value['authEmailMode'],
|
|
125
143
|
};
|
|
126
144
|
}
|
|
127
145
|
|
|
@@ -14,24 +14,40 @@
|
|
|
14
14
|
|
|
15
15
|
import { mapValues } from '../runtime';
|
|
16
16
|
/**
|
|
17
|
-
*
|
|
17
|
+
* Provide test_recipients and/or auth_email_mode. Omitting one leaves that value unchanged; sending neither is a 400.
|
|
18
18
|
* @export
|
|
19
19
|
* @interface SetSelfApplicationTestRecipientsRequest
|
|
20
20
|
*/
|
|
21
21
|
export interface SetSelfApplicationTestRecipientsRequest {
|
|
22
22
|
/**
|
|
23
|
-
* Email addresses allowed to receive auth emails.
|
|
23
|
+
* Email addresses allowed to receive auth emails when auth_email_mode is 'allowlist'. Ignored in 'unrestricted' mode. Optional — omit to leave the current list unchanged.
|
|
24
24
|
* @type {Array<string>}
|
|
25
25
|
* @memberof SetSelfApplicationTestRecipientsRequest
|
|
26
26
|
*/
|
|
27
|
-
testRecipients
|
|
27
|
+
testRecipients?: Array<string>;
|
|
28
|
+
/**
|
|
29
|
+
* Optional (sc-7673). Explicit auth-email gate mode. 'unrestricted' sends to everyone; 'allowlist' restricts to test_recipients (an EMPTY list in allowlist mode fails closed — blocks all auth email). Omit to leave the current mode unchanged.
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof SetSelfApplicationTestRecipientsRequest
|
|
32
|
+
*/
|
|
33
|
+
authEmailMode?: SetSelfApplicationTestRecipientsRequestAuthEmailModeEnum;
|
|
28
34
|
}
|
|
29
35
|
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export const SetSelfApplicationTestRecipientsRequestAuthEmailModeEnum = {
|
|
41
|
+
ALLOWLIST: 'allowlist',
|
|
42
|
+
UNRESTRICTED: 'unrestricted'
|
|
43
|
+
} as const;
|
|
44
|
+
export type SetSelfApplicationTestRecipientsRequestAuthEmailModeEnum = typeof SetSelfApplicationTestRecipientsRequestAuthEmailModeEnum[keyof typeof SetSelfApplicationTestRecipientsRequestAuthEmailModeEnum];
|
|
45
|
+
|
|
46
|
+
|
|
30
47
|
/**
|
|
31
48
|
* Check if a given object implements the SetSelfApplicationTestRecipientsRequest interface.
|
|
32
49
|
*/
|
|
33
50
|
export function instanceOfSetSelfApplicationTestRecipientsRequest(value: object): value is SetSelfApplicationTestRecipientsRequest {
|
|
34
|
-
if (!('testRecipients' in value) || value['testRecipients'] === undefined) return false;
|
|
35
51
|
return true;
|
|
36
52
|
}
|
|
37
53
|
|
|
@@ -45,7 +61,8 @@ export function SetSelfApplicationTestRecipientsRequestFromJSONTyped(json: any,
|
|
|
45
61
|
}
|
|
46
62
|
return {
|
|
47
63
|
|
|
48
|
-
'testRecipients': json['test_recipients'],
|
|
64
|
+
'testRecipients': json['test_recipients'] == null ? undefined : json['test_recipients'],
|
|
65
|
+
'authEmailMode': json['auth_email_mode'] == null ? undefined : json['auth_email_mode'],
|
|
49
66
|
};
|
|
50
67
|
}
|
|
51
68
|
|
|
@@ -61,6 +78,7 @@ export function SetSelfApplicationTestRecipientsRequestToJSONTyped(value?: SetSe
|
|
|
61
78
|
return {
|
|
62
79
|
|
|
63
80
|
'test_recipients': value['testRecipients'],
|
|
81
|
+
'auth_email_mode': value['authEmailMode'],
|
|
64
82
|
};
|
|
65
83
|
}
|
|
66
84
|
|