@@ -22,43 +22,42 @@ export type ResponseHeader = Record<string, string>
2222export type ObjectMetaData = Record < string , string | number >
2323
2424export type RequestHeaders = Record < string , string | boolean | number | undefined >
25+ export type EnabledOrDisabledStatus = 'Enabled' | 'Disabled'
26+
27+ export const ENCRYPTION_TYPES = {
28+ SSEC : 'SSE-C' ,
29+ KMS : 'KMS' ,
30+ } as const
31+
32+ export type ENCRYPTION_TYPES = ( typeof ENCRYPTION_TYPES ) [ keyof typeof ENCRYPTION_TYPES ]
2533
2634export type Encryption =
2735 | {
28- type : ENCRYPTION_TYPES . SSEC
36+ type : typeof ENCRYPTION_TYPES . SSEC
2937 }
3038 | {
31- type : ENCRYPTION_TYPES . KMS
39+ type : typeof ENCRYPTION_TYPES . KMS
3240 SSEAlgorithm ?: string
3341 KMSMasterKeyID ?: string
3442 }
3543
36- export type EnabledOrDisabledStatus = 'Enabled' | 'Disabled'
37- export enum ENCRYPTION_TYPES {
38- /**
39- * SSEC represents server-side-encryption with customer provided keys
40- */
41- SSEC = 'SSE-C' ,
42- /**
43- * KMS represents server-side-encryption with managed keys
44- */
45- KMS = 'KMS' ,
46- }
47-
48- export enum RETENTION_MODES {
49- GOVERNANCE = 'GOVERNANCE' ,
50- COMPLIANCE = 'COMPLIANCE' ,
51- }
52-
53- export enum RETENTION_VALIDITY_UNITS {
54- DAYS = 'Days' ,
55- YEARS = 'Years' ,
56- }
57-
58- export enum LEGAL_HOLD_STATUS {
59- ENABLED = 'ON' ,
60- DISABLED = 'OFF' ,
61- }
44+ export const RETENTION_MODES = {
45+ GOVERNANCE : 'GOVERNANCE' ,
46+ COMPLIANCE : 'COMPLIANCE' ,
47+ } as const
48+ export type RETENTION_MODES = ( typeof RETENTION_MODES ) [ keyof typeof RETENTION_MODES ]
49+
50+ export const RETENTION_VALIDITY_UNITS = {
51+ DAYS : 'Days' ,
52+ YEARS : 'Years' ,
53+ } as const
54+ export type RETENTION_VALIDITY_UNITS = ( typeof RETENTION_VALIDITY_UNITS ) [ keyof typeof RETENTION_VALIDITY_UNITS ]
55+
56+ export const LEGAL_HOLD_STATUS = {
57+ ENABLED : 'ON' ,
58+ DISABLED : 'OFF' ,
59+ } as const
60+ export type LEGAL_HOLD_STATUS = ( typeof LEGAL_HOLD_STATUS ) [ keyof typeof LEGAL_HOLD_STATUS ]
6261
6362export type Transport = Pick < typeof http , 'request' >
6463
0 commit comments