@spaciv/sdk 0.1.13 → 0.1.14

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.
@@ -117,6 +117,7 @@ src/models/CalcTreeValue.ts
117
117
  src/models/CalcTypeSingleValue.ts
118
118
  src/models/ChangelogOption.ts
119
119
  src/models/ChangelogValueOption.ts
120
+ src/models/ClientMessage.ts
120
121
  src/models/ConfidentialityData.ts
121
122
  src/models/Contribution.ts
122
123
  src/models/ContributionChangelogBody.ts
@@ -202,6 +203,8 @@ src/models/DatasetDataOneOf2.ts
202
203
  src/models/DatasetModify.ts
203
204
  src/models/DatasetRes.ts
204
205
  src/models/DaysOffData.ts
206
+ src/models/EntityChangeActor.ts
207
+ src/models/EntityChangedEvent.ts
205
208
  src/models/EntryPatch.ts
206
209
  src/models/EntryPatchPropertiesValue.ts
207
210
  src/models/ErrorDetail.ts
@@ -355,6 +358,7 @@ src/models/ScriptUsageResBody.ts
355
358
  src/models/ScriptWebhookResBody.ts
356
359
  src/models/SendPasswordPutReqBody.ts
357
360
  src/models/SerializedEvent.ts
361
+ src/models/ServerMessage.ts
358
362
  src/models/SingleSelectChangelogData.ts
359
363
  src/models/SingleSelectContributionData.ts
360
364
  src/models/SingleSelectData.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @spaciv/sdk@0.1.13
1
+ ## @spaciv/sdk@0.1.14
2
2
 
3
3
  This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
4
4
 
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
36
36
  _published:_
37
37
 
38
38
  ```
39
- npm install @spaciv/sdk@0.1.13 --save
39
+ npm install @spaciv/sdk@0.1.14 --save
40
40
  ```
41
41
 
42
42
  _unPublished (not recommended):_
