@assemblyline-agents/r2 0.1.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/LICENSE +21 -0
- package/README.md +19 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +23 -0
- package/dist/index.js.map +1 -0
- package/package.json +50 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 OpenEve contributors
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# @assemblyline-agents/r2
|
|
2
|
+
|
|
3
|
+
Official Assembly Line Cloudflare R2 blob-storage plugin.
|
|
4
|
+
|
|
5
|
+
A thin provider wrapper over `@assemblyline-agents/s3` that configures the S3-compatible blob adapter for Cloudflare R2 endpoints and credentials, giving agents durable blob storage (attachments and other binary artifacts) backed by R2.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
npm install @assemblyline-agents/r2
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Part of Assembly Line
|
|
14
|
+
|
|
15
|
+
This package is part of [Assembly Line](https://github.com/jasonbadeaux/openeve), a vendor-neutral, filesystem-first framework for durable AI agents. See the developer documentation in [docs/developers/](https://github.com/jasonbadeaux/openeve/tree/main/docs/developers) for setup, agent authoring, and deployment guides.
|
|
16
|
+
|
|
17
|
+
## License
|
|
18
|
+
|
|
19
|
+
MIT
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type JsonObject, type ProviderModule } from "@assemblyline-agents/core";
|
|
2
|
+
import { InMemoryS3ObjectStore, R2_BLOB_PROVIDER_METADATA, S3BlobAdapter, createR2BlobAdapterFromEnv, createR2ObjectStoreFromEnv, type R2Adapter, type S3Environment, type S3ObjectStoreLike } from "@assemblyline-agents/s3";
|
|
3
|
+
export type { R2Adapter, S3Environment as R2Environment, S3ObjectStoreLike as R2BucketLike };
|
|
4
|
+
export declare function r2Adapter(options?: JsonObject): R2Adapter;
|
|
5
|
+
export declare class R2BlobAdapter extends S3BlobAdapter {
|
|
6
|
+
constructor(bucket: S3ObjectStoreLike, options?: {
|
|
7
|
+
prefix?: string;
|
|
8
|
+
publicBaseUrl?: string;
|
|
9
|
+
uriScheme?: string;
|
|
10
|
+
});
|
|
11
|
+
}
|
|
12
|
+
export declare class InMemoryR2Bucket extends InMemoryS3ObjectStore {
|
|
13
|
+
}
|
|
14
|
+
export { createR2BlobAdapterFromEnv, createR2ObjectStoreFromEnv, R2_BLOB_PROVIDER_METADATA };
|
|
15
|
+
export declare const openeveProvider: ProviderModule;
|
|
16
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,cAAc,EAAE,MAAM,2BAA2B,CAAC;AACjF,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,aAAa,EACb,0BAA0B,EAC1B,0BAA0B,EAE1B,KAAK,SAAS,EACd,KAAK,aAAa,EAClB,KAAK,iBAAiB,EACvB,MAAM,yBAAyB,CAAC;AAEjC,YAAY,EAAE,SAAS,EAAE,aAAa,IAAI,aAAa,EAAE,iBAAiB,IAAI,YAAY,EAAE,CAAC;AAE7F,wBAAgB,SAAS,CAAC,OAAO,GAAE,UAAe,GAAG,SAAS,CAE7D;AAED,qBAAa,aAAc,SAAQ,aAAa;gBAClC,MAAM,EAAE,iBAAiB,EAAE,OAAO,GAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,aAAa,CAAC,EAAE,MAAM,CAAC;QAAC,SAAS,CAAC,EAAE,MAAM,CAAA;KAAO;CAGrH;AAED,qBAAa,gBAAiB,SAAQ,qBAAqB;CAAG;AAE9D,OAAO,EAAE,0BAA0B,EAAE,0BAA0B,EAAE,yBAAyB,EAAE,CAAC;AAE7F,eAAO,MAAM,eAAe,EAAE,cAS7B,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { InMemoryS3ObjectStore, R2_BLOB_PROVIDER_METADATA, S3BlobAdapter, createR2BlobAdapterFromEnv, createR2ObjectStoreFromEnv, r2Blob } from "@assemblyline-agents/s3";
|
|
2
|
+
export function r2Adapter(options = {}) {
|
|
3
|
+
return r2Blob(options);
|
|
4
|
+
}
|
|
5
|
+
export class R2BlobAdapter extends S3BlobAdapter {
|
|
6
|
+
constructor(bucket, options = {}) {
|
|
7
|
+
super(bucket, { ...options, uriScheme: "r2" });
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export class InMemoryR2Bucket extends InMemoryS3ObjectStore {
|
|
11
|
+
}
|
|
12
|
+
export { createR2BlobAdapterFromEnv, createR2ObjectStoreFromEnv, R2_BLOB_PROVIDER_METADATA };
|
|
13
|
+
export const openeveProvider = {
|
|
14
|
+
providers: [
|
|
15
|
+
{
|
|
16
|
+
metadata: R2_BLOB_PROVIDER_METADATA,
|
|
17
|
+
create(ctx) {
|
|
18
|
+
return createR2BlobAdapterFromEnv(ctx.env, ctx.fetch);
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
]
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,aAAa,EACb,0BAA0B,EAC1B,0BAA0B,EAC1B,MAAM,EAIP,MAAM,yBAAyB,CAAC;AAIjC,MAAM,UAAU,SAAS,CAAC,UAAsB,EAAE;IAChD,OAAO,MAAM,CAAC,OAAO,CAAC,CAAC;AACzB,CAAC;AAED,MAAM,OAAO,aAAc,SAAQ,aAAa;IAC9C,YAAY,MAAyB,EAAE,UAA2E,EAAE;QAClH,KAAK,CAAC,MAAM,EAAE,EAAE,GAAG,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IACjD,CAAC;CACF;AAED,MAAM,OAAO,gBAAiB,SAAQ,qBAAqB;CAAG;AAE9D,OAAO,EAAE,0BAA0B,EAAE,0BAA0B,EAAE,yBAAyB,EAAE,CAAC;AAE7F,MAAM,CAAC,MAAM,eAAe,GAAmB;IAC7C,SAAS,EAAE;QACT;YACE,QAAQ,EAAE,yBAAyB;YACnC,MAAM,CAAC,GAAG;gBACR,OAAO,0BAA0B,CAAC,GAAG,CAAC,GAAG,EAAE,GAAG,CAAC,KAAK,CAAC,CAAC;YACxD,CAAC;SACF;KACF;CACF,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@assemblyline-agents/r2",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"exports": {
|
|
6
|
+
".": {
|
|
7
|
+
"types": "./dist/index.d.ts",
|
|
8
|
+
"default": "./dist/index.js"
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@assemblyline-agents/core": "0.1.0",
|
|
13
|
+
"@assemblyline-agents/runtime": "0.1.0",
|
|
14
|
+
"@assemblyline-agents/s3": "0.1.0"
|
|
15
|
+
},
|
|
16
|
+
"description": "Official OpenEve Cloudflare R2 blob-storage plugin.",
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
20
|
+
"engines": {
|
|
21
|
+
"node": ">=22.19.0"
|
|
22
|
+
},
|
|
23
|
+
"license": "MIT",
|
|
24
|
+
"repository": {
|
|
25
|
+
"type": "git",
|
|
26
|
+
"url": "git+https://github.com/jasonbadeaux/openeve.git",
|
|
27
|
+
"directory": "packages/r2"
|
|
28
|
+
},
|
|
29
|
+
"bugs": {
|
|
30
|
+
"url": "https://github.com/jasonbadeaux/openeve/issues"
|
|
31
|
+
},
|
|
32
|
+
"homepage": "https://github.com/jasonbadeaux/openeve#readme",
|
|
33
|
+
"author": "OpenEve contributors",
|
|
34
|
+
"keywords": [
|
|
35
|
+
"openeve",
|
|
36
|
+
"ai",
|
|
37
|
+
"agents",
|
|
38
|
+
"cloudflare",
|
|
39
|
+
"r2",
|
|
40
|
+
"blob-storage",
|
|
41
|
+
"plugin"
|
|
42
|
+
],
|
|
43
|
+
"publishConfig": {
|
|
44
|
+
"access": "public"
|
|
45
|
+
},
|
|
46
|
+
"scripts": {
|
|
47
|
+
"build": "tsc -p tsconfig.json",
|
|
48
|
+
"check": "tsc -p tsconfig.json --noEmit"
|
|
49
|
+
}
|
|
50
|
+
}
|