@superdurable/connector-dropbox 0.0.0-stage → 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 +6 -2
- package/dex-connector.json +291 -0
- package/dist/chunk-OVLMU3VN.js +552 -0
- package/dist/connection-DDFkY9tu.d.ts +196 -0
- package/dist/index.d.ts +340 -0
- package/dist/index.js +678 -0
- package/dist/mock.d.ts +117 -0
- package/dist/mock.js +104 -0
- package/package.json +62 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Super Durable
|
|
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
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Dropbox connector for TypeScript
|
|
2
2
|
|
|
3
|
-
This
|
|
3
|
+
This package implements `listFolder`, `getMetadata`, `continueFolder`, `downloadFile`, and `uploadFile` with the Go-verified request and branch contracts. See the [connector README](../README.md) for Dropbox OAuth setup, scopes, and response limits.
|
|
4
|
+
|
|
5
|
+
Use `newProjectConnection(project, "dropbox")` with operation-specific Step factories. The [metadata Flow](examples/file-lookup/README.md) shows a runnable Dex Worker. `downloadFile` returns bounded Base64 content. `uploadFile` accepts Base64 content, overwrites one path with the same bytes on retry, and returns only the provider file identity.
|
|
6
|
+
|
|
7
|
+
From the repository root, run `npm ci --prefix connectors/dropbox/typescript` and `npm run check --prefix connectors/dropbox/typescript`. The conformance test replays `conformance/connectors/dropbox/scenarios.json`; live Dropbox authorization remains unverified.
|
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
{
|
|
2
|
+
"connectorId": "dropbox",
|
|
3
|
+
"releaseTag": "connectors/dropbox/go/v0.1.0",
|
|
4
|
+
"package": {
|
|
5
|
+
"ecosystem": "npm",
|
|
6
|
+
"name": "@superdurable/connector-dropbox",
|
|
7
|
+
"version": "0.1.0"
|
|
8
|
+
},
|
|
9
|
+
"factories": [
|
|
10
|
+
{
|
|
11
|
+
"name": "newListFolderStep",
|
|
12
|
+
"kind": "query",
|
|
13
|
+
"operationId": "listFolder",
|
|
14
|
+
"inputType": "ListFolderInput",
|
|
15
|
+
"description": "List one bounded page of files and folders in a Dropbox folder.",
|
|
16
|
+
"fields": {
|
|
17
|
+
"stepType": "stepType",
|
|
18
|
+
"annotations": "annotations",
|
|
19
|
+
"connectionName": "connectionName",
|
|
20
|
+
"resultAttribute": "resultAttribute"
|
|
21
|
+
},
|
|
22
|
+
"branches": [
|
|
23
|
+
{
|
|
24
|
+
"id": "listed",
|
|
25
|
+
"field": "listed",
|
|
26
|
+
"optional": false
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"id": "notFound",
|
|
30
|
+
"field": "notFound",
|
|
31
|
+
"optional": true
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"id": "providerRejected",
|
|
35
|
+
"field": "providerRejected",
|
|
36
|
+
"optional": true
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"id": "invalidResponse",
|
|
40
|
+
"field": "invalidResponse",
|
|
41
|
+
"optional": true
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"id": "defect",
|
|
45
|
+
"field": "defect",
|
|
46
|
+
"optional": true
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"inputSchema": {
|
|
50
|
+
"additionalProperties": false,
|
|
51
|
+
"description": "ListFolderInput selects one bounded page of a Dropbox folder.",
|
|
52
|
+
"properties": {
|
|
53
|
+
"limit": {
|
|
54
|
+
"description": "Limit is the approximate number of entries per page, from 1 to 2000.",
|
|
55
|
+
"type": "integer"
|
|
56
|
+
},
|
|
57
|
+
"path": {
|
|
58
|
+
"description": "Path is an empty string for the root or a Dropbox folder path or ID.",
|
|
59
|
+
"type": "string"
|
|
60
|
+
}
|
|
61
|
+
},
|
|
62
|
+
"required": [
|
|
63
|
+
"limit",
|
|
64
|
+
"path"
|
|
65
|
+
],
|
|
66
|
+
"type": "object"
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"name": "newGetMetadataStep",
|
|
71
|
+
"kind": "query",
|
|
72
|
+
"operationId": "getMetadata",
|
|
73
|
+
"inputType": "GetMetadataInput",
|
|
74
|
+
"description": "Read a Dropbox file or folder's stable ID, display path, and kind.",
|
|
75
|
+
"fields": {
|
|
76
|
+
"stepType": "stepType",
|
|
77
|
+
"annotations": "annotations",
|
|
78
|
+
"connectionName": "connectionName",
|
|
79
|
+
"resultAttribute": "resultAttribute"
|
|
80
|
+
},
|
|
81
|
+
"branches": [
|
|
82
|
+
{
|
|
83
|
+
"id": "found",
|
|
84
|
+
"field": "found",
|
|
85
|
+
"optional": false
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"id": "notFound",
|
|
89
|
+
"field": "notFound",
|
|
90
|
+
"optional": true
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
"id": "providerRejected",
|
|
94
|
+
"field": "providerRejected",
|
|
95
|
+
"optional": true
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"id": "invalidResponse",
|
|
99
|
+
"field": "invalidResponse",
|
|
100
|
+
"optional": true
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
"id": "defect",
|
|
104
|
+
"field": "defect",
|
|
105
|
+
"optional": true
|
|
106
|
+
}
|
|
107
|
+
],
|
|
108
|
+
"inputSchema": {
|
|
109
|
+
"additionalProperties": false,
|
|
110
|
+
"description": "GetMetadataInput selects one Dropbox file or folder.",
|
|
111
|
+
"properties": {
|
|
112
|
+
"path": {
|
|
113
|
+
"description": "Path is an absolute Dropbox path or a stable id: or rev: identifier.",
|
|
114
|
+
"type": "string"
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"required": [
|
|
118
|
+
"path"
|
|
119
|
+
],
|
|
120
|
+
"type": "object"
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"name": "newContinueFolderStep",
|
|
125
|
+
"kind": "query",
|
|
126
|
+
"operationId": "continueFolder",
|
|
127
|
+
"inputType": "ContinueFolderInput",
|
|
128
|
+
"description": "Continue one Dropbox folder page or read later changes from its cursor.",
|
|
129
|
+
"fields": {
|
|
130
|
+
"stepType": "stepType",
|
|
131
|
+
"annotations": "annotations",
|
|
132
|
+
"connectionName": "connectionName",
|
|
133
|
+
"resultAttribute": "resultAttribute"
|
|
134
|
+
},
|
|
135
|
+
"branches": [
|
|
136
|
+
{
|
|
137
|
+
"id": "listed",
|
|
138
|
+
"field": "listed",
|
|
139
|
+
"optional": false
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"id": "cursorExpired",
|
|
143
|
+
"field": "cursorExpired",
|
|
144
|
+
"optional": true
|
|
145
|
+
},
|
|
146
|
+
{
|
|
147
|
+
"id": "providerRejected",
|
|
148
|
+
"field": "providerRejected",
|
|
149
|
+
"optional": true
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
"id": "invalidResponse",
|
|
153
|
+
"field": "invalidResponse",
|
|
154
|
+
"optional": true
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
"id": "defect",
|
|
158
|
+
"field": "defect",
|
|
159
|
+
"optional": true
|
|
160
|
+
}
|
|
161
|
+
],
|
|
162
|
+
"inputSchema": {
|
|
163
|
+
"additionalProperties": false,
|
|
164
|
+
"description": "ContinueFolderInput selects the page or changes after a Dropbox cursor.",
|
|
165
|
+
"properties": {
|
|
166
|
+
"cursor": {
|
|
167
|
+
"description": "Cursor is returned by a previous folder listing or continuation.",
|
|
168
|
+
"type": "string"
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
"required": [
|
|
172
|
+
"cursor"
|
|
173
|
+
],
|
|
174
|
+
"type": "object"
|
|
175
|
+
}
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
"name": "newDownloadFileStep",
|
|
179
|
+
"kind": "query",
|
|
180
|
+
"operationId": "downloadFile",
|
|
181
|
+
"inputType": "DownloadFileInput",
|
|
182
|
+
"description": "Download a bounded Dropbox file and return Base64 content with its file identity.",
|
|
183
|
+
"fields": {
|
|
184
|
+
"stepType": "stepType",
|
|
185
|
+
"annotations": "annotations",
|
|
186
|
+
"connectionName": "connectionName",
|
|
187
|
+
"resultAttribute": "resultAttribute"
|
|
188
|
+
},
|
|
189
|
+
"branches": [
|
|
190
|
+
{
|
|
191
|
+
"id": "downloaded",
|
|
192
|
+
"field": "downloaded",
|
|
193
|
+
"optional": false
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"id": "notFound",
|
|
197
|
+
"field": "notFound",
|
|
198
|
+
"optional": true
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
"id": "tooLarge",
|
|
202
|
+
"field": "tooLarge",
|
|
203
|
+
"optional": true
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"id": "providerRejected",
|
|
207
|
+
"field": "providerRejected",
|
|
208
|
+
"optional": true
|
|
209
|
+
},
|
|
210
|
+
{
|
|
211
|
+
"id": "invalidResponse",
|
|
212
|
+
"field": "invalidResponse",
|
|
213
|
+
"optional": true
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
"id": "defect",
|
|
217
|
+
"field": "defect",
|
|
218
|
+
"optional": true
|
|
219
|
+
}
|
|
220
|
+
],
|
|
221
|
+
"inputSchema": {
|
|
222
|
+
"additionalProperties": false,
|
|
223
|
+
"description": "DownloadFileInput selects one Dropbox file by path, ID, or revision.",
|
|
224
|
+
"properties": {
|
|
225
|
+
"path": {
|
|
226
|
+
"description": "Path is an absolute Dropbox path or a stable id: or rev: identifier.",
|
|
227
|
+
"type": "string"
|
|
228
|
+
}
|
|
229
|
+
},
|
|
230
|
+
"required": [
|
|
231
|
+
"path"
|
|
232
|
+
],
|
|
233
|
+
"type": "object"
|
|
234
|
+
}
|
|
235
|
+
},
|
|
236
|
+
{
|
|
237
|
+
"name": "newUploadFileStep",
|
|
238
|
+
"kind": "mutation",
|
|
239
|
+
"operationId": "uploadFile",
|
|
240
|
+
"inputType": "UploadFileInput",
|
|
241
|
+
"description": "Overwrite one Dropbox path with bounded Base64-decoded content.",
|
|
242
|
+
"fields": {
|
|
243
|
+
"stepType": "stepType",
|
|
244
|
+
"annotations": "annotations",
|
|
245
|
+
"connectionName": "connectionName",
|
|
246
|
+
"resultAttribute": "resultAttribute"
|
|
247
|
+
},
|
|
248
|
+
"branches": [
|
|
249
|
+
{
|
|
250
|
+
"id": "uploaded",
|
|
251
|
+
"field": "uploaded",
|
|
252
|
+
"optional": false
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
"id": "providerRejected",
|
|
256
|
+
"field": "providerRejected",
|
|
257
|
+
"optional": true
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
"id": "invalidResponse",
|
|
261
|
+
"field": "invalidResponse",
|
|
262
|
+
"optional": true
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
"id": "defect",
|
|
266
|
+
"field": "defect",
|
|
267
|
+
"optional": true
|
|
268
|
+
}
|
|
269
|
+
],
|
|
270
|
+
"inputSchema": {
|
|
271
|
+
"additionalProperties": false,
|
|
272
|
+
"description": "UploadFileInput replaces one Dropbox path with Base64-decoded content.",
|
|
273
|
+
"properties": {
|
|
274
|
+
"contentBase64": {
|
|
275
|
+
"description": "ContentBase64 contains the complete replacement file content.",
|
|
276
|
+
"type": "string"
|
|
277
|
+
},
|
|
278
|
+
"path": {
|
|
279
|
+
"description": "Path is the absolute destination path, including the file name.",
|
|
280
|
+
"type": "string"
|
|
281
|
+
}
|
|
282
|
+
},
|
|
283
|
+
"required": [
|
|
284
|
+
"contentBase64",
|
|
285
|
+
"path"
|
|
286
|
+
],
|
|
287
|
+
"type": "object"
|
|
288
|
+
}
|
|
289
|
+
}
|
|
290
|
+
]
|
|
291
|
+
}
|