@shipfox/api-definitions-dto 2.0.0 → 6.0.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.
@@ -1,2 +1,2 @@
1
1
  $ shipfox-swc
2
- Successfully compiled: 5 files with swc (38.62ms)
2
+ Successfully compiled: 7 files with swc (307.57ms)
package/CHANGELOG.md CHANGED
@@ -1,5 +1,22 @@
1
1
  # @shipfox/api-definitions-dto
2
2
 
3
+ ## 6.0.0
4
+
5
+ ### Minor Changes
6
+
7
+ - a8f0545: Adds the versioned Definitions workflow snapshot contract and registered presentation.
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [81f9544]
12
+ - @shipfox/inter-module@0.2.0
13
+
14
+ ## 5.0.0
15
+
16
+ ### Patch Changes
17
+
18
+ - bb037af: Resolves workspace packages from source during development while published consumers continue to use compiled output.
19
+
3
20
  ## 2.0.0
4
21
 
5
22
  ### Minor Changes
package/dist/index.d.ts CHANGED
@@ -1,3 +1,5 @@
1
1
  export { type CreateDefinitionBodyDto, createDefinitionBodySchema, type DefinitionDto, type DefinitionListQueryDto, type DefinitionListResponseDto, type DefinitionResponseDto, type DefinitionSyncSummaryDto, type DefinitionValidationErrorDto, definitionDtoSchema, definitionListQuerySchema, definitionListResponseSchema, definitionResponseSchema, definitionSyncSummarySchema, definitionValidationErrorSchema, type TriggerDto, } from '#schemas/index.js';
2
2
  export { DEFINITION_DELETED, DEFINITION_INVALID, DEFINITION_RESOLVED, type DefinitionDeletedEvent, type DefinitionInvalidEvent, type DefinitionResolvedEvent, type DefinitionsEventMap, definitionDeletedEventSchema, definitionInvalidEventSchema, definitionResolvedEventSchema, definitionsEventSchemas, } from './events.js';
3
+ export type * from './workflow-model.js';
4
+ export { createWorkflowModelSnapshot, DEFAULT_JOB_CHECKOUT, DEFAULT_JOB_SUCCESS, DEFAULT_RUN_TIMEOUT_MS, readPersistedWorkflowModel, workflowModelFromSnapshot, workflowModelSnapshotSchema, } from './workflow-model.js';
3
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,uBAAuB,EAC5B,0BAA0B,EAC1B,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,qBAAqB,EAC1B,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,mBAAmB,EACnB,yBAAyB,EACzB,4BAA4B,EAC5B,wBAAwB,EACxB,2BAA2B,EAC3B,+BAA+B,EAC/B,KAAK,UAAU,GAChB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,4BAA4B,EAC5B,4BAA4B,EAC5B,6BAA6B,EAC7B,uBAAuB,GACxB,MAAM,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,uBAAuB,EAC5B,0BAA0B,EAC1B,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,qBAAqB,EAC1B,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,mBAAmB,EACnB,yBAAyB,EACzB,4BAA4B,EAC5B,wBAAwB,EACxB,2BAA2B,EAC3B,+BAA+B,EAC/B,KAAK,UAAU,GAChB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,uBAAuB,EAC5B,KAAK,mBAAmB,EACxB,4BAA4B,EAC5B,4BAA4B,EAC5B,6BAA6B,EAC7B,uBAAuB,GACxB,MAAM,aAAa,CAAC;AACrB,mBAAmB,qBAAqB,CAAC;AACzC,OAAO,EACL,2BAA2B,EAC3B,oBAAoB,EACpB,mBAAmB,EACnB,sBAAsB,EACtB,0BAA0B,EAC1B,yBAAyB,EACzB,2BAA2B,GAC5B,MAAM,qBAAqB,CAAC"}
package/dist/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  export { createDefinitionBodySchema, definitionDtoSchema, definitionListQuerySchema, definitionListResponseSchema, definitionResponseSchema, definitionSyncSummarySchema, definitionValidationErrorSchema } from '#schemas/index.js';
2
2
  export { DEFINITION_DELETED, DEFINITION_INVALID, DEFINITION_RESOLVED, definitionDeletedEventSchema, definitionInvalidEventSchema, definitionResolvedEventSchema, definitionsEventSchemas } from './events.js';