@@ -0,0 +1,67 @@
1
+ /**
2
+ * spaciv API
3
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@spaciv.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface ClientMessage
16
+ */
17
+ export interface ClientMessage {
18
+ [key: string]: any | any;
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof ClientMessage
23
+ */
24
+ token?: string;
25
+ /**
26
+ * Between 1 and 100 topics for subscribe and unsubscribe. A message must fit within 128 KiB as sent, so topics whose JSON encoding is long go in several messages.
27
+ * @type {Array<string>}
28
+ * @memberof ClientMessage
29
+ */
30
+ topics?: Array<string>;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof ClientMessage
35
+ */
36
+ type: ClientMessageTypeEnum;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof ClientMessage
41
+ */
42
+ v: ClientMessageVEnum;
43
+ }
44
+ /**
45
+ * @export
46
+ */
47
+ export declare const ClientMessageTypeEnum: {
48
+ readonly Auth: "auth";
49
+ readonly Subscribe: "subscribe";
50
+ readonly Unsubscribe: "unsubscribe";
51
+ };
52
+ export type ClientMessageTypeEnum = typeof ClientMessageTypeEnum[keyof typeof ClientMessageTypeEnum];
53
+ /**
54
+ * @export
55
+ */
56
+ export declare const ClientMessageVEnum: {
57
+ readonly NUMBER_1: 1;
58
+ };
59
+ export type ClientMessageVEnum = typeof ClientMessageVEnum[keyof typeof ClientMessageVEnum];
60
+ /**
61
+ * Check if a given object implements the ClientMessage interface.
62
+ */
63
+ export declare function instanceOfClientMessage(value: object): value is ClientMessage;
64
+ export declare function ClientMessageFromJSON(json: any): ClientMessage;
65
+ export declare function ClientMessageFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientMessage;
66
+ export declare function ClientMessageToJSON(json: any): ClientMessage;
67
+ export declare function ClientMessageToJSONTyped(value?: ClientMessage | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,55 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * spaciv API
5
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@spaciv.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * @export
16
+ */
17
+ export const ClientMessageTypeEnum = {
18
+ Auth: 'auth',
19
+ Subscribe: 'subscribe',
20
+ Unsubscribe: 'unsubscribe'
21
+ };
22
+ /**
23
+ * @export
24
+ */
25
+ export const ClientMessageVEnum = {
26
+ NUMBER_1: 1
27
+ };
28
+ /**
29
+ * Check if a given object implements the ClientMessage interface.
30
+ */
31
+ export function instanceOfClientMessage(value) {
32
+ if (!('type' in value) || value['type'] === undefined)
33
+ return false;
34
+ if (!('v' in value) || value['v'] === undefined)
35
+ return false;
36
+ return true;
37
+ }
38
+ export function ClientMessageFromJSON(json) {
39
+ return ClientMessageFromJSONTyped(json, false);
40
+ }
41
+ export function ClientMessageFromJSONTyped(json, ignoreDiscriminator) {
42
+ if (json == null) {
43
+ return json;
44
+ }
45
+ return Object.assign(Object.assign({}, json), { 'token': json['token'] == null ? undefined : json['token'], 'topics': json['topics'] == null ? undefined : json['topics'], 'type': json['type'], 'v': json['v'] });
46
+ }
47
+ export function ClientMessageToJSON(json) {
48
+ return ClientMessageToJSONTyped(json, false);
49
+ }
50
+ export function ClientMessageToJSONTyped(value, ignoreDiscriminator = false) {
51
+ if (value == null) {
52
+ return value;
53
+ }
54
+ return Object.assign(Object.assign({}, value), { 'token': value['token'], 'topics': value['topics'], 'type': value['type'], 'v': value['v'] });
55
+ }
@@ -0,0 +1,61 @@
1
+ /**
2
+ * spaciv API
3
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@spaciv.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface EntityChangeActor
16
+ */
17
+ export interface EntityChangeActor {
18
+ [key: string]: any | any;
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof EntityChangeActor
23
+ */
24
+ clientId?: string;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof EntityChangeActor
29
+ */
30
+ session: string;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof EntityChangeActor
35
+ */
36
+ type: EntityChangeActorTypeEnum;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof EntityChangeActor
41
+ */
42
+ user: number;
43
+ }
44
+ /**
45
+ * @export
46
+ */
47
+ export declare const EntityChangeActorTypeEnum: {
48
+ readonly User: "user";
49
+ readonly System: "system";
50
+ readonly Anonymous: "anonymous";
51
+ readonly Unknown: "unknown";
52
+ };
53
+ export type EntityChangeActorTypeEnum = typeof EntityChangeActorTypeEnum[keyof typeof EntityChangeActorTypeEnum];
54
+ /**
55
+ * Check if a given object implements the EntityChangeActor interface.
56
+ */
57
+ export declare function instanceOfEntityChangeActor(value: object): value is EntityChangeActor;
58
+ export declare function EntityChangeActorFromJSON(json: any): EntityChangeActor;
59
+ export declare function EntityChangeActorFromJSONTyped(json: any, ignoreDiscriminator: boolean): EntityChangeActor;
60
+ export declare function EntityChangeActorToJSON(json: any): EntityChangeActor;
61
+ export declare function EntityChangeActorToJSONTyped(value?: EntityChangeActor | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,52 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * spaciv API
5
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@spaciv.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * @export
16
+ */
17
+ export const EntityChangeActorTypeEnum = {
18
+ User: 'user',
19
+ System: 'system',
20
+ Anonymous: 'anonymous',
21
+ Unknown: 'unknown'
22
+ };
23
+ /**
24
+ * Check if a given object implements the EntityChangeActor interface.
25
+ */
26
+ export function instanceOfEntityChangeActor(value) {
27
+ if (!('session' in value) || value['session'] === undefined)
28
+ return false;
29
+ if (!('type' in value) || value['type'] === undefined)
30
+ return false;
31
+ if (!('user' in value) || value['user'] === undefined)
32
+ return false;
33
+ return true;
34
+ }
35
+ export function EntityChangeActorFromJSON(json) {
36
+ return EntityChangeActorFromJSONTyped(json, false);
37
+ }
38
+ export function EntityChangeActorFromJSONTyped(json, ignoreDiscriminator) {
39
+ if (json == null) {
40
+ return json;
41
+ }
42
+ return Object.assign(Object.assign({}, json), { 'clientId': json['clientId'] == null ? undefined : json['clientId'], 'session': json['session'], 'type': json['type'], 'user': json['user'] });
43
+ }
44
+ export function EntityChangeActorToJSON(json) {
45
+ return EntityChangeActorToJSONTyped(json, false);
46
+ }
47
+ export function EntityChangeActorToJSONTyped(value, ignoreDiscriminator = false) {
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return Object.assign(Object.assign({}, value), { 'clientId': value['clientId'], 'session': value['session'], 'type': value['type'], 'user': value['user'] });
52
+ }
@@ -0,0 +1,84 @@
1
+ /**
2
+ * spaciv API
3
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@spaciv.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { EntityChangeActor } from './EntityChangeActor';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface EntityChangedEvent
17
+ */
18
+ export interface EntityChangedEvent {
19
+ [key: string]: any | any;
20
+ /**
21
+ *
22
+ * @type {number}
23
+ * @memberof EntityChangedEvent
24
+ */
25
+ account: number;
26
+ /**
27
+ *
28
+ * @type {EntityChangeActor}
29
+ * @memberof EntityChangedEvent
30
+ */
31
+ actor: EntityChangeActor;
32
+ /**
33
+ *
34
+ * @type {string}
35
+ * @memberof EntityChangedEvent
36
+ */
37
+ at: string;
38
+ /**
39
+ *
40
+ * @type {string}
41
+ * @memberof EntityChangedEvent
42
+ */
43
+ id: string;
44
+ /**
45
+ *
46
+ * @type {string}
47
+ * @memberof EntityChangedEvent
48
+ */
49
+ op: EntityChangedEventOpEnum;
50
+ /**
51
+ *
52
+ * @type {number}
53
+ * @memberof EntityChangedEvent
54
+ */
55
+ project?: number;
56
+ /**
57
+ *
58
+ * @type {string}
59
+ * @memberof EntityChangedEvent
60
+ */
61
+ type: string;
62
+ /**
63
+ *
64
+ * @type {string}
65
+ * @memberof EntityChangedEvent
66
+ */
67
+ version?: string;
68
+ }
69
+ /**
70
+ * @export
71
+ */
72
+ export declare const EntityChangedEventOpEnum: {
73
+ readonly Upsert: "upsert";
74
+ readonly Delete: "delete";
75
+ };
76
+ export type EntityChangedEventOpEnum = typeof EntityChangedEventOpEnum[keyof typeof EntityChangedEventOpEnum];
77
+ /**
78
+ * Check if a given object implements the EntityChangedEvent interface.
79
+ */
80
+ export declare function instanceOfEntityChangedEvent(value: object): value is EntityChangedEvent;
81
+ export declare function EntityChangedEventFromJSON(json: any): EntityChangedEvent;
82
+ export declare function EntityChangedEventFromJSONTyped(json: any, ignoreDiscriminator: boolean): EntityChangedEvent;
83
+ export declare function EntityChangedEventToJSON(json: any): EntityChangedEvent;
84
+ export declare function EntityChangedEventToJSONTyped(value?: EntityChangedEvent | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,57 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * spaciv API
5
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@spaciv.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { EntityChangeActorFromJSON, EntityChangeActorToJSON, } from './EntityChangeActor';
15
+ /**
16
+ * @export
17
+ */
18
+ export const EntityChangedEventOpEnum = {
19
+ Upsert: 'upsert',
20
+ Delete: 'delete'
21
+ };
22
+ /**
23
+ * Check if a given object implements the EntityChangedEvent interface.
24
+ */
25
+ export function instanceOfEntityChangedEvent(value) {
26
+ if (!('account' in value) || value['account'] === undefined)
27
+ return false;
28
+ if (!('actor' in value) || value['actor'] === undefined)
29
+ return false;
30
+ if (!('at' in value) || value['at'] === undefined)
31
+ return false;
32
+ if (!('id' in value) || value['id'] === undefined)
33
+ return false;
34
+ if (!('op' in value) || value['op'] === undefined)
35
+ return false;
36
+ if (!('type' in value) || value['type'] === undefined)
37
+ return false;
38
+ return true;
39
+ }
40
+ export function EntityChangedEventFromJSON(json) {
41
+ return EntityChangedEventFromJSONTyped(json, false);
42
+ }
43
+ export function EntityChangedEventFromJSONTyped(json, ignoreDiscriminator) {
44
+ if (json == null) {
45
+ return json;
46
+ }
47
+ return Object.assign(Object.assign({}, json), { 'account': json['account'], 'actor': EntityChangeActorFromJSON(json['actor']), 'at': json['at'], 'id': json['id'], 'op': json['op'], 'project': json['project'] == null ? undefined : json['project'], 'type': json['type'], 'version': json['version'] == null ? undefined : json['version'] });
48
+ }
49
+ export function EntityChangedEventToJSON(json) {
50
+ return EntityChangedEventToJSONTyped(json, false);
51
+ }
52
+ export function EntityChangedEventToJSONTyped(value, ignoreDiscriminator = false) {
53
+ if (value == null) {
54
+ return value;
55
+ }
56
+ return Object.assign(Object.assign({}, value), { 'account': value['account'], 'actor': EntityChangeActorToJSON(value['actor']), 'at': value['at'], 'id': value['id'], 'op': value['op'], 'project': value['project'], 'type': value['type'], 'version': value['version'] });
57
+ }
@@ -0,0 +1,92 @@
1
+ /**
2
+ * spaciv API
3
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@spaciv.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { EntityChangedEvent } from './EntityChangedEvent';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ServerMessage
17
+ */
18
+ export interface ServerMessage {
19
+ [key: string]: any | any;
20
+ /**
21
+ *
22
+ * @type {string}
23
+ * @memberof ServerMessage
24
+ */
25
+ code?: ServerMessageCodeEnum;
26
+ /**
27
+ *
28
+ * @type {Array<EntityChangedEvent>}
29
+ * @memberof ServerMessage
30
+ */
31
+ events?: Array<EntityChangedEvent>;
32
+ /**
33
+ *
34
+ * @type {string}
35
+ * @memberof ServerMessage
36
+ */
37
+ message?: string;
38
+ /**
39
+ *
40
+ * @type {string}
41
+ * @memberof ServerMessage
42
+ */
43
+ topic?: string;
44
+ /**
45
+ *
46
+ * @type {string}
47
+ * @memberof ServerMessage
48
+ */
49
+ type: ServerMessageTypeEnum;
50
+ /**
51
+ *
52
+ * @type {number}
53
+ * @memberof ServerMessage
54
+ */
55
+ v: ServerMessageVEnum;
56
+ }
57
+ /**
58
+ * @export
59
+ */
60
+ export declare const ServerMessageCodeEnum: {
61
+ readonly InvalidTopic: "invalid_topic";
62
+ readonly Forbidden: "forbidden";
63
+ readonly NotFound: "not_found";
64
+ readonly TooManySubscriptions: "too_many_subscriptions";
65
+ readonly Unavailable: "unavailable";
66
+ };
67
+ export type ServerMessageCodeEnum = typeof ServerMessageCodeEnum[keyof typeof ServerMessageCodeEnum];
68
+ /**
69
+ * @export
70
+ */
71
+ export declare const ServerMessageTypeEnum: {
72
+ readonly Changed: "changed";
73
+ readonly Subscribed: "subscribed";
74
+ readonly Resync: "resync";
75
+ readonly Error: "error";
76
+ };
77
+ export type ServerMessageTypeEnum = typeof ServerMessageTypeEnum[keyof typeof ServerMessageTypeEnum];
78
+ /**
79
+ * @export
80
+ */
81
+ export declare const ServerMessageVEnum: {
82
+ readonly NUMBER_1: 1;
83
+ };
84
+ export type ServerMessageVEnum = typeof ServerMessageVEnum[keyof typeof ServerMessageVEnum];
85
+ /**
86
+ * Check if a given object implements the ServerMessage interface.
87
+ */
88
+ export declare function instanceOfServerMessage(value: object): value is ServerMessage;
89
+ export declare function ServerMessageFromJSON(json: any): ServerMessage;
90
+ export declare function ServerMessageFromJSONTyped(json: any, ignoreDiscriminator: boolean): ServerMessage;
91
+ export declare function ServerMessageToJSON(json: any): ServerMessage;
92
+ export declare function ServerMessageToJSONTyped(value?: ServerMessage | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,67 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * spaciv API
5
+ * The spaciv API powers workplace planning: modelling how many people an organisation has, how they work, and how much space that requires. ## Getting started 1. Exchange credentials for an access token using one of the operations under **Authentication**. 2. Send that token on every subsequent request as `Authorization: Bearer <token>`. 3. Access tokens are short lived. Call `POST /v1/auth/refresh-token` to obtain a new one before the old one expires. ## Conventions Every operation is versioned under `/v1`. Collections are plural (`GET /v1/dashboards` lists, `POST /v1/dashboards` creates) and individual records live beneath them (`/v1/dashboards/{id}`). Singular paths such as `/v1/account`, `/v1/project` and `/v1/user` refer to the record the access token was issued for. Request and response bodies are JSON. Timestamps are RFC 3339. Identifiers are opaque strings unless documented otherwise, and collection operations return the records visible to the account the token was issued for. Failures return an [RFC 9457](https://www.rfc-editor.org/rfc/rfc9457) problem document with a `detail` field describing what went wrong.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@spaciv.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { EntityChangedEventFromJSON, EntityChangedEventToJSON, } from './EntityChangedEvent';
15
+ /**
16
+ * @export
17
+ */
18
+ export const ServerMessageCodeEnum = {
19
+ InvalidTopic: 'invalid_topic',
20
+ Forbidden: 'forbidden',
21
+ NotFound: 'not_found',
22
+ TooManySubscriptions: 'too_many_subscriptions',
23
+ Unavailable: 'unavailable'
24
+ };
25
+ /**
26
+ * @export
27
+ */
28
+ export const ServerMessageTypeEnum = {
29
+ Changed: 'changed',
30
+ Subscribed: 'subscribed',
31
+ Resync: 'resync',
32
+ Error: 'error'
33
+ };
34
+ /**
35
+ * @export
36
+ */
37
+ export const ServerMessageVEnum = {
38
+ NUMBER_1: 1
39
+ };
40
+ /**
41
+ * Check if a given object implements the ServerMessage interface.
42
+ */
43
+ export function instanceOfServerMessage(value) {
44
+ if (!('type' in value) || value['type'] === undefined)
45
+ return false;
46
+ if (!('v' in value) || value['v'] === undefined)
47
+ return false;
48
+ return true;
49
+ }
50
+ export function ServerMessageFromJSON(json) {
51
+ return ServerMessageFromJSONTyped(json, false);
52
+ }
53
+ export function ServerMessageFromJSONTyped(json, ignoreDiscriminator) {
54
+ if (json == null) {
55
+ return json;
56
+ }
57
+ return Object.assign(Object.assign({}, json), { 'code': json['code'] == null ? undefined : json['code'], 'events': json['events'] == null ? undefined : (json['events'].map(EntityChangedEventFromJSON)), 'message': json['message'] == null ? undefined : json['message'], 'topic': json['topic'] == null ? undefined : json['topic'], 'type': json['type'], 'v': json['v'] });
58
+ }
59
+ export function ServerMessageToJSON(json) {
60
+ return ServerMessageToJSONTyped(json, false);
61
+ }
62
+ export function ServerMessageToJSONTyped(value, ignoreDiscriminator = false) {
63
+ if (value == null) {
64
+ return value;
65
+ }
66
+ return Object.assign(Object.assign({}, value), { 'code': value['code'], 'events': value['events'] == null ? undefined : (value['events'].map(EntityChangedEventToJSON)), 'message': value['message'], 'topic': value['topic'], 'type': value['type'], 'v': value['v'] });
67
+ }
@@ -81,6 +81,7 @@ export * from './CalcTreeValue';
81
81
  export * from './CalcTypeSingleValue';
82
82
  export * from './ChangelogOption';
83
83
  export * from './ChangelogValueOption';
84
+ export * from './ClientMessage';
84
85
  export * from './ConfidentialityData';
85
86
  export * from './Contribution';
86
87
  export * from './ContributionChangelogBody';
@@ -166,6 +167,8 @@ export * from './DatasetDataOneOf2';
166
167
  export * from './DatasetModify';
167
168
  export * from './DatasetRes';
168
169
  export * from './DaysOffData';
170
+ export * from './EntityChangeActor';
171
+ export * from './EntityChangedEvent';
169
172
  export * from './EntryPatch';
170
173
  export * from './EntryPatchPropertiesValue';
171
174
  export * from './ErrorDetail';
@@ -319,6 +322,7 @@ export * from './ScriptUsageResBody';
319
322
  export * from './ScriptWebhookResBody';
320
323
  export * from './SendPasswordPutReqBody';
321
324
  export * from './SerializedEvent';
325
+ export * from './ServerMessage';
322
326
  export * from './SingleSelectChangelogData';
323
327
  export * from './SingleSelectContributionData';
324
328
  export * from './SingleSelectData';
@@ -83,6 +83,7 @@ export * from './CalcTreeValue';
83
83
  export * from './CalcTypeSingleValue';
84
84
  export * from './ChangelogOption';
85
85
  export * from './ChangelogValueOption';
86
+ export * from './ClientMessage';
86
87
  export * from './ConfidentialityData';
87
88
  export * from './Contribution';
88
89
  export * from './ContributionChangelogBody';
@@ -168,6 +169,8 @@ export * from './DatasetDataOneOf2';
168
169
  export * from './DatasetModify';
169
170
  export * from './DatasetRes';
170
171
  export * from './DaysOffData';
172
+ export * from './EntityChangeActor';
173
+ export * from './EntityChangedEvent';
171
174
  export * from './EntryPatch';
172
175
  export * from './EntryPatchPropertiesValue';
173
176
  export * from './ErrorDetail';
@@ -321,6 +324,7 @@ export * from './ScriptUsageResBody';
321
324
  export * from './ScriptWebhookResBody';
322
325
  export * from './SendPasswordPutReqBody';
323
326
  export * from './SerializedEvent';
327
+ export * from './ServerMessage';
324
328
  export * from './SingleSelectChangelogData';
325
329
  export * from './SingleSelectContributionData';
326
330
  export * from './SingleSelectData';