zkcloudworker 0.7.4 → 0.7.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (152) hide show
  1. package/lib/ts/src/cloud/index.d.ts +4 -5
  2. package/lib/ts/src/cloud/index.js +4 -5
  3. package/lib/ts/src/cloud/utils/index.d.ts +3 -0
  4. package/lib/ts/src/cloud/utils/index.js +19 -0
  5. package/lib/ts/src/cloud/worker/index.d.ts +3 -0
  6. package/lib/ts/src/cloud/worker/index.js +19 -0
  7. package/lib/ts/src/index.d.ts +1 -4
  8. package/lib/ts/src/index.js +1 -4
  9. package/lib/ts/src/{api → mina/api}/api.d.ts +2 -2
  10. package/lib/ts/src/{api → mina/api}/api.js +3 -3
  11. package/lib/ts/src/mina/index.d.ts +4 -0
  12. package/lib/ts/src/mina/index.js +20 -0
  13. package/lib/{web/src/cloud → ts/src/mina/local}/local.d.ts +5 -19
  14. package/lib/ts/src/{cloud → mina/local}/local.js +8 -22
  15. package/lib/ts/src/{utils → mina/utils}/fee.js +1 -1
  16. package/lib/ts/src/{utils → mina/utils}/fetch.js +3 -3
  17. package/lib/ts/src/{utils → mina/utils}/index.d.ts +0 -2
  18. package/lib/ts/src/{utils → mina/utils}/index.js +0 -2
  19. package/lib/ts/src/{utils → mina/utils}/mina.d.ts +1 -1
  20. package/lib/ts/src/{utils → mina/utils}/mina.js +3 -3
  21. package/lib/ts/tsconfig.tsbuildinfo +1 -1
  22. package/lib/web/src/cloud/config.js.map +1 -0
  23. package/lib/web/src/cloud/index.d.ts +4 -5
  24. package/lib/web/src/cloud/index.js +4 -5
  25. package/lib/web/src/cloud/index.js.map +1 -1
  26. package/lib/web/src/cloud/networks.js.map +1 -0
  27. package/lib/web/src/cloud/utils/files.js.map +1 -0
  28. package/lib/web/src/cloud/utils/graphql.js.map +1 -0
  29. package/lib/web/src/cloud/utils/index.d.ts +3 -0
  30. package/lib/web/src/cloud/utils/index.js +4 -0
  31. package/lib/web/src/cloud/utils/index.js.map +1 -0
  32. package/lib/web/src/cloud/utils/utils.js.map +1 -0
  33. package/lib/web/src/cloud/worker/cloud.js.map +1 -0
  34. package/lib/web/src/cloud/worker/index.d.ts +3 -0
  35. package/lib/web/src/cloud/worker/index.js +4 -0
  36. package/lib/web/src/cloud/worker/index.js.map +1 -0
  37. package/lib/web/src/cloud/{job.js.map → worker/job.js.map} +1 -1
  38. package/lib/web/src/cloud/{task.js.map → worker/task.js.map} +1 -1
  39. package/lib/web/src/index.d.ts +1 -4
  40. package/lib/web/src/index.js +1 -4
  41. package/lib/web/src/index.js.map +1 -1
  42. package/lib/web/src/{api → mina/api}/api.d.ts +2 -2
  43. package/lib/web/src/{api → mina/api}/api.js +3 -3
  44. package/lib/web/src/mina/api/api.js.map +1 -0
  45. package/lib/web/src/mina/encryption/client.js.map +1 -0
  46. package/lib/web/src/mina/encryption/connections.js.map +1 -0
  47. package/lib/web/src/mina/encryption/encryption.js.map +1 -0
  48. package/lib/web/src/mina/encryption/index.js.map +1 -0
  49. package/lib/web/src/mina/encryption/messages.js.map +1 -0
  50. package/lib/web/src/mina/index.d.ts +4 -0
  51. package/lib/web/src/mina/index.js +5 -0
  52. package/lib/web/src/mina/index.js.map +1 -0
  53. package/lib/{ts/src/cloud → web/src/mina/local}/local.d.ts +5 -19
  54. package/lib/web/src/{cloud → mina/local}/local.js +3 -17
  55. package/lib/web/src/mina/local/local.js.map +1 -0
  56. package/lib/web/src/mina/utils/base64.js.map +1 -0
  57. package/lib/web/src/{utils → mina/utils}/fee.js +1 -1
  58. package/lib/web/src/mina/utils/fee.js.map +1 -0
  59. package/lib/web/src/{utils → mina/utils}/fetch.js +1 -1
  60. package/lib/web/src/mina/utils/fetch.js.map +1 -0
  61. package/lib/web/src/mina/utils/fields.js.map +1 -0
  62. package/lib/web/src/{utils → mina/utils}/index.d.ts +0 -2
  63. package/lib/web/src/{utils → mina/utils}/index.js +0 -2
  64. package/lib/web/src/mina/utils/index.js.map +1 -0
  65. package/lib/web/src/{utils → mina/utils}/mina.d.ts +1 -1
  66. package/lib/web/src/{utils → mina/utils}/mina.js +1 -1
  67. package/lib/web/src/mina/utils/mina.js.map +1 -0
  68. package/lib/web/tsconfig.web.tsbuildinfo +1 -1
  69. package/package.json +1 -1
  70. package/lib/web/src/api/api.js.map +0 -1
  71. package/lib/web/src/cloud/cloud.js.map +0 -1
  72. package/lib/web/src/cloud/files.js.map +0 -1
  73. package/lib/web/src/cloud/local.js.map +0 -1
  74. package/lib/web/src/config.js.map +0 -1
  75. package/lib/web/src/encryption/client.js.map +0 -1
  76. package/lib/web/src/encryption/connections.js.map +0 -1
  77. package/lib/web/src/encryption/encryption.js.map +0 -1
  78. package/lib/web/src/encryption/index.js.map +0 -1
  79. package/lib/web/src/encryption/messages.js.map +0 -1
  80. package/lib/web/src/networks.js.map +0 -1
  81. package/lib/web/src/utils/base64.js.map +0 -1
  82. package/lib/web/src/utils/fee.js.map +0 -1
  83. package/lib/web/src/utils/fetch.js.map +0 -1
  84. package/lib/web/src/utils/fields.js.map +0 -1
  85. package/lib/web/src/utils/graphql.js.map +0 -1
  86. package/lib/web/src/utils/index.js.map +0 -1
  87. package/lib/web/src/utils/mina.js.map +0 -1
  88. package/lib/web/src/utils/utils.js.map +0 -1
  89. /package/lib/ts/src/{config.d.ts → cloud/config.d.ts} +0 -0
  90. /package/lib/ts/src/{config.js → cloud/config.js} +0 -0
  91. /package/lib/ts/src/{networks.d.ts → cloud/networks.d.ts} +0 -0
  92. /package/lib/ts/src/{networks.js → cloud/networks.js} +0 -0
  93. /package/lib/ts/src/cloud/{files.d.ts → utils/files.d.ts} +0 -0
  94. /package/lib/ts/src/cloud/{files.js → utils/files.js} +0 -0
  95. /package/lib/ts/src/{utils → cloud/utils}/graphql.d.ts +0 -0
  96. /package/lib/ts/src/{utils → cloud/utils}/graphql.js +0 -0
  97. /package/lib/ts/src/{utils → cloud/utils}/utils.d.ts +0 -0
  98. /package/lib/ts/src/{utils → cloud/utils}/utils.js +0 -0
  99. /package/lib/ts/src/cloud/{cloud.d.ts → worker/cloud.d.ts} +0 -0
  100. /package/lib/ts/src/cloud/{cloud.js → worker/cloud.js} +0 -0
  101. /package/lib/ts/src/cloud/{job.d.ts → worker/job.d.ts} +0 -0
  102. /package/lib/ts/src/cloud/{job.js → worker/job.js} +0 -0
  103. /package/lib/ts/src/cloud/{task.d.ts → worker/task.d.ts} +0 -0
  104. /package/lib/ts/src/cloud/{task.js → worker/task.js} +0 -0
  105. /package/lib/ts/src/{encryption → mina/encryption}/client.d.ts +0 -0
  106. /package/lib/ts/src/{encryption → mina/encryption}/client.js +0 -0
  107. /package/lib/ts/src/{encryption → mina/encryption}/connections.d.ts +0 -0
  108. /package/lib/ts/src/{encryption → mina/encryption}/connections.js +0 -0
  109. /package/lib/ts/src/{encryption → mina/encryption}/encryption.d.ts +0 -0
  110. /package/lib/ts/src/{encryption → mina/encryption}/encryption.js +0 -0
  111. /package/lib/ts/src/{encryption → mina/encryption}/index.d.ts +0 -0
  112. /package/lib/ts/src/{encryption → mina/encryption}/index.js +0 -0
  113. /package/lib/ts/src/{encryption → mina/encryption}/messages.d.ts +0 -0
  114. /package/lib/ts/src/{encryption → mina/encryption}/messages.js +0 -0
  115. /package/lib/ts/src/{utils → mina/utils}/base64.d.ts +0 -0
  116. /package/lib/ts/src/{utils → mina/utils}/base64.js +0 -0
  117. /package/lib/ts/src/{utils → mina/utils}/fee.d.ts +0 -0
  118. /package/lib/ts/src/{utils → mina/utils}/fetch.d.ts +0 -0
  119. /package/lib/ts/src/{utils → mina/utils}/fields.d.ts +0 -0
  120. /package/lib/ts/src/{utils → mina/utils}/fields.js +0 -0
  121. /package/lib/web/src/{config.d.ts → cloud/config.d.ts} +0 -0
  122. /package/lib/web/src/{config.js → cloud/config.js} +0 -0
  123. /package/lib/web/src/{networks.d.ts → cloud/networks.d.ts} +0 -0
  124. /package/lib/web/src/{networks.js → cloud/networks.js} +0 -0
  125. /package/lib/web/src/cloud/{files.d.ts → utils/files.d.ts} +0 -0
  126. /package/lib/web/src/cloud/{files.js → utils/files.js} +0 -0
  127. /package/lib/web/src/{utils → cloud/utils}/graphql.d.ts +0 -0
  128. /package/lib/web/src/{utils → cloud/utils}/graphql.js +0 -0
  129. /package/lib/web/src/{utils → cloud/utils}/utils.d.ts +0 -0
  130. /package/lib/web/src/{utils → cloud/utils}/utils.js +0 -0
  131. /package/lib/web/src/cloud/{cloud.d.ts → worker/cloud.d.ts} +0 -0
  132. /package/lib/web/src/cloud/{cloud.js → worker/cloud.js} +0 -0
  133. /package/lib/web/src/cloud/{job.d.ts → worker/job.d.ts} +0 -0
  134. /package/lib/web/src/cloud/{job.js → worker/job.js} +0 -0
  135. /package/lib/web/src/cloud/{task.d.ts → worker/task.d.ts} +0 -0
  136. /package/lib/web/src/cloud/{task.js → worker/task.js} +0 -0
  137. /package/lib/web/src/{encryption → mina/encryption}/client.d.ts +0 -0
  138. /package/lib/web/src/{encryption → mina/encryption}/client.js +0 -0
  139. /package/lib/web/src/{encryption → mina/encryption}/connections.d.ts +0 -0
  140. /package/lib/web/src/{encryption → mina/encryption}/connections.js +0 -0
  141. /package/lib/web/src/{encryption → mina/encryption}/encryption.d.ts +0 -0
  142. /package/lib/web/src/{encryption → mina/encryption}/encryption.js +0 -0
  143. /package/lib/web/src/{encryption → mina/encryption}/index.d.ts +0 -0
  144. /package/lib/web/src/{encryption → mina/encryption}/index.js +0 -0
  145. /package/lib/web/src/{encryption → mina/encryption}/messages.d.ts +0 -0
  146. /package/lib/web/src/{encryption → mina/encryption}/messages.js +0 -0
  147. /package/lib/web/src/{utils → mina/utils}/base64.d.ts +0 -0
  148. /package/lib/web/src/{utils → mina/utils}/base64.js +0 -0
  149. /package/lib/web/src/{utils → mina/utils}/fee.d.ts +0 -0
  150. /package/lib/web/src/{utils → mina/utils}/fetch.d.ts +0 -0
  151. /package/lib/web/src/{utils → mina/utils}/fields.d.ts +0 -0
  152. /package/lib/web/src/{utils → mina/utils}/fields.js +0 -0