3
+ export { createWorkflowModelSnapshot, DEFAULT_JOB_CHECKOUT, DEFAULT_JOB_SUCCESS, DEFAULT_RUN_TIMEOUT_MS, readPersistedWorkflowModel, workflowModelFromSnapshot, workflowModelSnapshotSchema } from './workflow-model.js';
3
4
 
4
5
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export {\n type CreateDefinitionBodyDto,\n createDefinitionBodySchema,\n type DefinitionDto,\n type DefinitionListQueryDto,\n type DefinitionListResponseDto,\n type DefinitionResponseDto,\n type DefinitionSyncSummaryDto,\n type DefinitionValidationErrorDto,\n definitionDtoSchema,\n definitionListQuerySchema,\n definitionListResponseSchema,\n definitionResponseSchema,\n definitionSyncSummarySchema,\n definitionValidationErrorSchema,\n type TriggerDto,\n} from '#schemas/index.js';\nexport {\n DEFINITION_DELETED,\n DEFINITION_INVALID,\n DEFINITION_RESOLVED,\n type DefinitionDeletedEvent,\n type DefinitionInvalidEvent,\n type DefinitionResolvedEvent,\n type DefinitionsEventMap,\n definitionDeletedEventSchema,\n definitionInvalidEventSchema,\n definitionResolvedEventSchema,\n definitionsEventSchemas,\n} from './events.js';\n"],"names":["createDefinitionBodySchema","definitionDtoSchema","definitionListQuerySchema","definitionListResponseSchema","definitionResponseSchema","definitionSyncSummarySchema","definitionValidationErrorSchema","DEFINITION_DELETED","DEFINITION_INVALID","DEFINITION_RESOLVED","definitionDeletedEventSchema","definitionInvalidEventSchema","definitionResolvedEventSchema","definitionsEventSchemas"],"mappings":"AAAA,SAEEA,0BAA0B,EAO1BC,mBAAmB,EACnBC,yBAAyB,EACzBC,4BAA4B,EAC5BC,wBAAwB,EACxBC,2BAA2B,EAC3BC,+BAA+B,QAE1B,oBAAoB;AAC3B,SACEC,kBAAkB,EAClBC,kBAAkB,EAClBC,mBAAmB,EAKnBC,4BAA4B,EAC5BC,4BAA4B,EAC5BC,6BAA6B,EAC7BC,uBAAuB,QAClB,cAAc"}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export {\n type CreateDefinitionBodyDto,\n createDefinitionBodySchema,\n type DefinitionDto,\n type DefinitionListQueryDto,\n type DefinitionListResponseDto,\n type DefinitionResponseDto,\n type DefinitionSyncSummaryDto,\n type DefinitionValidationErrorDto,\n definitionDtoSchema,\n definitionListQuerySchema,\n definitionListResponseSchema,\n definitionResponseSchema,\n definitionSyncSummarySchema,\n definitionValidationErrorSchema,\n type TriggerDto,\n} from '#schemas/index.js';\nexport {\n DEFINITION_DELETED,\n DEFINITION_INVALID,\n DEFINITION_RESOLVED,\n type DefinitionDeletedEvent,\n type DefinitionInvalidEvent,\n type DefinitionResolvedEvent,\n type DefinitionsEventMap,\n definitionDeletedEventSchema,\n definitionInvalidEventSchema,\n definitionResolvedEventSchema,\n definitionsEventSchemas,\n} from './events.js';\nexport type * from './workflow-model.js';\nexport {\n createWorkflowModelSnapshot,\n DEFAULT_JOB_CHECKOUT,\n DEFAULT_JOB_SUCCESS,\n DEFAULT_RUN_TIMEOUT_MS,\n readPersistedWorkflowModel,\n workflowModelFromSnapshot,\n workflowModelSnapshotSchema,\n} from './workflow-model.js';\n"],"names":["createDefinitionBodySchema","definitionDtoSchema","definitionListQuerySchema","definitionListResponseSchema","definitionResponseSchema","definitionSyncSummarySchema","definitionValidationErrorSchema","DEFINITION_DELETED","DEFINITION_INVALID","DEFINITION_RESOLVED","definitionDeletedEventSchema","definitionInvalidEventSchema","definitionResolvedEventSchema","definitionsEventSchemas","createWorkflowModelSnapshot","DEFAULT_JOB_CHECKOUT","DEFAULT_JOB_SUCCESS","DEFAULT_RUN_TIMEOUT_MS","readPersistedWorkflowModel","workflowModelFromSnapshot","workflowModelSnapshotSchema"],"mappings":"AAAA,SAEEA,0BAA0B,EAO1BC,mBAAmB,EACnBC,yBAAyB,EACzBC,4BAA4B,EAC5BC,wBAAwB,EACxBC,2BAA2B,EAC3BC,+BAA+B,QAE1B,oBAAoB;AAC3B,SACEC,kBAAkB,EAClBC,kBAAkB,EAClBC,mBAAmB,EAKnBC,4BAA4B,EAC5BC,4BAA4B,EAC5BC,6BAA6B,EAC7BC,uBAAuB,QAClB,cAAc;AAErB,SACEC,2BAA2B,EAC3BC,oBAAoB,EACpBC,mBAAmB,EACnBC,sBAAsB,EACtBC,0BAA0B,EAC1BC,yBAAyB,EACzBC,2BAA2B,QACtB,sBAAsB"}
@@ -0,0 +1,44 @@
1
+ import { type InterModuleClient } from '@shipfox/inter-module';
2
+ import { z } from 'zod';
3
+ declare const definitionSnapshotSchema: z.ZodObject<{
4
+ id: z.ZodString;
5
+ projectId: z.ZodString;
6
+ name: z.ZodString;
7
+ model: z.ZodObject<{
8
+ version: z.ZodLiteral<1>;
9
+ model: z.ZodCustom<import("./workflow-model.js").WorkflowModel, import("./workflow-model.js").WorkflowModel>;
10
+ }, z.core.$strip>;
11
+ sourceSnapshot: z.ZodNullable<z.ZodObject<{
12
+ content: z.ZodString;
13
+ format: z.ZodLiteral<"yaml">;
14
+ }, z.core.$strip>>;
15
+ }, z.core.$strip>;
16
+ export declare const definitionsInterModuleContract: import("@shipfox/inter-module").InterModuleContract<{
17
+ readonly module: "definitions";
18
+ readonly methods: {
19
+ readonly getDefinitionForWorkflowRun: {
20
+ readonly input: z.ZodObject<{
21
+ definitionId: z.ZodString;
22
+ }, z.core.$strip>;
23
+ readonly output: z.ZodObject<{
24
+ definition: z.ZodNullable<z.ZodObject<{
25
+ id: z.ZodString;
26
+ projectId: z.ZodString;
27
+ name: z.ZodString;
28
+ model: z.ZodObject<{
29
+ version: z.ZodLiteral<1>;
30
+ model: z.ZodCustom<import("./workflow-model.js").WorkflowModel, import("./workflow-model.js").WorkflowModel>;
31
+ }, z.core.$strip>;
32
+ sourceSnapshot: z.ZodNullable<z.ZodObject<{
33
+ content: z.ZodString;
34
+ format: z.ZodLiteral<"yaml">;
35
+ }, z.core.$strip>>;
36
+ }, z.core.$strip>>;
37
+ }, z.core.$strip>;
38
+ };
39
+ };
40
+ }>;
41
+ export type DefinitionsInterModuleClient = InterModuleClient<typeof definitionsInterModuleContract>;
42
+ export type DefinitionWorkflowSnapshot = z.infer<typeof definitionSnapshotSchema>;
43
+ export {};
44
+ //# sourceMappingURL=inter-module.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"inter-module.d.ts","sourceRoot":"","sources":["../src/inter-module.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,KAAK,iBAAiB,EAAC,MAAM,uBAAuB,CAAC;AACxF,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAItB,QAAA,MAAM,wBAAwB;;;;;;;;;;;;iBAM5B,CAAC;AAEH,eAAO,MAAM,8BAA8B;;;;;;;;;;;;;;;;;;;;;;;;EAQzC,CAAC;AAEH,MAAM,MAAM,4BAA4B,GAAG,iBAAiB,CAAC,OAAO,8BAA8B,CAAC,CAAC;AACpG,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
@@ -0,0 +1,29 @@
1
+ import { defineInterModuleContract } from '@shipfox/inter-module';
2
+ import { z } from 'zod';
3
+ import { workflowModelSnapshotSchema } from './workflow-model.js';
4
+ const idSchema = z.string().uuid();
5
+ const definitionSnapshotSchema = z.object({
6
+ id: idSchema,
7
+ projectId: idSchema,
8
+ name: z.string(),
9
+ model: workflowModelSnapshotSchema,
10
+ sourceSnapshot: z.object({
11
+ content: z.string(),
12
+ format: z.literal('yaml')
13
+ }).nullable()
14
+ });
15
+ export const definitionsInterModuleContract = defineInterModuleContract({
16
+ module: 'definitions',
17
+ methods: {
18
+ getDefinitionForWorkflowRun: {
19
+ input: z.object({
20
+ definitionId: idSchema
21
+ }),
22
+ output: z.object({
23
+ definition: definitionSnapshotSchema.nullable()
24
+ })
25
+ }
26
+ }
27
+ });
28
+
29
+ //# sourceMappingURL=inter-module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/inter-module.ts"],"sourcesContent":["import {defineInterModuleContract, type InterModuleClient} from '@shipfox/inter-module';\nimport {z} from 'zod';\nimport {workflowModelSnapshotSchema} from './workflow-model.js';\n\nconst idSchema = z.string().uuid();\nconst definitionSnapshotSchema = z.object({\n id: idSchema,\n projectId: idSchema,\n name: z.string(),\n model: workflowModelSnapshotSchema,\n sourceSnapshot: z.object({content: z.string(), format: z.literal('yaml')}).nullable(),\n});\n\nexport const definitionsInterModuleContract = defineInterModuleContract({\n module: 'definitions',\n methods: {\n getDefinitionForWorkflowRun: {\n input: z.object({definitionId: idSchema}),\n output: z.object({definition: definitionSnapshotSchema.nullable()}),\n },\n },\n});\n\nexport type DefinitionsInterModuleClient = InterModuleClient<typeof definitionsInterModuleContract>;\nexport type DefinitionWorkflowSnapshot = z.infer<typeof definitionSnapshotSchema>;\n"],"names":["defineInterModuleContract","z","workflowModelSnapshotSchema","idSchema","string","uuid","definitionSnapshotSchema","object","id","projectId","name","model","sourceSnapshot","content","format","literal","nullable","definitionsInterModuleContract","module","methods","getDefinitionForWorkflowRun","input","definitionId","output","definition"],"mappings":"AAAA,SAAQA,yBAAyB,QAA+B,wBAAwB;AACxF,SAAQC,CAAC,QAAO,MAAM;AACtB,SAAQC,2BAA2B,QAAO,sBAAsB;AAEhE,MAAMC,WAAWF,EAAEG,MAAM,GAAGC,IAAI;AAChC,MAAMC,2BAA2BL,EAAEM,MAAM,CAAC;IACxCC,IAAIL;IACJM,WAAWN;IACXO,MAAMT,EAAEG,MAAM;IACdO,OAAOT;IACPU,gBAAgBX,EAAEM,MAAM,CAAC;QAACM,SAASZ,EAAEG,MAAM;QAAIU,QAAQb,EAAEc,OAAO,CAAC;IAAO,GAAGC,QAAQ;AACrF;AAEA,OAAO,MAAMC,iCAAiCjB,0BAA0B;IACtEkB,QAAQ;IACRC,SAAS;QACPC,6BAA6B;YAC3BC,OAAOpB,EAAEM,MAAM,CAAC;gBAACe,cAAcnB;YAAQ;YACvCoB,QAAQtB,EAAEM,MAAM,CAAC;gBAACiB,YAAYlB,yBAAyBU,QAAQ;YAAE;QACnE;IACF;AACF,GAAG"}