@spotto/contract 1.0.67-alpha.3 → 1.0.67-alpha.5

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.
@@ -4,6 +4,6 @@ export declare type AssetCrudEventType = 'AssetCreated' | 'AssetUpdated' | 'Asse
4
4
  export declare type LocationCrudEventType = 'LocationCreated' | 'LocationUpdated' | 'LocationDeleted';
5
5
  export declare type ReaderCrudEventType = 'ReaderCreated' | 'ReaderUpdated' | 'ReaderDeleted';
6
6
  export declare type SnapshotCrudEventType = 'SnapshotCreated' | 'SnapshotDeleted';
7
- export declare type SlateEventType = 'ReaderArrived' | 'ReaderExited' | 'Arrived' | 'Moved' | 'ExplicitArrived' | 'Exited' | 'ReaderOnline' | 'ReaderOffline';
7
+ export declare type SlateEventType = 'ReaderArrived' | 'ReaderExited' | 'Arrived' | 'Moved' | 'Exited' | 'ReaderOnline' | 'ReaderOffline';
8
8
  export declare type EventType = SlateEventType | AssetCrudEventType | LocationCrudEventType | ReaderCrudEventType | SnapshotCrudEventType | 'UserSearch' | 'WorkflowActionExecuted';
9
9
  export declare const EVENT_TYPES: EventType[];
@@ -13,7 +13,6 @@ exports.EVENT_TYPES = [
13
13
  'ReaderExited',
14
14
  'Arrived',
15
15
  'Moved',
16
- 'ExplicitArrived',
17
16
  'Exited',
18
17
  'ReaderOnline',
19
18
  'ReaderOffline',
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/events/constants.ts"],"names":[],"mappings":";;;AACa,QAAA,qBAAqB,GAA0B;IAC1D,MAAM;IACN,MAAM;IACN,OAAO;IACP,KAAK;IACL,MAAM;CACP,CAAA;AAsCY,QAAA,WAAW,GAAgB;IACtC,eAAe;IACf,cAAc;IACd,SAAS;IACT,OAAO;IACP,iBAAiB;IACjB,QAAQ;IACR,cAAc;IACd,eAAe;IACf,cAAc;IACd,cAAc;IACd,cAAc;IACd,iBAAiB;IACjB,iBAAiB;IACjB,iBAAiB;IACjB,eAAe;IACf,eAAe;IACf,eAAe;IACf,iBAAiB;IACjB,iBAAiB;IACjB,YAAY;IACZ,wBAAwB;CACzB,CAAA"}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/events/constants.ts"],"names":[],"mappings":";;;AACa,QAAA,qBAAqB,GAA0B;IAC1D,MAAM;IACN,MAAM;IACN,OAAO;IACP,KAAK;IACL,MAAM;CACP,CAAA;AAqCY,QAAA,WAAW,GAAgB;IACtC,eAAe;IACf,cAAc;IACd,SAAS;IACT,OAAO;IACP,QAAQ;IACR,cAAc;IACd,eAAe;IACf,cAAc;IACd,cAAc;IACd,cAAc;IACd,iBAAiB;IACjB,iBAAiB;IACjB,iBAAiB;IACjB,eAAe;IACf,eAAe;IACf,eAAe;IACf,iBAAiB;IACjB,iBAAiB;IACjB,YAAY;IACZ,wBAAwB;CACzB,CAAA"}
@@ -10,6 +10,15 @@ export interface EventLocation extends IEmbeddedEntity {
10
10
  type: LocationType;
11
11
  organisation?: IEmbeddedEntity;
12
12
  }
