@veryfront/ext-blob-gcs 0.1.1184

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/LICENSE ADDED
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
package/NOTICE ADDED
@@ -0,0 +1,2 @@
1
+ Veryfront Code
2
+ Copyright 2026 Veryfront GmbH
package/README.md ADDED
@@ -0,0 +1,117 @@
1
+ # @veryfront/ext-blob-gcs
2
+
3
+ > **Category:** Storage | **Contract:** `BlobStorage` | **Explicit**
4
+
5
+ Use this extension to select Google Cloud Storage as Veryfront's blob store.
6
+
7
+ ## Install and compose
8
+
9
+ Add the package to the application, then compose it explicitly in
10
+ `veryfront.config.ts`:
11
+
12
+ ```ts
13
+ import extBlobGCS from "@veryfront/ext-blob-gcs";
14
+
15
+ function requiredEnvironmentVariable(name: string): string {
16
+ const value = Deno.env.get(name);
17
+ if (!value) throw new Error(`${name} is required`);
18
+ return value;
19
+ }
20
+
21
+ export default {
22
+ extensions: [
23
+ extBlobGCS({
24
+ bucket: requiredEnvironmentVariable("VERYFRONT_BLOB_BUCKET"),
25
+ serviceAccountKey: requiredEnvironmentVariable("GOOGLE_SERVICE_ACCOUNT_JSON"),
26
+ }),
27
+ ],
28
+ };
29
+ ```
30
+
31
+ Supply the complete service-account JSON as `serviceAccountKey`. The extension
32
+ uses its `client_email` and PKCS8 `private_key`; it does not probe ambient Google
33
+ credentials.
34
+
35
+ Do not register another extension that provides `BlobStorage` at the same
36
+ priority. Veryfront rejects that ambiguous selection.
37
+
38
+ ## Configure the provider
39
+
40
+ The factory requires these values:
41
+
42
+ | Option | Purpose |
43
+ | ------------------- | ---------------------------------------------------------------- |
44
+ | `bucket` | Destination Cloud Storage bucket |
45
+ | `serviceAccountKey` | Service-account JSON containing `client_email` and `private_key` |
46
+
47
+ Optional settings are:
48
+
49
+ | Option | Default | Purpose |
50
+ | -------------------- | -------------------------- | ------------------------------------------------------------------------------ |
51
+ | `prefix` | empty | Prefix prepended to each blob ID |
52
+ | `baseUrl` | unset | Public HTTP(S) URL used in returned blob references |
53
+ | `defaultTtl` | unset | Default expiry in seconds; `0` disables expiry |
54
+ | `resumableChunkSize` | 8 MiB | Unknown-length stream chunk size; 256 KiB multiple from 256 KiB through 64 MiB |
55
+ | `signal` | extension lifecycle signal | Cancel token and storage operations |
56
+
57
+ Metadata is normalized to lowercase and limited to 100 entries and 8 KiB,
58
+ including Veryfront's internal expiry value. Unknown-length streams use bounded,
59
+ aligned resumable chunks and validate every provider acknowledgement before
60
+ sending the next chunk.
61
+
62
+ TTL metadata reserves one of the 100 entries, so callers may supply at most 99
63
+ entries when expiry is enabled. Blob IDs use the framework-wide portable
64
+ alphabet: ASCII letters, digits, hyphens, and underscores. Put any provider path
65
+ hierarchy in `prefix`; IDs with slashes, whitespace, query syntax, or Unicode
66
+ are rejected before transport.
67
+
68
+ `BlobRef.url` is omitted unless `baseUrl` is explicitly configured. The JSON
69
+ API's `mediaLink` normally requires authorization and is therefore not exposed
70
+ as a public URL. `baseUrl` requires HTTPS except for `localhost` or a loopback
71
+ IP used during local development.
72
+
73
+ ## Grant capabilities
74
+
75
+ Allow outbound HTTPS access to:
76
+
77
+ - `oauth2.googleapis.com`
78
+ - `storage.googleapis.com`
79
+
80
+ The extension requests the `devstorage.read_write` OAuth scope and does not read
81
+ environment variables. If the application reads the service-account JSON from
82
+ an environment variable as in the example, grant that application-level read
83
+ separately.
84
+
85
+ Grant the service account object access plus `storage.buckets.get`. When an
86
+ object request returns `404`, Veryfront verifies that the bucket still exists
87
+ before returning `null` or `false`; a missing or inaccessible bucket remains a
88
+ provider error.
89
+
90
+ ## Verify the extension
91
+
92
+ From the Veryfront repository, run:
93
+
94
+ ```sh
95
+ deno task --cwd extensions/ext-blob-gcs test
96
+ ```
97
+
98
+ The test task needs no runtime permissions. It verifies JWT signing, token
99
+ coalescing, trusted resumable sessions, aligned range acknowledgements, bounded
100
+ responses, cancellation, and contract registration.
101
+
102
+ ## Migrate from core imports
103
+
104
+ Replace imports from `veryfront/workflow/blob`:
105
+
106
+ ```ts
107
+ // Before
108
+ import { GCSBlobStorage } from "veryfront/workflow/blob";
109
+
110
+ // After
111
+ import { GCSBlobStorage } from "@veryfront/ext-blob-gcs";
112
+ ```
113
+
114
+ Remove the former `projectId` option; it was not used to identify requests and
115
+ could imply quota or billing behavior that this storage contract does not own.
116
+ Prefer `extBlobGCS(config)` in application configuration. Direct class
117
+ construction remains available for low-level composition and tests.
@@ -0,0 +1,12 @@
1
+ declare global {
2
+ interface Object {
3
+ /**
4
+ * Determines whether an object has a property with the specified name.
5
+ * @param o An object.
6
+ * @param v A property name.
7
+ */
8
+ hasOwn(o: object, v: PropertyKey): boolean;
9
+ }
10
+ }
11
+ export {};
12
+ //# sourceMappingURL=_dnt.polyfills.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"_dnt.polyfills.d.ts","sourceRoot":"","sources":["../src/_dnt.polyfills.ts"],"names":[],"mappings":"AAeA,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QACd;;;;WAIG;QACH,MAAM,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC;KAC5C;CACF;AAED,OAAO,EAAE,CAAC"}
@@ -0,0 +1,15 @@
1
+ // https://github.com/tc39/proposal-accessible-object-hasownproperty/blob/main/polyfill.js
2
+ if (!Object.hasOwn) {
3
+ Object.defineProperty(Object, "hasOwn", {
4
+ value: function (object, property) {
5
+ if (object == null) {
6
+ throw new TypeError("Cannot convert undefined or null to object");
7
+ }
8
+ return Object.prototype.hasOwnProperty.call(Object(object), property);
9
+ },
10
+ configurable: true,
11
+ enumerable: false,
12
+ writable: true,
13
+ });
14
+ }
15
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Deno } from "@deno/shim-deno";
2
+ export { Deno } from "@deno/shim-deno";
3
+ export { crypto, type Crypto, type SubtleCrypto, type AlgorithmIdentifier, type Algorithm, type RsaOaepParams, type BufferSource, type AesCtrParams, type AesCbcParams, type AesGcmParams, type CryptoKey, type KeyAlgorithm, type KeyType, type KeyUsage, type EcdhKeyDeriveParams, type HkdfParams, type HashAlgorithmIdentifier, type Pbkdf2Params, type AesDerivedKeyParams, type HmacImportParams, type JsonWebKey, type RsaOtherPrimesInfo, type KeyFormat, type RsaHashedKeyGenParams, type RsaKeyGenParams, type BigInteger, type EcKeyGenParams, type NamedCurve, type CryptoKeyPair, type AesKeyGenParams, type HmacKeyGenParams, type RsaHashedImportParams, type EcKeyImportParams, type AesKeyAlgorithm, type RsaPssParams, type EcdsaParams } from "@deno/shim-crypto";
4
+ export { setInterval, setTimeout } from "@deno/shim-timers";
5
+ export declare const dntGlobalThis: Omit<typeof globalThis, "Deno" | "crypto" | "setInterval" | "setTimeout"> & {
6
+ Deno: typeof Deno;
7
+ crypto: import("@deno/shim-crypto").Crypto;
8
+ setInterval: any;
9
+ setTimeout: any;
10
+ };
11
+ //# sourceMappingURL=_dnt.shims.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"_dnt.shims.d.ts","sourceRoot":"","sources":["../src/_dnt.shims.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAEvC,OAAO,EAAE,MAAM,EAAE,KAAK,MAAM,EAAE,KAAK,YAAY,EAAE,KAAK,mBAAmB,EAAE,KAAK,SAAS,EAAE,KAAK,aAAa,EAAE,KAAK,YAAY,EAAE,KAAK,YAAY,EAAE,KAAK,YAAY,EAAE,KAAK,YAAY,EAAE,KAAK,SAAS,EAAE,KAAK,YAAY,EAAE,KAAK,OAAO,EAAE,KAAK,QAAQ,EAAE,KAAK,mBAAmB,EAAE,KAAK,UAAU,EAAE,KAAK,uBAAuB,EAAE,KAAK,YAAY,EAAE,KAAK,mBAAmB,EAAE,KAAK,gBAAgB,EAAE,KAAK,UAAU,EAAE,KAAK,kBAAkB,EAAE,KAAK,SAAS,EAAE,KAAK,qBAAqB,EAAE,KAAK,eAAe,EAAE,KAAK,UAAU,EAAE,KAAK,cAAc,EAAE,KAAK,UAAU,EAAE,KAAK,aAAa,EAAE,KAAK,eAAe,EAAE,KAAK,gBAAgB,EAAE,KAAK,qBAAqB,EAAE,KAAK,iBAAiB,EAAE,KAAK,eAAe,EAAE,KAAK,YAAY,EAAE,KAAK,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErvB,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAQ5D,eAAO,MAAM,aAAa;;;;;CAA2C,CAAC"}
@@ -0,0 +1,68 @@
1
+ import { Deno } from "@deno/shim-deno";
2
+ export { Deno } from "@deno/shim-deno";
3
+ import { crypto } from "@deno/shim-crypto";
4
+ export { crypto } from "@deno/shim-crypto";
5
+ import { setInterval, setTimeout } from "@deno/shim-timers";
6
+ export { setInterval, setTimeout } from "@deno/shim-timers";
7
+ const dntGlobals = {
8
+ Deno,
9
+ crypto,
10
+ setInterval,
11
+ setTimeout,
12
+ };
13
+ export const dntGlobalThis = createMergeProxy(globalThis, dntGlobals);
14
+ function createMergeProxy(baseObj, extObj) {
15
+ return new Proxy(baseObj, {
16
+ get(_target, prop, _receiver) {
17
+ if (prop in extObj) {
18
+ return extObj[prop];
19
+ }
20
+ else {
21
+ return baseObj[prop];
22
+ }
23
+ },
24
+ set(_target, prop, value) {
25
+ if (prop in extObj) {
26
+ delete extObj[prop];
27
+ }
28
+ baseObj[prop] = value;
29
+ return true;
30
+ },
31
+ deleteProperty(_target, prop) {
32
+ let success = false;
33
+ if (prop in extObj) {
34
+ delete extObj[prop];
35
+ success = true;
36
+ }
37
+ if (prop in baseObj) {
38
+ delete baseObj[prop];
39
+ success = true;
40
+ }
41
+ return success;
42
+ },
43
+ ownKeys(_target) {
44
+ const baseKeys = Reflect.ownKeys(baseObj);
45
+ const extKeys = Reflect.ownKeys(extObj);
46
+ const extKeysSet = new Set(extKeys);
47
+ return [...baseKeys.filter((k) => !extKeysSet.has(k)), ...extKeys];
48
+ },
49
+ defineProperty(_target, prop, desc) {
50
+ if (prop in extObj) {
51
+ delete extObj[prop];
52
+ }
53
+ Reflect.defineProperty(baseObj, prop, desc);
54
+ return true;
55
+ },
56
+ getOwnPropertyDescriptor(_target, prop) {
57
+ if (prop in extObj) {
58
+ return Reflect.getOwnPropertyDescriptor(extObj, prop);
59
+ }
60
+ else {
61
+ return Reflect.getOwnPropertyDescriptor(baseObj, prop);
62
+ }
63
+ },
64
+ has(_target, prop) {
65
+ return prop in extObj || prop in baseObj;
66
+ },
67
+ });
68
+ }
@@ -0,0 +1,41 @@
1
+ import { type BlobRef, type BlobStorage, type StoreBlobOptions } from "veryfront/workflow/blob";
2
+ /** Fetch-compatible transport used for OAuth and Cloud Storage requests. */
3
+ export type GCSFetch = (input: string | URL | Request, init?: RequestInit) => Promise<Response>;
4
+ /** Injectable transport and clock seams for deterministic tests. */
5
+ export interface GCSBlobStorageDependencies {
6
+ /** Fetch-compatible provider transport. */
7
+ fetch?: GCSFetch;
8
+ /** Millisecond Unix timestamp source. */
9
+ now?: () => number;
10
+ }
11
+ /** Explicit Google Cloud Storage connection and object-layout configuration. */
12
+ export interface GCSBlobStorageConfig {
13
+ /** GCS bucket name. */
14
+ bucket: string;
15
+ /** Google service-account JSON containing `private_key` and `client_email`. */
16
+ serviceAccountKey: string;
17
+ /** Object-key prefix applied verbatim before each blob id. */
18
+ prefix?: string;
19
+ /** Public base URL used only to populate `BlobRef.url`. */
20
+ baseUrl?: string;
21
+ /** Default TTL in seconds. Zero means no expiry. */
22
+ defaultTtl?: number;
23
+ /** Resumable stream chunk size; must be a 256 KiB multiple. Defaults to 8 MiB. */
24
+ resumableChunkSize?: number;
25
+ /** Cancellation signal applied to provider requests and returned streams. */
26
+ signal?: AbortSignal;
27
+ }
28
+ /** Google Cloud Storage implementation of the framework-owned contract. */
29
+ export declare class GCSBlobStorage implements BlobStorage {
30
+ #private;
31
+ constructor(config: GCSBlobStorageConfig, dependencies?: GCSBlobStorageDependencies);
32
+ close(): void;
33
+ put(data: string | Uint8Array | Blob | ReadableStream, options?: StoreBlobOptions): Promise<BlobRef>;
34
+ getStream(id: string): Promise<ReadableStream | null>;
35
+ getText(id: string): Promise<string | null>;
36
+ getBytes(id: string): Promise<Uint8Array | null>;
37
+ delete(id: string): Promise<void>;
38
+ exists(id: string): Promise<boolean>;
39
+ stat(id: string): Promise<BlobRef | null>;
40
+ }
41
+ //# sourceMappingURL=gcs-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gcs-storage.d.ts","sourceRoot":"","sources":["../src/gcs-storage.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,gBAAgB,EACtB,MAAM,yBAAyB,CAAC;AAsBjC,4EAA4E;AAC5E,MAAM,MAAM,QAAQ,GAAG,CACrB,KAAK,EAAE,MAAM,GAAG,GAAG,GAAG,OAAO,EAC7B,IAAI,CAAC,EAAE,WAAW,KACf,OAAO,CAAC,QAAQ,CAAC,CAAC;AAEvB,oEAAoE;AACpE,MAAM,WAAW,0BAA0B;IACzC,2CAA2C;IAC3C,KAAK,CAAC,EAAE,QAAQ,CAAC;IACjB,yCAAyC;IACzC,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;CACpB;AAED,gFAAgF;AAChF,MAAM,WAAW,oBAAoB;IACnC,uBAAuB;IACvB,MAAM,EAAE,MAAM,CAAC;IACf,+EAA+E;IAC/E,iBAAiB,EAAE,MAAM,CAAC;IAC1B,8DAA8D;IAC9D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,2DAA2D;IAC3D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,oDAAoD;IACpD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,kFAAkF;IAClF,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,6EAA6E;IAC7E,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB;AAykBD,2EAA2E;AAC3E,qBAAa,cAAe,YAAW,WAAW;;gBAWpC,MAAM,EAAE,oBAAoB,EAAE,YAAY,GAAE,0BAA+B;IAgBvF,KAAK,IAAI,IAAI;IAmJP,GAAG,CACP,IAAI,EAAE,MAAM,GAAG,UAAU,GAAG,IAAI,GAAG,cAAc,EACjD,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC,OAAO,CAAC;IA6Hb,SAAS,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,GAAG,IAAI,CAAC;IAiBrD,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;IAK3C,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,GAAG,IAAI,CAAC;IAMhD,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAYjC,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAcpC,IAAI,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,GAAG,IAAI,CAAC;CAiChD"}