@@ -1,5 +1,4 @@
1
- export * from "./cloud";
2
- export * from "./files";
3
- export * from "./job";
4
- export * from "./task";
5
- export * from "./local";
1
+ export * from "./utils";
2
+ export * from "./worker";
3
+ export * from "./config";
4
+ export * from "./networks";
@@ -14,8 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./cloud"), exports);
18
- __exportStar(require("./files"), exports);
19
- __exportStar(require("./job"), exports);
20
- __exportStar(require("./task"), exports);
21
- __exportStar(require("./local"), exports);
17
+ __exportStar(require("./utils"), exports);
18
+ __exportStar(require("./worker"), exports);
19
+ __exportStar(require("./config"), exports);
20
+ __exportStar(require("./networks"), exports);
@@ -0,0 +1,3 @@
1
+ export * from "./files";
2
+ export * from "./graphql";
3
+ export * from "./utils";
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./files"), exports);
18
+ __exportStar(require("./graphql"), exports);
19
+ __exportStar(require("./utils"), exports);
@@ -0,0 +1,3 @@
1
+ export * from "./cloud";
2
+ export * from "./job";
3
+ export * from "./task";
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./cloud"), exports);
18
+ __exportStar(require("./job"), exports);
19
+ __exportStar(require("./task"), exports);
@@ -1,5 +1,2 @@
1
- export * from "./api/api";
2
1
  export * from "./cloud";