13
+ export interface AssetEventLocation extends Partial<IEmbeddedEntity> {
14
+ type: LocationType;
15
+ organisation?: IEmbeddedEntity;
16
+ withAsset?: IEmbeddedEntity;
17
+ locationGPS?: {
18
+ type: 'Point';
19
+ coordinates: [number, number];
20
+ };
21
+ }
13
22
  export interface IBaseEvent {
14
23
  id: string;
15
24
  timestamp: number;
@@ -79,14 +88,14 @@ export interface IWorkflowActionExecutedEvent extends IBaseEvent {
79
88
  export interface IArrivedEvent extends IBaseEvent {
80
89
  type: 'Arrived';
81
90
  asset: IEmbeddedEntity;
82
- location: EventLocation;
83
- reader: IEmbeddedEntity;
91
+ location: AssetEventLocation;
92
+ reader?: IEmbeddedEntity;
84
93
  }
85
94
  export interface IExitedEvent extends IBaseEvent {
86
95
  type: 'Exited';
87
96
  asset: IEmbeddedEntity;
88
- location: EventLocation;
89
- reader: IEmbeddedEntity;
97
+ location: AssetEventLocation;
98
+ reader?: IEmbeddedEntity;
90
99
  }
91
100
  export interface IReaderArrivedEvent extends IBaseEvent {
92
101
  type: 'ReaderArrived';
@@ -101,13 +110,8 @@ export interface IReaderExitedEvent extends IBaseEvent {
101
110
  export interface IMovedEvent extends IBaseEvent {
102
111
  type: 'Moved';
103
112
  asset: IEmbeddedEntity;
104
- location: EventLocation;
105
- reader: IEmbeddedEntity;
106
- }
107
- export interface IExplicitArrivedEvent extends IBaseEvent {
108
- type: 'ExplicitArrived';
109
- asset: IEmbeddedEntity;
110
- location: EventLocation;
113
+ location: AssetEventLocation;
114
+ reader?: IEmbeddedEntity;
111
115
  }
112
116
  export interface IReaderOnlineEvent extends IBaseEvent {
113
117
  type: 'ReaderOnline';
@@ -117,7 +121,7 @@ export interface IReaderOfflineEvent extends IBaseEvent {
117
121
  type: 'ReaderOffline';
118
122
  reader: IEmbeddedEntity;
119
123
  }
120
- export declare type GetEventResponse = IAssetCrudEvent | ILocationCrudEvent | IReaderCrudEvent | ISnapshotCrudEvent | IUserSearchEvent | IReaderArrivedEvent | IReaderExitedEvent | IArrivedEvent | IMovedEvent | IExplicitArrivedEvent | IExitedEvent | IReaderOnlineEvent | IReaderOfflineEvent | IWorkflowActionExecutedEvent;
124
+ export declare type GetEventResponse = IAssetCrudEvent | ILocationCrudEvent | IReaderCrudEvent | ISnapshotCrudEvent | IUserSearchEvent | IReaderArrivedEvent | IReaderExitedEvent | IArrivedEvent | IMovedEvent | IExitedEvent | IReaderOnlineEvent | IReaderOfflineEvent | IWorkflowActionExecutedEvent;
121
125
  export interface GetEventsResponse {
122
126
  query: GetEventsQuery | null;
123
127
  items: GetEventResponse[];
@@ -8,7 +8,6 @@ export interface IManifestType {
8
8
  countMin?: number;
9
9
  countMax?: number;
10
10
  untagged?: boolean;
11
- selectedManifestId?: string;
12
11
  manifestIds?: string[];
13
12
  manifest?: GetManifestResponse;
14
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"get.js","sourceRoot":"","sources":["../../../src/manifests/[id]/get.ts"],"names":[],"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,EAAE,EAAE;SACZ;QACD;YACE,MAAM,EAAE,MAAM;YACd,QAAQ,EAAE,YAAY;YACtB,QAAQ,EAAE,EAAE;YACZ,QAAQ,EAAE,EAAE;YACZ,QAAQ,EAAE,IAAI;YACd,OAAO,EAAE,KAAK;SACf;KACF;IACD,UAAU,EAAE,CAAC;IACb,WAAW,EAAE,CAAC;CACf,CAAA"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@spotto/contract",
3
3
  "license": "ISC",
4
- "version": "1.0.67-alpha.3",
4
+ "version": "1.0.67-alpha.5",
5
5
  "description": "Spotto's API Contract type definitions",
6
6
  "main": "./dist/index.js",
7
7
  "files": [
@@ -18,5 +18,5 @@
18
18
  "@types/geojson": "^7946.0.11",
19
19
  "shx": "^0.3.4"
20
20
  },
21
- "gitHead": "0486e44d92fd4177ca8324a0077521896d18539c"
21
+ "gitHead": "9bf058c83136c603dde64800875f21b8b6da8aaf"
22
22
  }