@spaciv/sdk 0.1.0 → 0.1.2

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.
Files changed (171) hide show
  1. package/.openapi-generator/FILES +26 -0
  2. package/README.md +2 -2
  3. package/dist/apis/AccountsApi.d.ts +24 -24
  4. package/dist/apis/AccountsApi.js +12 -12
  5. package/dist/apis/AssistantApi.d.ts +28 -1
  6. package/dist/apis/AssistantApi.js +39 -0
  7. package/dist/apis/AuditLogApi.d.ts +1 -1
  8. package/dist/apis/AuthenticationApi.d.ts +8 -8
  9. package/dist/apis/AuthenticationApi.js +4 -4
  10. package/dist/apis/ScriptsApi.d.ts +383 -0
  11. package/dist/apis/ScriptsApi.js +559 -0
  12. package/dist/apis/UsersApi.d.ts +4 -4
  13. package/dist/apis/UsersApi.js +2 -2
  14. package/dist/apis/index.d.ts +1 -0
  15. package/dist/apis/index.js +1 -0
  16. package/dist/esm/apis/AccountsApi.d.ts +24 -24
  17. package/dist/esm/apis/AccountsApi.js +12 -12
  18. package/dist/esm/apis/AssistantApi.d.ts +28 -1
  19. package/dist/esm/apis/AssistantApi.js +40 -1
  20. package/dist/esm/apis/AuditLogApi.d.ts +1 -1
  21. package/dist/esm/apis/AuthenticationApi.d.ts +8 -8
  22. package/dist/esm/apis/AuthenticationApi.js +4 -4
  23. package/dist/esm/apis/ScriptsApi.d.ts +383 -0
  24. package/dist/esm/apis/ScriptsApi.js +555 -0
  25. package/dist/esm/apis/UsersApi.d.ts +4 -4
  26. package/dist/esm/apis/UsersApi.js +2 -2
  27. package/dist/esm/apis/index.d.ts +1 -0
  28. package/dist/esm/apis/index.js +1 -0
  29. package/dist/esm/models/APIKey.d.ts +6 -0
  30. package/dist/esm/models/APIKey.js +2 -0
  31. package/dist/esm/models/AssistantTranscriptBody.d.ts +45 -0
  32. package/dist/esm/models/AssistantTranscriptBody.js +52 -0
  33. package/dist/esm/models/AssistantTranscriptMessage.d.ts +98 -0
  34. package/dist/esm/models/AssistantTranscriptMessage.js +90 -0
  35. package/dist/esm/models/AssistantTranscriptToolCall.d.ts +44 -0
  36. package/dist/esm/models/AssistantTranscriptToolCall.js +51 -0
  37. package/dist/esm/models/ScriptAuditEntry.d.ts +67 -0
  38. package/dist/esm/models/ScriptAuditEntry.js +63 -0
  39. package/dist/esm/models/ScriptAuditResBody.d.ts +39 -0
  40. package/dist/esm/models/ScriptAuditResBody.js +46 -0
  41. package/dist/esm/models/ScriptDetail.d.ts +161 -0
  42. package/dist/esm/models/ScriptDetail.js +122 -0
  43. package/dist/esm/models/ScriptExport.d.ts +174 -0
  44. package/dist/esm/models/ScriptExport.js +129 -0
  45. package/dist/esm/models/ScriptExportResBody.d.ts +39 -0
  46. package/dist/esm/models/ScriptExportResBody.js +48 -0
  47. package/dist/esm/models/ScriptExportRun.d.ts +92 -0
  48. package/dist/esm/models/ScriptExportRun.js +73 -0
  49. package/dist/esm/models/ScriptKey.d.ts +64 -0
  50. package/dist/esm/models/ScriptKey.js +58 -0
  51. package/dist/esm/models/ScriptListResBody.d.ts +33 -0
  52. package/dist/esm/models/ScriptListResBody.js +44 -0
  53. package/dist/esm/models/ScriptLogLine.d.ts +38 -0
  54. package/dist/esm/models/ScriptLogLine.js +47 -0
  55. package/dist/esm/models/ScriptPatchReqBody.d.ts +98 -0
  56. package/dist/esm/models/ScriptPatchReqBody.js +70 -0
  57. package/dist/esm/models/ScriptPostReqBody.d.ts +113 -0
  58. package/dist/esm/models/ScriptPostReqBody.js +82 -0
  59. package/dist/esm/models/ScriptRun.d.ts +86 -0
  60. package/dist/esm/models/ScriptRun.js +69 -0
  61. package/dist/esm/models/ScriptRunLogsResBody.d.ts +39 -0
  62. package/dist/esm/models/ScriptRunLogsResBody.js +48 -0
  63. package/dist/esm/models/ScriptRunsResBody.d.ts +39 -0
  64. package/dist/esm/models/ScriptRunsResBody.js +46 -0
  65. package/dist/esm/models/ScriptRuntime.d.ts +62 -0
  66. package/dist/esm/models/ScriptRuntime.js +51 -0
  67. package/dist/esm/models/ScriptSchedule.d.ts +38 -0
  68. package/dist/esm/models/ScriptSchedule.js +43 -0
  69. package/dist/esm/models/ScriptSchedulePreviewReqBody.d.ts +44 -0
  70. package/dist/esm/models/ScriptSchedulePreviewReqBody.js +45 -0
  71. package/dist/esm/models/ScriptSchedulePreviewResBody.d.ts +44 -0
  72. package/dist/esm/models/ScriptSchedulePreviewResBody.js +49 -0
  73. package/dist/esm/models/ScriptSecretsReqBody.d.ts +40 -0
  74. package/dist/esm/models/ScriptSecretsReqBody.js +43 -0
  75. package/dist/esm/models/ScriptSecretsResBody.d.ts +134 -0
  76. package/dist/esm/models/ScriptSecretsResBody.js +111 -0
  77. package/dist/esm/models/ScriptSummary.d.ts +128 -0
  78. package/dist/esm/models/ScriptSummary.js +107 -0
  79. package/dist/esm/models/ScriptWebhookResBody.d.ts +32 -0
  80. package/dist/esm/models/ScriptWebhookResBody.js +43 -0
  81. package/dist/esm/models/index.d.ts +25 -0
  82. package/dist/esm/models/index.js +25 -0
  83. package/dist/models/APIKey.d.ts +6 -0
  84. package/dist/models/APIKey.js +2 -0
  85. package/dist/models/AssistantTranscriptBody.d.ts +45 -0
  86. package/dist/models/AssistantTranscriptBody.js +59 -0
  87. package/dist/models/AssistantTranscriptMessage.d.ts +98 -0
  88. package/dist/models/AssistantTranscriptMessage.js +98 -0
  89. package/dist/models/AssistantTranscriptToolCall.d.ts +44 -0
  90. package/dist/models/AssistantTranscriptToolCall.js +58 -0
  91. package/dist/models/ScriptAuditEntry.d.ts +67 -0
  92. package/dist/models/ScriptAuditEntry.js +71 -0
  93. package/dist/models/ScriptAuditResBody.d.ts +39 -0
  94. package/dist/models/ScriptAuditResBody.js +53 -0
  95. package/dist/models/ScriptDetail.d.ts +161 -0
  96. package/dist/models/ScriptDetail.js +130 -0
  97. package/dist/models/ScriptExport.d.ts +174 -0
  98. package/dist/models/ScriptExport.js +137 -0
  99. package/dist/models/ScriptExportResBody.d.ts +39 -0
  100. package/dist/models/ScriptExportResBody.js +55 -0
  101. package/dist/models/ScriptExportRun.d.ts +92 -0
  102. package/dist/models/ScriptExportRun.js +80 -0
  103. package/dist/models/ScriptKey.d.ts +64 -0
  104. package/dist/models/ScriptKey.js +66 -0
  105. package/dist/models/ScriptListResBody.d.ts +33 -0
  106. package/dist/models/ScriptListResBody.js +51 -0
  107. package/dist/models/ScriptLogLine.d.ts +38 -0
  108. package/dist/models/ScriptLogLine.js +54 -0
  109. package/dist/models/ScriptPatchReqBody.d.ts +98 -0
  110. package/dist/models/ScriptPatchReqBody.js +78 -0
  111. package/dist/models/ScriptPostReqBody.d.ts +113 -0
  112. package/dist/models/ScriptPostReqBody.js +90 -0
  113. package/dist/models/ScriptRun.d.ts +86 -0
  114. package/dist/models/ScriptRun.js +76 -0
  115. package/dist/models/ScriptRunLogsResBody.d.ts +39 -0
  116. package/dist/models/ScriptRunLogsResBody.js +55 -0
  117. package/dist/models/ScriptRunsResBody.d.ts +39 -0
  118. package/dist/models/ScriptRunsResBody.js +53 -0
  119. package/dist/models/ScriptRuntime.d.ts +62 -0
  120. package/dist/models/ScriptRuntime.js +58 -0
  121. package/dist/models/ScriptSchedule.d.ts +38 -0
  122. package/dist/models/ScriptSchedule.js +50 -0
  123. package/dist/models/ScriptSchedulePreviewReqBody.d.ts +44 -0
  124. package/dist/models/ScriptSchedulePreviewReqBody.js +52 -0
  125. package/dist/models/ScriptSchedulePreviewResBody.d.ts +44 -0
  126. package/dist/models/ScriptSchedulePreviewResBody.js +56 -0
  127. package/dist/models/ScriptSecretsReqBody.d.ts +40 -0
  128. package/dist/models/ScriptSecretsReqBody.js +50 -0
  129. package/dist/models/ScriptSecretsResBody.d.ts +134 -0
  130. package/dist/models/ScriptSecretsResBody.js +119 -0
  131. package/dist/models/ScriptSummary.d.ts +128 -0
  132. package/dist/models/ScriptSummary.js +115 -0
  133. package/dist/models/ScriptWebhookResBody.d.ts +32 -0
  134. package/dist/models/ScriptWebhookResBody.js +50 -0
  135. package/dist/models/index.d.ts +25 -0
  136. package/dist/models/index.js +25 -0
  137. package/package.json +1 -1
  138. package/src/apis/AccountsApi.ts +24 -24
  139. package/src/apis/AssistantApi.ts +70 -0
  140. package/src/apis/AuditLogApi.ts +1 -1
  141. package/src/apis/AuthenticationApi.ts +8 -8
  142. package/src/apis/ScriptsApi.ts +984 -0
  143. package/src/apis/UsersApi.ts +4 -4
  144. package/src/apis/index.ts +1 -0
  145. package/src/models/APIKey.ts +8 -0
  146. package/src/models/AssistantTranscriptBody.ts +92 -0
  147. package/src/models/AssistantTranscriptMessage.ts +175 -0
  148. package/src/models/AssistantTranscriptToolCall.ts +84 -0
  149. package/src/models/ScriptAuditEntry.ts +112 -0
  150. package/src/models/ScriptAuditResBody.ts +82 -0
  151. package/src/models/ScriptDetail.ts +265 -0
  152. package/src/models/ScriptExport.ts +289 -0
  153. package/src/models/ScriptExportResBody.ts +83 -0
  154. package/src/models/ScriptExportRun.ts +151 -0
  155. package/src/models/ScriptKey.ts +109 -0
  156. package/src/models/ScriptListResBody.ts +74 -0
  157. package/src/models/ScriptLogLine.ts +75 -0
  158. package/src/models/ScriptPatchReqBody.ts +158 -0
  159. package/src/models/ScriptPostReqBody.ts +176 -0
  160. package/src/models/ScriptRun.ts +142 -0
  161. package/src/models/ScriptRunLogsResBody.ts +83 -0
  162. package/src/models/ScriptRunsResBody.ts +82 -0
  163. package/src/models/ScriptRuntime.ts +105 -0
  164. package/src/models/ScriptSchedule.ts +73 -0
  165. package/src/models/ScriptSchedulePreviewReqBody.ts +81 -0
  166. package/src/models/ScriptSchedulePreviewResBody.ts +83 -0
  167. package/src/models/ScriptSecretsReqBody.ts +73 -0
  168. package/src/models/ScriptSecretsResBody.ts +225 -0
  169. package/src/models/ScriptSummary.ts +216 -0
  170. package/src/models/ScriptWebhookResBody.ts +66 -0
  171. package/src/models/index.ts +25 -0