3
- export * from "./networks";
4
- export * from "./encryption";
5
- export * from "./utils";
2
+ export * from "./mina";
@@ -14,8 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./api/api"), exports);
18
17
  __exportStar(require("./cloud"), exports);
19
- __exportStar(require("./networks"), exports);
20
- __exportStar(require("./encryption"), exports);
21
- __exportStar(require("./utils"), exports);
18
+ __exportStar(require("./mina"), exports);
@@ -1,5 +1,5 @@
1
- import { zkCloudWorker, Cloud } from "../cloud/cloud";
2
- import { blockchain } from "../networks";
1
+ import { zkCloudWorker, Cloud } from "../../cloud/worker";
2
+ import { blockchain } from "../../cloud/networks";
3
3
  /**
4
4
  * The APICommand type for interacting with the zkCloudWorker
5
5
  * @typedef { "recursiveProof" | "execute" | "sendTransactions" | "jobResult" | "deploy" | "getBalance" | "queryBilling" } ApiCommand
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.zkCloudWorkerClient = void 0;
7
7
  const axios_1 = __importDefault(require("axios"));
8
8
  const chalk_1 = __importDefault(require("chalk"));
9
- const utils_1 = require("../utils/utils");
10
- const local_1 = require("../cloud/local");
11
- const config_1 = __importDefault(require("../config"));
9
+ const utils_1 = require("../../cloud/utils");
10
+ const local_1 = require("../local/local");
11
+ const config_1 = __importDefault(require("../../cloud/config"));
12
12
  const { ZKCLOUDWORKER_AUTH, ZKCLOUDWORKER_API } = config_1.default;
13
13
  /**
14
14
  * API class for interacting with the zkCloudWorker
@@ -0,0 +1,4 @@
1
+ export * from "./api/api";
2
+ export * from "./encryption";
3
+ export * from "./utils";
4
+ export * from "./local/local";
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./api/api"), exports);
18
+ __exportStar(require("./encryption"), exports);
19
+ __exportStar(require("./utils"), exports);
20
+ __exportStar(require("./local/local"), exports);
@@ -1,9 +1,9 @@
1
1
  /// <reference types="node" />
2
- import { Cloud, zkCloudWorker } from "./cloud";
3
- import { JobData } from "./job";
4
- import { TaskData } from "./task";
5
- import { blockchain } from "../networks";
6
- import { CloudTransaction, DeployerKeyPair } from "./cloud";
2
+ import { Cloud, zkCloudWorker } from "../../cloud";
3
+ import { JobData } from "../../cloud";
4
+ import { TaskData } from "../../cloud";
5
+ import { blockchain } from "../../cloud";
6
+ import { CloudTransaction, DeployerKeyPair } from "../../cloud";
7
7
  import { ApiCommand } from "../api/api";
8
8
  /**
9
9
  * LocalCloud is a cloud that runs on the local machine for testing and development
@@ -93,13 +93,6 @@ export declare class LocalCloud extends Cloud {
93
93
  * @param params the parameters to run the worker
94
94
  * @param params.command the command to run
95
95
  * @param params.data the data to use
96
- * @param params.data.developer the developer of the repo
97
- * @param params.data.repo the repo
98
- * @param params.data.transactions the transactions to process
99
- * @param params.data.task the task to execute
100
- * @param params.data.userId the user id
101
- * @param params.data.args the arguments for the job
102
- * @param params.data.metadata the metadata for the job
103
96
  * @param params.chain the blockchain to execute the job on
104
97
  * @param params.localWorker the worker to execute the tasks
105
98
  * @returns the job id
@@ -203,13 +196,6 @@ export declare class LocalCloud extends Cloud {
203
196
  * @param params the parameters to run the sequencer
204
197
  * @param params.worker the worker to execute the tasks
205
198
  * @param params.data the data to use
206
- * @param params.data.developer the developer of the repo
207
- * @param params.data.repo the repo
208
- * @param params.data.transactions the transactions to process
209
- * @param params.data.task the task to execute
210
- * @param params.data.userId the user id
211
- * @param params.data.args the arguments for the job
212
- * @param params.data.metadata the metadata for the job
213
199
  * @returns the proof
214
200
  */
