@distilled.cloud/turso 1.0.0-rc.17 → 1.0.0-rc.19
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/lib/_bundle/sdk.js +1 -1
- package/lib/_bundle/sdk.js.map +1 -1
- package/lib/credentials.d.ts +10 -1
- package/lib/credentials.d.ts.map +1 -1
- package/lib/index.d.ts +3 -3
- package/lib/protocol.d.ts +3 -2
- package/lib/protocol.d.ts.map +1 -1
- package/lib/services/turso.d.ts +271 -271
- package/lib/services/turso.d.ts.map +1 -1
- package/lib/services/turso.js +80 -79
- package/lib/services/turso.js.map +1 -1
- package/lib/services.lazy/turso.js +1 -1
- package/package.json +6 -5
- package/src/credentials.ts +3 -2
- package/src/index.ts +3 -3
- package/src/protocol.ts +8 -2
- package/src/services/turso.ts +395 -270
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@distilled.cloud/turso",
|
|
3
|
-
"version": "1.0.0-rc.
|
|
3
|
+
"version": "1.0.0-rc.19",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -68,17 +68,18 @@
|
|
|
68
68
|
}
|
|
69
69
|
},
|
|
70
70
|
"dependencies": {
|
|
71
|
-
"@distilled.cloud/core": "1.0.0-rc.
|
|
71
|
+
"@distilled.cloud/core": "1.0.0-rc.19"
|
|
72
72
|
},
|
|
73
73
|
"devDependencies": {
|
|
74
|
+
"@distilled.cloud/dev": "0.0.0",
|
|
74
75
|
"@types/node": "26.6.5"
|
|
75
76
|
},
|
|
76
77
|
"peerDependencies": {
|
|
77
|
-
"effect": "^4.
|
|
78
|
+
"effect": "^4.1.2"
|
|
78
79
|
},
|
|
79
80
|
"distilled": {
|
|
80
|
-
"generatedAt": "2026-10
|
|
81
|
-
"specUpdatedAt": "2026-
|
|
81
|
+
"generatedAt": "2026-11-10",
|
|
82
|
+
"specUpdatedAt": "2026-10-28"
|
|
82
83
|
},
|
|
83
84
|
"scripts": {
|
|
84
85
|
"build": "tsrs -b",
|
package/src/credentials.ts
CHANGED
|
@@ -21,7 +21,9 @@ export interface Config {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
export class Credentials
|
|
24
|
-
extends /*@__PURE__*/ Context.Service<Credentials, Effect.Effect<Config>>()(
|
|
24
|
+
extends /*@__PURE__*/ Context.Service<Credentials, Effect.Effect<Config, ConfigError>>()(
|
|
25
|
+
"TursoCredentials",
|
|
26
|
+
) {}
|
|
25
27
|
|
|
26
28
|
const envConfig = /*@__PURE__*/ EffectConfig.all({
|
|
27
29
|
apiKey: /*@__PURE__*/ EffectConfig.String("TURSO_API_KEY"),
|
|
@@ -40,6 +42,5 @@ export const CredentialsFromEnv = /*@__PURE__*/ Layer.succeed(
|
|
|
40
42
|
apiKey: Redacted.make(apiKey),
|
|
41
43
|
apiBaseUrl: DEFAULT_API_BASE_URL,
|
|
42
44
|
})),
|
|
43
|
-
Effect.orDie,
|
|
44
45
|
),
|
|
45
46
|
);
|
package/src/index.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @distilled.cloud/turso -- Turso SDK for Effect.
|
|
3
3
|
*
|
|
4
|
-
* `./services` is generated by `scripts/generate.ts` from the Smithy model
|
|
5
|
-
*
|
|
6
|
-
*
|
|
4
|
+
* `./services` is generated by `scripts/generate.ts` from the Smithy model that
|
|
5
|
+
* `scripts/convert.ts` converts from the Turso OpenAPI spec. Everything else in
|
|
6
|
+
* this folder is hand-written.
|
|
7
7
|
*
|
|
8
8
|
* @example
|
|
9
9
|
* ```ts
|
package/src/protocol.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type * as API from "@distilled.cloud/core/api";
|
|
2
|
-
import type { ConfigError } from "@distilled.cloud/core/errors";
|
|
2
|
+
import type { ConfigError, InvalidInput } from "@distilled.cloud/core/errors";
|
|
3
3
|
import { makeRestProtocol } from "@distilled.cloud/core/protocol-rest";
|
|
4
|
+
import type { SdkError } from "@distilled.cloud/core/sdk-error";
|
|
4
5
|
/**
|
|
5
6
|
* TursoProtocol -- hand-written.
|
|
6
7
|
*
|
|
@@ -31,7 +32,12 @@ import { UnknownTursoError, type DefaultErrors, TursoParseError } from "./errors
|
|
|
31
32
|
* TursoOpContext>` explicitly so the compiler never infers these back out of
|
|
32
33
|
* the schema generics.
|
|
33
34
|
*/
|
|
34
|
-
export type TursoOpError =
|
|
35
|
+
export type TursoOpError =
|
|
36
|
+
| DefaultErrors
|
|
37
|
+
| ConfigError
|
|
38
|
+
| HttpClientError.HttpClientError
|
|
39
|
+
| InvalidInput
|
|
40
|
+
| SdkError;
|
|
35
41
|
|
|
36
42
|
/** Context (requirements) shared by every generated Turso operation. */
|
|
37
43
|
export type TursoOpContext = Credentials | HttpClient.HttpClient;
|