@@ -0,0 +1,98 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * spaciv API
6
+ * 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.
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: support@spaciv.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.AssistantTranscriptMessageRoleEnum = void 0;
17
+ exports.instanceOfAssistantTranscriptMessage = instanceOfAssistantTranscriptMessage;
18
+ exports.AssistantTranscriptMessageFromJSON = AssistantTranscriptMessageFromJSON;
19
+ exports.AssistantTranscriptMessageFromJSONTyped = AssistantTranscriptMessageFromJSONTyped;
20
+ exports.AssistantTranscriptMessageToJSON = AssistantTranscriptMessageToJSON;
21
+ exports.AssistantTranscriptMessageToJSONTyped = AssistantTranscriptMessageToJSONTyped;
22
+ const AssistantTranscriptToolCall_1 = require("./AssistantTranscriptToolCall");
23
+ const AssistantChatPollAttachment_1 = require("./AssistantChatPollAttachment");
24
+ /**
25
+ * @export
26
+ */
27
+ exports.AssistantTranscriptMessageRoleEnum = {
28
+ User: 'user',
29
+ Assistant: 'assistant',
30
+ Tool: 'tool',
31
+ Notice: 'notice'
32
+ };
33
+ /**
34
+ * Check if a given object implements the AssistantTranscriptMessage interface.
35
+ */
36
+ function instanceOfAssistantTranscriptMessage(value) {
37
+ if (!('attachments' in value) || value['attachments'] === undefined)
38
+ return false;
39
+ if (!('createdAt' in value) || value['createdAt'] === undefined)
40
+ return false;
41
+ if (!('failed' in value) || value['failed'] === undefined)
42
+ return false;
43
+ if (!('id' in value) || value['id'] === undefined)
44
+ return false;
45
+ if (!('reason' in value) || value['reason'] === undefined)
46
+ return false;
47
+ if (!('requestId' in value) || value['requestId'] === undefined)
48
+ return false;
49
+ if (!('role' in value) || value['role'] === undefined)
50
+ return false;
51
+ if (!('text' in value) || value['text'] === undefined)
52
+ return false;
53
+ if (!('toolCallId' in value) || value['toolCallId'] === undefined)
54
+ return false;
55
+ if (!('toolCalls' in value) || value['toolCalls'] === undefined)
56
+ return false;
57
+ return true;
58
+ }
59
+ function AssistantTranscriptMessageFromJSON(json) {
60
+ return AssistantTranscriptMessageFromJSONTyped(json, false);
61
+ }
62
+ function AssistantTranscriptMessageFromJSONTyped(json, ignoreDiscriminator) {
63
+ if (json == null) {
64
+ return json;
65
+ }
66
+ return {
67
+ 'attachments': (json['attachments'].map(AssistantChatPollAttachment_1.AssistantChatPollAttachmentFromJSON)),
68
+ 'createdAt': json['createdAt'],
69
+ 'failed': json['failed'],
70
+ 'id': json['id'],
71
+ 'reason': json['reason'],
72
+ 'requestId': json['requestId'],
73
+ 'role': json['role'],
74
+ 'text': json['text'],
75
+ 'toolCallId': json['toolCallId'],
76
+ 'toolCalls': (json['toolCalls'].map(AssistantTranscriptToolCall_1.AssistantTranscriptToolCallFromJSON)),
77
+ };
78
+ }
79
+ function AssistantTranscriptMessageToJSON(json) {
80
+ return AssistantTranscriptMessageToJSONTyped(json, false);
81
+ }
82
+ function AssistantTranscriptMessageToJSONTyped(value, ignoreDiscriminator = false) {
83
+ if (value == null) {
84
+ return value;
85
+ }
86
+ return {
87
+ 'attachments': (value['attachments'].map(AssistantChatPollAttachment_1.AssistantChatPollAttachmentToJSON)),
88
+ 'createdAt': value['createdAt'],
89
+ 'failed': value['failed'],
90
+ 'id': value['id'],
91
+ 'reason': value['reason'],
92
+ 'requestId': value['requestId'],
93
+ 'role': value['role'],
94
+ 'text': value['text'],
95
+ 'toolCallId': value['toolCallId'],
96
+ 'toolCalls': (value['toolCalls'].map(AssistantTranscriptToolCall_1.AssistantTranscriptToolCallToJSON)),
97
+ };
98
+ }
@@ -0,0 +1,44 @@
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 AssistantTranscriptToolCall
16
+ */
17
+ export interface AssistantTranscriptToolCall {
18
+ /**
19
+ * The call's JSON arguments.
20
+ * @type {string}
21
+ * @memberof AssistantTranscriptToolCall
22
+ */
23
+ arguments: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof AssistantTranscriptToolCall
28
+ */
29
+ id: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof AssistantTranscriptToolCall
34
+ */
35
+ name: string;
36
+ }
37
+ /**
38
+ * Check if a given object implements the AssistantTranscriptToolCall interface.
39
+ */
40
+ export declare function instanceOfAssistantTranscriptToolCall(value: object): value is AssistantTranscriptToolCall;
41
+ export declare function AssistantTranscriptToolCallFromJSON(json: any): AssistantTranscriptToolCall;
42
+ export declare function AssistantTranscriptToolCallFromJSONTyped(json: any, ignoreDiscriminator: boolean): AssistantTranscriptToolCall;
43
+ export declare function AssistantTranscriptToolCallToJSON(json: any): AssistantTranscriptToolCall;
44
+ export declare function AssistantTranscriptToolCallToJSONTyped(value?: AssistantTranscriptToolCall | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,58 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * spaciv API
6
+ * 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.
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: support@spaciv.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfAssistantTranscriptToolCall = instanceOfAssistantTranscriptToolCall;
17
+ exports.AssistantTranscriptToolCallFromJSON = AssistantTranscriptToolCallFromJSON;
18
+ exports.AssistantTranscriptToolCallFromJSONTyped = AssistantTranscriptToolCallFromJSONTyped;
19
+ exports.AssistantTranscriptToolCallToJSON = AssistantTranscriptToolCallToJSON;
20
+ exports.AssistantTranscriptToolCallToJSONTyped = AssistantTranscriptToolCallToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the AssistantTranscriptToolCall interface.
23
+ */
24
+ function instanceOfAssistantTranscriptToolCall(value) {
25
+ if (!('arguments' in value) || value['arguments'] === undefined)
26
+ return false;
27
+ if (!('id' in value) || value['id'] === undefined)
28
+ return false;
29
+ if (!('name' in value) || value['name'] === undefined)
30
+ return false;
31
+ return true;
32
+ }
33
+ function AssistantTranscriptToolCallFromJSON(json) {
34
+ return AssistantTranscriptToolCallFromJSONTyped(json, false);
35
+ }
36
+ function AssistantTranscriptToolCallFromJSONTyped(json, ignoreDiscriminator) {
37
+ if (json == null) {
38
+ return json;
39
+ }
40
+ return {
41
+ 'arguments': json['arguments'],
42
+ 'id': json['id'],
43
+ 'name': json['name'],
44
+ };
45
+ }
46
+ function AssistantTranscriptToolCallToJSON(json) {
47
+ return AssistantTranscriptToolCallToJSONTyped(json, false);
48
+ }
49
+ function AssistantTranscriptToolCallToJSONTyped(value, ignoreDiscriminator = false) {
50
+ if (value == null) {
51
+ return value;
52
+ }
53
+ return {
54
+ 'arguments': value['arguments'],
55
+ 'id': value['id'],
56
+ 'name': value['name'],
57
+ };
58
+ }
@@ -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 ScriptAuditEntry
16
+ */
17
+ export interface ScriptAuditEntry {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof ScriptAuditEntry
22
+ */
23
+ actorType: ScriptAuditEntryActorTypeEnum;
24
+ /**
25
+ * What changed, for example created, updated, api-key-rotated or needs-reauthorisation.
26
+ * @type {string}
27
+ * @memberof ScriptAuditEntry
28
+ */
29
+ kind: string;
30
+ /**
31
+ *
32
+ * @type {Date}
33
+ * @memberof ScriptAuditEntry
34
+ */
35
+ modifiedAt: Date;
36
+ /**
37
+ * User who made the change, when actorType is user.
38
+ * @type {number}
39
+ * @memberof ScriptAuditEntry
40
+ */
41
+ modifiedBy?: number;
42
+ /**
43
+ *
44
+ * @type {{ [key: string]: string; }}
45
+ * @memberof ScriptAuditEntry
46
+ */
47
+ params?: {
48
+ [key: string]: string;
49
+ };
50
+ }
51
+ /**
52
+ * @export
53
+ */
54
+ export declare const ScriptAuditEntryActorTypeEnum: {
55
+ readonly User: "user";
56
+ readonly System: "system";
57
+ readonly Anonymous: "anonymous";
58
+ };
59
+ export type ScriptAuditEntryActorTypeEnum = typeof ScriptAuditEntryActorTypeEnum[keyof typeof ScriptAuditEntryActorTypeEnum];
60
+ /**
61
+ * Check if a given object implements the ScriptAuditEntry interface.
62
+ */
63
+ export declare function instanceOfScriptAuditEntry(value: object): value is ScriptAuditEntry;
64
+ export declare function ScriptAuditEntryFromJSON(json: any): ScriptAuditEntry;
65
+ export declare function ScriptAuditEntryFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScriptAuditEntry;
66
+ export declare function ScriptAuditEntryToJSON(json: any): ScriptAuditEntry;
67
+ export declare function ScriptAuditEntryToJSONTyped(value?: ScriptAuditEntry | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,71 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * spaciv API
6
+ * 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.
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: support@spaciv.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.ScriptAuditEntryActorTypeEnum = void 0;
17
+ exports.instanceOfScriptAuditEntry = instanceOfScriptAuditEntry;
18
+ exports.ScriptAuditEntryFromJSON = ScriptAuditEntryFromJSON;
19
+ exports.ScriptAuditEntryFromJSONTyped = ScriptAuditEntryFromJSONTyped;
20
+ exports.ScriptAuditEntryToJSON = ScriptAuditEntryToJSON;
21
+ exports.ScriptAuditEntryToJSONTyped = ScriptAuditEntryToJSONTyped;
22
+ /**
23
+ * @export
24
+ */
25
+ exports.ScriptAuditEntryActorTypeEnum = {
26
+ User: 'user',
27
+ System: 'system',
28
+ Anonymous: 'anonymous'
29
+ };
30
+ /**
31
+ * Check if a given object implements the ScriptAuditEntry interface.
32
+ */
33
+ function instanceOfScriptAuditEntry(value) {
34
+ if (!('actorType' in value) || value['actorType'] === undefined)
35
+ return false;
36
+ if (!('kind' in value) || value['kind'] === undefined)
37
+ return false;
38
+ if (!('modifiedAt' in value) || value['modifiedAt'] === undefined)
39
+ return false;
40
+ return true;
41
+ }
42
+ function ScriptAuditEntryFromJSON(json) {
43
+ return ScriptAuditEntryFromJSONTyped(json, false);
44
+ }
45
+ function ScriptAuditEntryFromJSONTyped(json, ignoreDiscriminator) {
46
+ if (json == null) {
47
+ return json;
48
+ }
49
+ return {
50
+ 'actorType': json['actorType'],
51
+ 'kind': json['kind'],
52
+ 'modifiedAt': (new Date(json['modifiedAt'])),
53
+ 'modifiedBy': json['modifiedBy'] == null ? undefined : json['modifiedBy'],
54
+ 'params': json['params'] == null ? undefined : json['params'],
55
+ };
56
+ }
57
+ function ScriptAuditEntryToJSON(json) {
58
+ return ScriptAuditEntryToJSONTyped(json, false);
59
+ }
60
+ function ScriptAuditEntryToJSONTyped(value, ignoreDiscriminator = false) {
61
+ if (value == null) {
62
+ return value;
63
+ }
64
+ return {
65
+ 'actorType': value['actorType'],
66
+ 'kind': value['kind'],
67
+ 'modifiedAt': ((value['modifiedAt']).toISOString()),
68
+ 'modifiedBy': value['modifiedBy'],
69
+ 'params': value['params'],
70
+ };
71
+ }
@@ -0,0 +1,39 @@
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 { ScriptAuditEntry } from './ScriptAuditEntry';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface ScriptAuditResBody
17
+ */
18
+ export interface ScriptAuditResBody {
19
+ /**
20
+ *
21
+ * @type {Array<ScriptAuditEntry>}
22
+ * @memberof ScriptAuditResBody
23
+ */
24
+ entries: Array<ScriptAuditEntry>;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof ScriptAuditResBody
29
+ */
30
+ nextCursor?: string;
31
+ }
32
+ /**
33
+ * Check if a given object implements the ScriptAuditResBody interface.
34
+ */
35
+ export declare function instanceOfScriptAuditResBody(value: object): value is ScriptAuditResBody;
36
+ export declare function ScriptAuditResBodyFromJSON(json: any): ScriptAuditResBody;
37
+ export declare function ScriptAuditResBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScriptAuditResBody;
38
+ export declare function ScriptAuditResBodyToJSON(json: any): ScriptAuditResBody;
39
+ export declare function ScriptAuditResBodyToJSONTyped(value?: ScriptAuditResBody | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * spaciv API
6
+ * 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.
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ * Contact: support@spaciv.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfScriptAuditResBody = instanceOfScriptAuditResBody;
17
+ exports.ScriptAuditResBodyFromJSON = ScriptAuditResBodyFromJSON;
18
+ exports.ScriptAuditResBodyFromJSONTyped = ScriptAuditResBodyFromJSONTyped;
19
+ exports.ScriptAuditResBodyToJSON = ScriptAuditResBodyToJSON;
20
+ exports.ScriptAuditResBodyToJSONTyped = ScriptAuditResBodyToJSONTyped;
21
+ const ScriptAuditEntry_1 = require("./ScriptAuditEntry");
22
+ /**
23
+ * Check if a given object implements the ScriptAuditResBody interface.
24
+ */
25
+ function instanceOfScriptAuditResBody(value) {
26
+ if (!('entries' in value) || value['entries'] === undefined)
27
+ return false;
28
+ return true;
29
+ }
30
+ function ScriptAuditResBodyFromJSON(json) {
31
+ return ScriptAuditResBodyFromJSONTyped(json, false);
32
+ }
33
+ function ScriptAuditResBodyFromJSONTyped(json, ignoreDiscriminator) {
34
+ if (json == null) {
35
+ return json;
36
+ }
37
+ return {
38
+ 'entries': (json['entries'].map(ScriptAuditEntry_1.ScriptAuditEntryFromJSON)),
39
+ 'nextCursor': json['nextCursor'] == null ? undefined : json['nextCursor'],
40
+ };
41
+ }
42
+ function ScriptAuditResBodyToJSON(json) {
43
+ return ScriptAuditResBodyToJSONTyped(json, false);
44
+ }
45
+ function ScriptAuditResBodyToJSONTyped(value, ignoreDiscriminator = false) {
46
+ if (value == null) {
47
+ return value;
48
+ }
49
+ return {
50
+ 'entries': (value['entries'].map(ScriptAuditEntry_1.ScriptAuditEntryToJSON)),
51
+ 'nextCursor': value['nextCursor'],
52
+ };
53
+ }
@@ -0,0 +1,161 @@
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 { ScriptKey } from './ScriptKey';
13
+ import type { ScriptSchedule } from './ScriptSchedule';
14
+ import type { ScriptRuntime } from './ScriptRuntime';
15
+ /**
16
+ *
17
+ * @export
18
+ * @interface ScriptDetail
19
+ */
20
+ export interface ScriptDetail {
21
+ /**
22
+ *
23
+ * @type {Date}
24
+ * @memberof ScriptDetail
25
+ */
26
+ createdAt: Date;
27
+ /**
28
+ *
29
+ * @type {number}
30
+ * @memberof ScriptDetail
31
+ */
32
+ createdBy: number;
33
+ /**
34
+ *
35
+ * @type {string}
36
+ * @memberof ScriptDetail
37
+ */
38
+ description?: string;
39
+ /**
40
+ *
41
+ * @type {boolean}
42
+ * @memberof ScriptDetail
43
+ */
44
+ enabled: boolean;
45
+ /**
46
+ * Source files keyed by path.
47
+ * @type {{ [key: string]: string; }}
48
+ * @memberof ScriptDetail
49
+ */
50
+ files: {
51
+ [key: string]: string;
52
+ };
53
+ /**
54
+ *
55
+ * @type {string}
56
+ * @memberof ScriptDetail
57
+ */
58
+ id: string;
59
+ /**
60
+ *
61
+ * @type {ScriptKey}
62
+ * @memberof ScriptDetail
63
+ */
64
+ key: ScriptKey;
65
+ /**
66
+ *
67
+ * @type {string}
68
+ * @memberof ScriptDetail
69
+ */
70
+ language: ScriptDetailLanguageEnum;
71
+ /**
72
+ * Dependency manifest: requirements.txt for Python, go.mod for Go, package.json for JavaScript.
73
+ * @type {string}
74
+ * @memberof ScriptDetail
75
+ */
76
+ manifest?: string;
77
+ /**
78
+ *
79
+ * @type {string}
80
+ * @memberof ScriptDetail
81
+ */
82
+ name: string;
83
+ /**
84
+ * Project the script's API key is scoped to. Absent when it acts across the account.
85
+ * @type {number}
86
+ * @memberof ScriptDetail
87
+ */
88
+ project?: number;
89
+ /**
90
+ * Pass back when updating, so a concurrent change is reported rather than overwritten.
91
+ * @type {number}
92
+ * @memberof ScriptDetail
93
+ */
94
+ revision: number;
95
+ /**
96
+ * Live state from the runner; absent if the runner could not be reached.
97
+ * @type {ScriptRuntime}
98
+ * @memberof ScriptDetail
99
+ */
100
+ runtime?: ScriptRuntime;
101
+ /**
102
+ *
103
+ * @type {ScriptSchedule}
104
+ * @memberof ScriptDetail
105
+ */
106
+ schedule: ScriptSchedule;
107
+ /**
108
+ * Names of the secrets set on the script. Values are never returned.
109
+ * @type {Array<string>}
110
+ * @memberof ScriptDetail
111
+ */
112
+ secretNames: Array<string>;
113
+ /**
114
+ * The handler signature the script implements.
115
+ * @type {string}
116
+ * @memberof ScriptDetail
117
+ */
118
+ type: ScriptDetailTypeEnum;
119
+ /**
120
+ *
121
+ * @type {Date}
122
+ * @memberof ScriptDetail
123
+ */
124
+ updatedAt: Date;
125
+ /**
126
+ *
127
+ * @type {boolean}
128
+ * @memberof ScriptDetail
129
+ */
130
+ webhook: boolean;
131
+ /**
132
+ * Returned only when a webhook URL is first issued; it cannot be retrieved later.
133
+ * @type {string}
134
+ * @memberof ScriptDetail
135
+ */
136
+ webhookUrl?: string;
137
+ }
138
+ /**
139
+ * @export
140
+ */
141
+ export declare const ScriptDetailLanguageEnum: {
142
+ readonly Python: "python";
143
+ readonly Go: "go";
144
+ readonly Javascript: "javascript";
145
+ };
146
+ export type ScriptDetailLanguageEnum = typeof ScriptDetailLanguageEnum[keyof typeof ScriptDetailLanguageEnum];
147
+ /**
148
+ * @export
149
+ */
150
+ export declare const ScriptDetailTypeEnum: {
151
+ readonly Integration: "integration";
152
+ };
153
+ export type ScriptDetailTypeEnum = typeof ScriptDetailTypeEnum[keyof typeof ScriptDetailTypeEnum];
154
+ /**
155
+ * Check if a given object implements the ScriptDetail interface.
156
+ */
157
+ export declare function instanceOfScriptDetail(value: object): value is ScriptDetail;
158
+ export declare function ScriptDetailFromJSON(json: any): ScriptDetail;
159
+ export declare function ScriptDetailFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScriptDetail;
160
+ export declare function ScriptDetailToJSON(json: any): ScriptDetail;
161
+ export declare function ScriptDetailToJSONTyped(value?: ScriptDetail | null, ignoreDiscriminator?: boolean): any;