215
201
  static sequencer(params: {
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.LocalStorage = exports.LocalCloud = void 0;
4
- const cloud_1 = require("./cloud");
5
- const utils_1 = require("../utils/utils");
6
- const files_1 = require("./files");
4
+ const cloud_1 = require("../../cloud");
5
+ const cloud_2 = require("../../cloud");
6
+ const cloud_3 = require("../../cloud");
7
7
  /**
8
8
  * LocalCloud is a cloud that runs on the local machine for testing and development
9
9
  * It uses LocalStorage to store jobs, tasks, transactions, and data
@@ -93,7 +93,7 @@ class LocalCloud extends cloud_1.Cloud {
93
93
  * @param value the value to save
94
94
  */
95
95
  async saveFile(filename, value) {
96
- await (0, files_1.saveBinaryFile)({ data: value, filename });
96
+ await (0, cloud_3.saveBinaryFile)({ data: value, filename });
97
97
  }
98
98
  /**
99
99
  * Loads the file
@@ -101,7 +101,7 @@ class LocalCloud extends cloud_1.Cloud {
101
101
  * @returns the file data
102
102
  */
103
103
  async loadFile(filename) {
104
- const data = await (0, files_1.loadBinaryFile)(filename);
104
+ const data = await (0, cloud_3.loadBinaryFile)(filename);
105
105
  return data;
106
106
  }
107
107
  /**
@@ -116,7 +116,7 @@ class LocalCloud extends cloud_1.Cloud {
116
116
  * @returns generated unique id
117
117
  */
118
118
  static generateId() {
119
- return "local." + Date.now().toString() + "." + (0, utils_1.makeString)(32);
119
+ return "local." + Date.now().toString() + "." + (0, cloud_2.makeString)(32);
120
120
  }
121
121
  /**
122
122
  * Adds transactions to the local cloud
@@ -158,13 +158,6 @@ class LocalCloud extends cloud_1.Cloud {
158
158
  * @param params the parameters to run the worker
159
159
  * @param params.command the command to run
160
160
  * @param params.data the data to use
161
- * @param params.data.developer the developer of the repo
162
- * @param params.data.repo the repo
163
- * @param params.data.transactions the transactions to process
164
- * @param params.data.task the task to execute
165
- * @param params.data.userId the user id
166
- * @param params.data.args the arguments for the job
167
- * @param params.data.metadata the metadata for the job
168
161
  * @param params.chain the blockchain to execute the job on
169
162
  * @param params.localWorker the worker to execute the tasks
170
163
  * @returns the job id
@@ -386,13 +379,6 @@ class LocalCloud extends cloud_1.Cloud {
386
379
  * @param params the parameters to run the sequencer
387
380
  * @param params.worker the worker to execute the tasks
388
381
  * @param params.data the data to use
389
- * @param params.data.developer the developer of the repo
390
- * @param params.data.repo the repo
391
- * @param params.data.transactions the transactions to process
392
- * @param params.data.task the task to execute
393
- * @param params.data.userId the user id
394
- * @param params.data.args the arguments for the job
395
- * @param params.data.metadata the metadata for the job
396
382
  * @returns the proof
397
383
  */
398
384
  static async sequencer(params) {
@@ -440,7 +426,7 @@ class LocalStorage {
440
426
  tasks: LocalStorage.tasks,
441
427
  };
442
428
  const filename = name + ".cloud";
443
- await (0, files_1.saveFile)({ data, filename });
429
+ await (0, cloud_3.saveFile)({ data, filename });
444
430
  }
445
431
  /**
446
432
  * Loads the data
@@ -448,7 +434,7 @@ class LocalStorage {
448
434
  */
449
435
  static async loadData(name) {
450
436
  const filename = name + ".cloud";
451
- const data = await (0, files_1.loadFile)(filename);
437
+ const data = await (0, cloud_3.loadFile)(filename);
452
438
  if (data === undefined)
453
439
  return;
454
440
  LocalStorage.jobs = data.jobs;
@@ -5,7 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.fee = void 0;
7
7
  const o1js_1 = require("o1js");
8
- const config_1 = __importDefault(require("../config"));
8
+ const config_1 = __importDefault(require("../../cloud/config"));
9
9
  /**
10
10
  * Calculate the fee for a transaction
11
11
  * @returns the fee for a transaction
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.checkMinaZkappTransaction = exports.fetchMinaActions = exports.fetchMinaAccount = void 0;
4
4
  const o1js_1 = require("o1js");
5
- const utils_1 = require("./utils");
5
+ const cloud_1 = require("../../cloud");
6
6
  /**
7
7
  * Fetches the Mina account for a given public key with error handling
8
8
  * @param params the parameters for fetching the account
@@ -42,7 +42,7 @@ async function fetchMinaAccount(params) {
42
42
  return result;
43
43
  }
44
44
  }
45
- await (0, utils_1.sleep)(1000 * 5);
45
+ await (0, cloud_1.sleep)(1000 * 5);
46
46
  }
47
47
  if (force === true)
48
48
  throw new Error(`fetchMinaAccount timeout
@@ -80,7 +80,7 @@ async function fetchMinaActions(publicKey, fromActionState, endActionState) {
80
80
  catch (error) {
81
81
  console.log("Error in fetchMinaActions", error.toString().substring(0, 300));
82
82
  }
83
- await (0, utils_1.sleep)(1000 * 60 * 2);
83
+ await (0, cloud_1.sleep)(1000 * 60 * 2);
84
84
  }
85
85
  console.log("Timeout in fetchMinaActions");
86
86
  return undefined;
@@ -1,7 +1,5 @@
1
1
  export * from "./base64";
2
2
  export * from "./fetch";
3
3
  export * from "./fields";
4
- export * from "./graphql";
5
4
  export * from "./fee";
6
5
  export * from "./mina";
7
- export * from "./utils";
@@ -17,7 +17,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./base64"), exports);
18
18
  __exportStar(require("./fetch"), exports);
19
19
  __exportStar(require("./fields"), exports);
20
- __exportStar(require("./graphql"), exports);
21
20
  __exportStar(require("./fee"), exports);
22
21
  __exportStar(require("./mina"), exports);
23
- __exportStar(require("./utils"), exports);
@@ -1,6 +1,6 @@
1
1
  export { initBlockchain, accountBalance, accountBalanceMina, MinaNetworkInstance, currentNetwork, getNetworkIdHash, getCurrentNetwork, getDeployer, };
2
2
  import { Mina, PublicKey, UInt64, Field } from "o1js";
3
- import { blockchain, MinaNetwork } from "../networks";
3
+ import { blockchain, MinaNetwork } from "../../cloud";
4
4
  /**
5
5
  * MinaNetworkInstance is the data structure for a Mina network instance, keeping track of the keys, network, and network id hash
6
6
  * @param keys the keys for the deployers
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getDeployer = exports.getCurrentNetwork = exports.getNetworkIdHash = exports.currentNetwork = exports.accountBalanceMina = exports.accountBalance = exports.initBlockchain = void 0;
4
4
  const o1js_1 = require("o1js");
5
- const networks_1 = require("../networks");
5
+ const cloud_1 = require("../../cloud");
6
6
  let currentNetwork = undefined;
7
7
  exports.currentNetwork = currentNetwork;
8
8
  function getNetworkIdHash() {
@@ -59,12 +59,12 @@ async function initBlockchain(instance, deployersNumber = 0) {
59
59
  throw new Error("Not enough test accounts");
60
60
  exports.currentNetwork = currentNetwork = {
61
61
  keys: local.testAccounts,
62
- network: networks_1.Local,
62
+ network: cloud_1.Local,
63
63
  networkIdHash,
64
64
  };
65
65
  return currentNetwork;
66
66
  }
67
- const network = networks_1.networks.find((n) => n.chainId === instance);
67
+ const network = cloud_1.networks.find((n) => n.chainId === instance);
68
68
  if (network === undefined) {
69
69
  throw new Error("Unknown network");
70
70
  }