@distilled.cloud/temporal 1.0.0-rc.20 → 1.0.0-rc.21
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/README.md +0 -1
- package/lib/_bundle/sdk.js +1 -1
- package/lib/_bundle/sdk.js.map +1 -1
- package/lib/credentials.d.ts +9 -4
- package/lib/credentials.d.ts.map +1 -1
- package/lib/errors.d.ts +7 -0
- package/lib/errors.d.ts.map +1 -1
- package/lib/errors.js +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.lazy.js.map +1 -1
- package/lib/pagination.d.ts.map +1 -1
- package/lib/protocol.d.ts +9 -12
- package/lib/protocol.d.ts.map +1 -1
- package/lib/retry.d.ts.map +1 -1
- package/lib/services/index.d.ts.map +1 -1
- package/lib/services/temporal.d.ts +8 -7
- package/lib/services/temporal.d.ts.map +1 -1
- package/lib/services/temporal.js +176 -176
- package/lib/services/temporal.js.map +1 -1
- package/lib/services.lazy/temporal.js +1 -1
- package/lib/traits.d.ts.map +1 -1
- package/package.json +5 -5
- package/src/credentials.ts +24 -16
- package/src/errors.ts +9 -1
- package/src/protocol.ts +13 -23
- package/src/services/temporal.ts +224 -119
package/README.md
CHANGED
package/lib/_bundle/sdk.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{errors$API_ERRORS as e,errors$BadGateway as t,errors$BadRequest as n,errors$ConfigError as r,errors$Conflict as i,errors$DEFAULT_ERRORS as a,errors$Forbidden as
|
|
1
|
+
import{errors$API_ERRORS as e,errors$BadGateway as t,errors$BadRequest as n,errors$ConfigError as r,errors$Conflict as i,errors$DEFAULT_ERRORS as a,errors$Forbidden as o,errors$GatewayTimeout as s,errors$HTTP_STATUS_MAP as ee,errors$InternalServerError as te,errors$Locked as ne,errors$NotFound as re,errors$ServiceUnavailable as c,errors$TooManyRequests as l,errors$Unauthorized as u,errors$UnknownErrorFields as d,errors$UnprocessableEntity as f,protocol_rest$RawResponse as p,protocol_rest$RawResponseRoot as m,protocol_rest$SensitiveValue as h,protocol_rest$rawResponseRootSymbol as g,protocol_rest$rawResponseSymbol as _,protocol_rest$restProtocol as v,protocol_rest$sensitiveValueSymbol as y,protocol_rest$unknownErrorProps as b,schema_lite$Array as x,schema_lite$Boolean as S,schema_lite$Number as C,schema_lite$Record as w,schema_lite$String as T,schema_lite$Struct as E,schema_lite$StructWithRest as D,schema_lite$Unknown as O,schema_lite$at as k,schema_lite$optional as A,schema_lite$suspend as j}from"@distilled.cloud/core/_bundle/rest";import{api$D as M,api$call as N,api$named as P,api$op as F,category$withParseError as I,retry$capped as L,retry$jittered as R,retry$makeDefault as z,retry$throttlingFactory as B,retry$throttlingOptions as V,retry$transientFactory as H,retry$transientOptions as U,schema_lite_typed$TaggedError as W,schema_lite_typed$Unknown as G,trait$Body as K,trait$FormDataFile as q,trait$Header as ie,trait$Http as J,trait$HttpBody as Y,trait$KeyDictionary as ae,trait$Label as oe,trait$Query as se,trait$ResponseCode as ce,trait$UnionCases as le,trait$applyErrorMatchers as ue,trait$bodySymbol as de,trait$errorMatchersSymbol as fe,trait$formDataFileSymbol as pe,trait$getErrorMatchers as me,trait$headerSymbol as he,trait$httpBodySymbol as ge,trait$httpSymbol as _e,trait$keyDictionarySymbol as ve,trait$labelSymbol as ye,trait$querySymbol as be,trait$responseCodeSymbol as xe,trait$unionCasesSymbol as Se}from"@distilled.cloud/core/_bundle/base";import*as X from"effect/Context";import*as Z from"effect/Effect";import*as Q from"effect/Layer";import*as $ from"effect/Redacted";const Ce=`http://localhost:7243`;var Credentials=class extends (/*@__PURE__*/ X.Service()(`TemporalCredentials`)){};const fromApiKey=e=>Q.succeed(Credentials,Z.succeed({apiKey:e.apiKey,apiBaseUrl:e.apiBaseUrl??`http://localhost:7243`}));const we=/*@__PURE__*/ Q.effect(Credentials,/*@__PURE__*/ Z.map(/*@__PURE__*/ Z.gen(function*(){const e=process.env.TEMPORAL_API_KEY;if(!e)return yield*new r({message:`TEMPORAL_API_KEY environment variable is required`});return{apiKey:$.make(e),apiBaseUrl:process.env.TEMPORAL_API_BASE_URL??`http://localhost:7243`}}),e=>Z.succeed(e)));var UnknownTemporalError=class extends (/*@__PURE__*/ W()(`UnknownTemporalError`,d)){};var TemporalParseError=class extends (/*@__PURE__*/ W()(`TemporalParseError`,{body:G,cause:G}).pipe(I)){};const Te=e;const Ee=/*@__PURE__*/ v({credentials:/*@__PURE__*/ Z.flatten(Credentials),baseUrl:e=>e.apiBaseUrl,headers:e=>({Authorization:`Bearer ${$.value(e.apiKey)}`}),unknownError:e=>new UnknownTemporalError(b(e)),parseError:({body:e,cause:t})=>new TemporalParseError({body:e,cause:t})});var Retry=class extends (/*@__PURE__*/ X.Service()(`TemporalRetry`)){};const policy=e=>Z.provide(Q.succeed(Retry,e));const De=/*@__PURE__*/ Z.provide(/*@__PURE__*/ Q.succeed(Retry,{while:()=>false}));const Oe=/*@__PURE__*/ policy(B);const ke=/*@__PURE__*/ policy(H);export{x as Zb,S as _b,M as a,N as b,Credentials as credentials$Credentials,we as credentials$CredentialsFromEnv,Ce as credentials$DEFAULT_API_BASE_URL,fromApiKey as credentials$fromApiKey,e as errors$API_ERRORS,t as errors$BadGateway,n as errors$BadRequest,r as errors$ConfigError,i as errors$Conflict,a as errors$DEFAULT_ERRORS,o as errors$Forbidden,s as errors$GatewayTimeout,ee as errors$HTTP_STATUS_MAP,te as errors$InternalServerError,ne as errors$Locked,re as errors$NotFound,c as errors$ServiceUnavailable,TemporalParseError as errors$TemporalParseError,Te as errors$TemporalServiceErrors,l as errors$TooManyRequests,u as errors$Unauthorized,UnknownTemporalError as errors$UnknownTemporalError,f as errors$UnprocessableEntity,C as ic,w as jc,P as l,T as lc,E as mc,F as n,D as nc,Ee as protocol$TemporalProtocol,O as rc,Retry as retry$Retry,L as retry$capped,R as retry$jittered,z as retry$makeDefault,De as retry$none,policy as retry$policy,Oe as retry$throttling,B as retry$throttlingFactory,V as retry$throttlingOptions,ke as retry$transient,H as retry$transientFactory,U as retry$transientOptions,k as tc,K as traits$Body,q as traits$FormDataFile,ie as traits$Header,J as traits$Http,Y as traits$HttpBody,ae as traits$KeyDictionary,oe as traits$Label,se as traits$Query,p as traits$RawResponse,m as traits$RawResponseRoot,ce as traits$ResponseCode,h as traits$SensitiveValue,le as traits$UnionCases,ue as traits$applyErrorMatchers,de as traits$bodySymbol,fe as traits$errorMatchersSymbol,pe as traits$formDataFileSymbol,me as traits$getErrorMatchers,he as traits$headerSymbol,ge as traits$httpBodySymbol,_e as traits$httpSymbol,ve as traits$keyDictionarySymbol,ye as traits$labelSymbol,be as traits$querySymbol,g as traits$rawResponseRootSymbol,_ as traits$rawResponseSymbol,xe as traits$responseCodeSymbol,y as traits$sensitiveValueSymbol,Se as traits$unionCasesSymbol,A as yc,j as zc};
|
|
2
2
|
//# sourceMappingURL=sdk.js.map
|
package/lib/_bundle/sdk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.js","names":["Schema.Unknown","Category.withParseError","API_ERRORS","BadGateway","BadRequest","ConfigError","Conflict","DEFAULT_ERRORS","Forbidden","GatewayTimeout","HTTP_STATUS_MAP","InternalServerError","Locked","NotFound","ServiceUnavailable","TooManyRequests","Unauthorized","UnknownErrorFields","UnprocessableEntity","RawResponse","RawResponseRoot","SensitiveValue","
|
|
1
|
+
{"version":3,"file":"sdk.js","names":["Schema.Unknown","Category.withParseError","API_ERRORS","BadGateway","BadRequest","ConfigError","Conflict","DEFAULT_ERRORS","Forbidden","GatewayTimeout","HTTP_STATUS_MAP","InternalServerError","Locked","NotFound","ServiceUnavailable","TooManyRequests","Unauthorized","UnknownErrorFields","UnprocessableEntity","RawResponse","RawResponseRoot","SensitiveValue","rawResponseRootSymbol","rawResponseSymbol","restProtocol","sensitiveValueSymbol","unknownErrorProps","Array","Boolean","Number","Record","String","Struct","StructWithRest","Unknown","at","optional","suspend","D","call","named","op","withParseError","capped","jittered","makeDefault","throttlingFactory","throttlingOptions","transientFactory","transientOptions","TaggedError$1","Unknown$1","Body","FormDataFile","Header","Http","HttpBody","KeyDictionary","Label","Query","ResponseCode","UnionCases","applyErrorMatchers","bodySymbol","errorMatchersSymbol","formDataFileSymbol","getErrorMatchers","headerSymbol","httpBodySymbol","httpSymbol","keyDictionarySymbol","labelSymbol","querySymbol","responseCodeSymbol","unionCasesSymbol","Context","Effect","Layer","Redacted","DEFAULT_API_BASE_URL","config","CredentialsFromEnv","apiKey","TemporalServiceErrors","TemporalProtocol","creds","info","optionsOrFactory","none","throttling","transient"],"sources":["../../src/credentials.ts","../../src/errors.ts","../../src/protocol.ts","../../src/retry.ts"],"mappings":"kkEAoBA,MAAa+E,GAAuB,wBAOpC,IAAa,YAAb,eACwB,gBAAQ,QAA4C,CAAC,CACzE,qBACF,EAAA,AAAE,CAAC,EAGL,MAAa,WAAc,GAIzBF,EAAM,QACJ,YACAD,EAAO,QAAQ,CACb,OAAQI,EAAO,OACf,WAAYA,EAAO,YAAA,uBACrB,CAAC,CACH,EAQF,MAAaC,GAA0E,gBAAM,OAC3F,YACc,gBAAO,IACL,gBAAO,IAAI,WAAa,CACpC,MAAMC,EAAS,QAAQ,IAAI,iBAE3B,GAAI,CAACA,EACH,OAAO,MAAO,IAAI7E,EAAY,CAC5B,QAAS,mDACX,CAAC,EAGH,MAAO,CACL,OAAQyE,EAAS,KAAKI,CAAM,EAC5B,WAAY,QAAQ,IAAI,uBAAA,uBAC1B,CACF,CAAC,EACA,GAAWN,EAAO,QAAQI,CAAM,CACnC,CACF,ECpCA,IAAa,qBAAb,eACwB,gBAAyC,CAAC,CAC9D,uBACA/D,CACF,EAAA,AAAE,CAAC,EAGL,IAAa,mBAAb,eACwB,gBAAuC,CAAC,CAAC,qBAAsB,CACnF,KAAMjB,EACN,MAAOA,CACT,CAAC,CAAC,CAAC,KAAKC,CAAuB,EAAA,AAAE,CAAC,EAOpC,MAAakF,GAAwBjF,ECfrC,MAAakF,GAAiC,gBAAa,CAGzD,YAA2B,gBAAO,QAAQ,WAAW,EACrD,QAAU,GAAUC,EAAM,WAC1B,QAAU,IAAW,CACnB,cAAe,UAAUP,EAAS,MAAMO,EAAM,MAAM,GACtD,GAGA,aAAe,GAAS,IAAI,qBAAqB3D,EAAkB4D,CAAI,CAAC,EACxE,YAAa,CAAE,OAAM,WAAY,IAAI,mBAAmB,CAAE,OAAM,OAAM,CAAC,CACzE,CAAC,ECfD,IAAa,MAAb,eAAyC,gBAAQ,QAAuB,CAAC,CAAC,eAAe,EAAA,AAAE,CAAC,EAG5F,MAAa,OAAU,GACrBV,EAAO,QAAQC,EAAM,QAAQ,MAAOU,CAAgB,CAAC,EAGvD,MAAaC,GAAqB,gBAAO,QACzB,gBAAM,QAAQ,MAAO,CAAE,UAAa,KAAM,CAAC,CAC3D,EAGA,MAAaC,GAA2B,qBAAO3C,CAAiB,EAGhE,MAAa4C,GAA0B,qBAAO1C,CAAgB"}
|
package/lib/credentials.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { ConfigError } from "@distilled.cloud/core/errors";
|
|
|
4
4
|
*
|
|
5
5
|
* API-compatible port of the distilled v0 credentials module: the
|
|
6
6
|
* `Credentials` service holds an *effect* that resolves the current
|
|
7
|
-
* credentials on every request (the protocol
|
|
7
|
+
* credentials on every request (the protocol resolves it per request
|
|
8
8
|
* on the calling fiber).
|
|
9
9
|
*
|
|
10
10
|
* Temporal Cloud and JWT-configured self-hosted servers accept
|
|
@@ -22,7 +22,7 @@ export interface Config {
|
|
|
22
22
|
readonly apiKey: Redacted.Redacted<string>;
|
|
23
23
|
readonly apiBaseUrl: string;
|
|
24
24
|
}
|
|
25
|
-
declare const Credentials_base: Context.ServiceClass<Credentials, "TemporalCredentials", Effect.Effect<Config,
|
|
25
|
+
declare const Credentials_base: Context.ServiceClass<Credentials, "TemporalCredentials", Effect.Effect<Config, never, never>>;
|
|
26
26
|
export declare class Credentials extends /*@__PURE__*/ Credentials_base {
|
|
27
27
|
}
|
|
28
28
|
/** Layer from a redacted API key + optional base URL. */
|
|
@@ -30,7 +30,12 @@ export declare const fromApiKey: (config: {
|
|
|
30
30
|
readonly apiKey: Redacted.Redacted<string>;
|
|
31
31
|
readonly apiBaseUrl?: string;
|
|
32
32
|
}) => Layer.Layer<Credentials>;
|
|
33
|
-
/**
|
|
34
|
-
|
|
33
|
+
/**
|
|
34
|
+
* Reads TEMPORAL_API_KEY (required) and TEMPORAL_API_BASE_URL (optional).
|
|
35
|
+
*
|
|
36
|
+
* Its configuration is read and checked once, when the layer is built: a
|
|
37
|
+
* problem there fails the layer with `ConfigError`.
|
|
38
|
+
*/
|
|
39
|
+
export declare const CredentialsFromEnv: Layer.Layer<Credentials, ConfigError>;
|
|
35
40
|
export {};
|
|
36
41
|
//# sourceMappingURL=credentials.d.ts.map
|
package/lib/credentials.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"credentials.d.ts","
|
|
1
|
+
{"version":3,"file":"credentials.d.ts","sources":["../src/credentials.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D;;;;;;;;;;;;GAYG;AACH,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAC;AAC1C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,QAAQ,MAAM,iBAAiB,CAAC;AAE5C,uEAAuE;AACvE,eAAO,MAAM,oBAAoB,0BAA0B,CAAC;AAE5D,MAAM,WAAW,MAAM;IACrB,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC3C,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B;;AAED,qBAAa,WACX,SAAQ,aAAa,CAAC,gBAErB;CAAG;AAEN,yDAAyD;AACzD,eAAO,MAAM,UAAU,WAAY;IACjC,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC3C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;CAC9B,KAAG,KAAK,CAAC,KAAK,CAAC,WAAW,CAOxB,CAAC;AAEJ;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,EAAE,KAAK,CAAC,KAAK,CAAC,WAAW,EAAE,WAAW,CAmBpE,CAAC"}
|
package/lib/errors.d.ts
CHANGED
|
@@ -30,4 +30,11 @@ declare const TemporalParseError_base: Schema.TaggedErrorClass<"TemporalParseErr
|
|
|
30
30
|
/** Schema parse error wrapper (kept for v0 surface parity). */
|
|
31
31
|
export declare class TemporalParseError extends /*@__PURE__*/ TemporalParseError_base {
|
|
32
32
|
}
|
|
33
|
+
/**
|
|
34
|
+
* The errors declared on the Temporal service: any operation can return them,
|
|
35
|
+
* and every generated operation lists them as its `serviceErrors`. Today that
|
|
36
|
+
* is each of core's status classes (401, 403, 404, 429, the 5xx ...).
|
|
37
|
+
*/
|
|
38
|
+
export declare const TemporalServiceErrors: readonly [typeof import("@distilled.cloud/core/errors").Unauthorized, typeof import("@distilled.cloud/core/errors").Forbidden, typeof import("@distilled.cloud/core/errors").NotFound, typeof import("@distilled.cloud/core/errors").BadRequest, typeof import("@distilled.cloud/core/errors").Conflict, typeof import("@distilled.cloud/core/errors").UnprocessableEntity, typeof import("@distilled.cloud/core/errors").TooManyRequests, typeof import("@distilled.cloud/core/errors").Locked, typeof import("@distilled.cloud/core/errors").InternalServerError, typeof import("@distilled.cloud/core/errors").BadGateway, typeof import("@distilled.cloud/core/errors").ServiceUnavailable, typeof import("@distilled.cloud/core/errors").GatewayTimeout];
|
|
39
|
+
export type TemporalServiceError = InstanceType<(typeof TemporalServiceErrors)[number]>;
|
|
33
40
|
//# sourceMappingURL=errors.d.ts.map
|
package/lib/errors.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EACL,UAAU,EACV,UAAU,EACV,QAAQ,EACR,WAAW,EACX,SAAS,EACT,cAAc,EACd,mBAAmB,EACnB,MAAM,EACN,QAAQ,EACR,kBAAkB,EAClB,eAAe,EACf,YAAY,EACZ,mBAAmB,EACnB,eAAe,EACf,cAAc,EACd,UAAU,GACX,MAAM,8BAA8B,CAAC;AACtC,YAAY,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAIlE,OAAO,KAAK,MAAM,MAAM,yCAAyC,CAAC;;;;;;;AAElE,gFAAgF;AAChF,qBAAa,oBACX,SAAQ,aAAa,CAAC,yBAGrB;CAAG;;;;;;;;;AAEN,+DAA+D;AAC/D,qBAAa,kBACX,SAAQ,aAAa,CAAC,uBAGU;CAAG;AAErC;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,+tBAAa,CAAC;AAChD,MAAM,MAAM,oBAAoB,GAAG,YAAY,CAAC,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC"}
|
package/lib/errors.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { errors$API_ERRORS as API_ERRORS, errors$BadGateway as BadGateway, errors$BadRequest as BadRequest, errors$ConfigError as ConfigError, errors$Conflict as Conflict, errors$DEFAULT_ERRORS as DEFAULT_ERRORS, errors$Forbidden as Forbidden, errors$GatewayTimeout as GatewayTimeout, errors$HTTP_STATUS_MAP as HTTP_STATUS_MAP, errors$InternalServerError as InternalServerError, errors$Locked as Locked, errors$NotFound as NotFound, errors$ServiceUnavailable as ServiceUnavailable, errors$TemporalParseError as TemporalParseError, errors$TooManyRequests as TooManyRequests, errors$Unauthorized as Unauthorized, errors$UnknownTemporalError as UnknownTemporalError, errors$UnprocessableEntity as UnprocessableEntity } from "./_bundle/sdk.js";
|
|
1
|
+
export { errors$API_ERRORS as API_ERRORS, errors$BadGateway as BadGateway, errors$BadRequest as BadRequest, errors$ConfigError as ConfigError, errors$Conflict as Conflict, errors$DEFAULT_ERRORS as DEFAULT_ERRORS, errors$Forbidden as Forbidden, errors$GatewayTimeout as GatewayTimeout, errors$HTTP_STATUS_MAP as HTTP_STATUS_MAP, errors$InternalServerError as InternalServerError, errors$Locked as Locked, errors$NotFound as NotFound, errors$ServiceUnavailable as ServiceUnavailable, errors$TemporalParseError as TemporalParseError, errors$TemporalServiceErrors as TemporalServiceErrors, errors$TooManyRequests as TooManyRequests, errors$Unauthorized as Unauthorized, errors$UnknownTemporalError as UnknownTemporalError, errors$UnprocessableEntity as UnprocessableEntity } from "./_bundle/sdk.js";
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,cAAc,kBAAkB,CAAC;AACjC,cAAc,aAAa,CAAC;AAC5B,OAAO,KAAK,CAAC,MAAM,aAAa,CAAC;AACjC,OAAO,EAAE,gBAAgB,EAAE,KAAK,eAAe,EAAE,KAAK,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,KAAK,QAAQ,MAAM,qBAAqB,CAAC;AAKhD,cAAc,wBAAwB,CAAC"}
|
package/lib/index.lazy.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AACH,cAAc,kBAAkB,CAAC;AACjC,cAAc,aAAa,CAAC;AAC5B,OAAO,KAAK,CAAC,MAAM,aAAa,CAAC;AACjC,OAAO,EAAE,gBAAgB,EAAgD,MAAM,eAAe,CAAC;AAC/F,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,KAAK,QAAQ,MAAM,qBAAqB,CAAC;AAChD,4EAA4E;AAC5E,qEAAqE;AACrE,wEAAwE;AACxE,yBAAyB;AACzB,cAAc,wBAAwB,CAAC"}
|
package/lib/pagination.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pagination.d.ts","
|
|
1
|
+
{"version":3,"file":"pagination.d.ts","sources":["../src/pagination.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC"}
|
package/lib/protocol.d.ts
CHANGED
|
@@ -1,19 +1,16 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import type { API_ERRORS, ConfigError, InvalidInput } from "@distilled.cloud/core/errors";
|
|
3
|
-
import type { SdkError } from "@distilled.cloud/core/sdk-error";
|
|
1
|
+
import type { ErrorOf } from "@distilled.cloud/core/protocol";
|
|
4
2
|
import type * as HttpClient from "effect/http/HttpClient";
|
|
5
|
-
import type * as HttpClientError from "effect/http/HttpClientError";
|
|
6
|
-
import type * as Layer from "effect/Layer";
|
|
7
3
|
import { Credentials } from "./credentials.ts";
|
|
8
|
-
import { UnknownTemporalError, TemporalParseError } from "./errors.ts";
|
|
4
|
+
import { UnknownTemporalError, TemporalParseError, type TemporalServiceError } from "./errors.ts";
|
|
9
5
|
/**
|
|
10
|
-
*
|
|
11
|
-
* service
|
|
12
|
-
*
|
|
13
|
-
*
|
|
6
|
+
* What every generated Temporal operation fails with besides its own errors:
|
|
7
|
+
* the service's errors, the protocol's, and what resolving the credentials
|
|
8
|
+
* fails with. Generated service files annotate operations with
|
|
9
|
+
* `API.OperationMethod<I, O, TemporalOpError, TemporalOpContext>` explicitly
|
|
10
|
+
* so the compiler never infers these back out of the schema generics.
|
|
14
11
|
*/
|
|
15
|
-
export type TemporalOpError =
|
|
12
|
+
export type TemporalOpError = TemporalServiceError | ErrorOf<typeof TemporalProtocol>;
|
|
16
13
|
/** Context (requirements) shared by every generated Temporal operation. */
|
|
17
14
|
export type TemporalOpContext = Credentials | HttpClient.HttpClient;
|
|
18
|
-
export declare const TemporalProtocol:
|
|
15
|
+
export declare const TemporalProtocol: import("@distilled.cloud/core/protocol").Protocol<TemporalParseError | UnknownTemporalError | import("@distilled.cloud/core/protocol-rest").RestProtocolError, Credentials>;
|
|
19
16
|
//# sourceMappingURL=protocol.d.ts.map
|
package/lib/protocol.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"protocol.d.ts","
|
|
1
|
+
{"version":3,"file":"protocol.d.ts","sources":["../src/protocol.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gCAAgC,CAAC;AAoB9D,OAAO,KAAK,KAAK,UAAU,MAAM,wBAAwB,CAAC;AAE1D,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,KAAK,oBAAoB,EAAE,MAAM,aAAa,CAAC;AAElG;;;;;;GAMG;AACH,MAAM,MAAM,eAAe,GAAG,oBAAoB,GAAG,OAAO,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEtF,2EAA2E;AAC3E,MAAM,MAAM,iBAAiB,GAAG,WAAW,GAAG,UAAU,CAAC,UAAU,CAAC;AAEpE,eAAO,MAAM,gBAAgB,6KAY3B,CAAC"}
|
package/lib/retry.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retry.d.ts","
|
|
1
|
+
{"version":3,"file":"retry.d.ts","sources":["../src/retry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAuC,MAAM,6BAA6B,CAAC;AAC/F;;;;;;;;;;;;;;GAcG;AACH,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAC;AAC1C,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AAGxC,OAAO,EACL,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,MAAM,EACX,WAAW,EACX,QAAQ,EACR,MAAM,EACN,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,GACjB,MAAM,6BAA6B,CAAC;;AAErC,wEAAwE;AACxE,qBAAa,KAAM,SAAQ,aAAa,CAAC,UAAiD;CAAG;AAE7F,0EAA0E;AAC1E,eAAO,MAAM,MAAM,qBAAsB,MAAM,sFACS,CAAC;AAEzD,sCAAsC;AACtC,eAAO,MAAM,IAAI,mFAEhB,CAAC;AAEF,kFAAkF;AAClF,eAAO,MAAM,UAAU,mFAA0C,CAAC;AAElE,oFAAoF;AACpF,eAAO,MAAM,SAAS,mFAAyC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../../src/services/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,QAAQ,MAAM,eAAe,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import * as API from "@distilled.cloud/core/api";
|
|
2
|
+
import type * as Redacted from "effect/Redacted";
|
|
2
3
|
import { type TemporalOpError, type TemporalOpContext } from "../protocol.ts";
|
|
3
4
|
export type { TemporalOpError, TemporalOpContext };
|
|
4
5
|
export interface CountActivityExecutionsRequest {
|
|
@@ -3766,7 +3767,7 @@ export interface QueryWorkflowResponse {
|
|
|
3766
3767
|
export interface RecordActivityTaskHeartbeatRequest {
|
|
3767
3768
|
namespace: string;
|
|
3768
3769
|
/** The task token as received in `PollActivityTaskQueueResponse` */
|
|
3769
|
-
taskToken?: string | undefined;
|
|
3770
|
+
taskToken?: string | Redacted.Redacted<string> | undefined;
|
|
3770
3771
|
/** Arbitrary data, of which the most recent call is kept, to store for this activity */
|
|
3771
3772
|
details?: Payloads | undefined;
|
|
3772
3773
|
/** The identity of the worker/client */
|
|
@@ -3835,7 +3836,7 @@ export interface RegisterNamespaceRequest {
|
|
|
3835
3836
|
activeClusterName?: string | undefined;
|
|
3836
3837
|
/** A key-value map for any customized purpose. */
|
|
3837
3838
|
data?: RegisterNamespaceRequestDataMap | undefined;
|
|
3838
|
-
securityToken?: string | undefined;
|
|
3839
|
+
securityToken?: string | Redacted.Redacted<string> | undefined;
|
|
3839
3840
|
isGlobalNamespace?: boolean | undefined;
|
|
3840
3841
|
/** If unspecified (ARCHIVAL_STATE_UNSPECIFIED) then default server configuration is used. */
|
|
3841
3842
|
historyArchivalState?: RegisterNamespaceRequestHistoryArchivalState | (string & {}) | undefined;
|
|
@@ -4000,7 +4001,7 @@ export interface ResetWorkflowExecutionResponse {
|
|
|
4000
4001
|
export interface RespondActivityTaskCanceledRequest {
|
|
4001
4002
|
namespace: string;
|
|
4002
4003
|
/** The task token as received in `PollActivityTaskQueueResponse` */
|
|
4003
|
-
taskToken?: string | undefined;
|
|
4004
|
+
taskToken?: string | Redacted.Redacted<string> | undefined;
|
|
4004
4005
|
/** Serialized additional information to attach to the cancellation */
|
|
4005
4006
|
details?: Payloads | undefined;
|
|
4006
4007
|
/** The identity of the worker/client */
|
|
@@ -4037,7 +4038,7 @@ export type RespondActivityTaskCanceledByIdResponse2 = unknown;
|
|
|
4037
4038
|
export interface RespondActivityTaskCompletedRequest {
|
|
4038
4039
|
namespace: string;
|
|
4039
4040
|
/** The task token as received in `PollActivityTaskQueueResponse` */
|
|
4040
|
-
taskToken?: string | undefined;
|
|
4041
|
+
taskToken?: string | Redacted.Redacted<string> | undefined;
|
|
4041
4042
|
/** The result of successfully executing the activity */
|
|
4042
4043
|
result?: Payloads | undefined;
|
|
4043
4044
|
/** The identity of the worker/client */
|
|
@@ -4072,7 +4073,7 @@ export type RespondActivityTaskCompletedByIdResponse2 = unknown;
|
|
|
4072
4073
|
export interface RespondActivityTaskFailedRequest {
|
|
4073
4074
|
namespace: string;
|
|
4074
4075
|
/** The task token as received in `PollActivityTaskQueueResponse` */
|
|
4075
|
-
taskToken?: string | undefined;
|
|
4076
|
+
taskToken?: string | Redacted.Redacted<string> | undefined;
|
|
4076
4077
|
/** Detailed failure information */
|
|
4077
4078
|
failure?: Failure | undefined;
|
|
4078
4079
|
/** The identity of the worker/client */
|
|
@@ -4656,7 +4657,7 @@ export interface PollerGroupInfo {
|
|
|
4656
4657
|
export type PollWorkflowTaskQueueResponsePollerGroupInfosList = Array<PollerGroupInfo>;
|
|
4657
4658
|
export interface PollWorkflowTaskQueueResponse {
|
|
4658
4659
|
/** A unique identifier for this task */
|
|
4659
|
-
taskToken?: string | undefined;
|
|
4660
|
+
taskToken?: string | Redacted.Redacted<string> | undefined;
|
|
4660
4661
|
workflowExecution?: WorkflowExecution | undefined;
|
|
4661
4662
|
workflowType?: WorkflowType | undefined;
|
|
4662
4663
|
/** The last workflow task started event which was processed by some worker for this execution. Will be zero if no task has ever started. */
|
|
@@ -4898,7 +4899,7 @@ export interface UpdateNamespaceRequest {
|
|
|
4898
4899
|
updateInfo?: UpdateNamespaceInfo | undefined;
|
|
4899
4900
|
config?: NamespaceConfig | undefined;
|
|
4900
4901
|
replicationConfig?: NamespaceReplicationConfig | undefined;
|
|
4901
|
-
securityToken?: string | undefined;
|
|
4902
|
+
securityToken?: string | Redacted.Redacted<string> | undefined;
|
|
4902
4903
|
deleteBadBinary?: string | undefined;
|
|
4903
4904
|
/** promote local namespace to global namespace. Ignored if namespace is already global namespace. */
|
|
4904
4905
|
promoteNamespace?: boolean | undefined;
|