From 33380bfedd517a7314965990226c56e4826e1e1c Mon Sep 17 00:00:00 2001 From: Jerome Simeon Date: Thu, 1 Apr 2021 10:08:54 -0400 Subject: [PATCH] feature(1.0) New based models for AP + Concerto 1.0 switch Signed-off-by: Jerome Simeon --- build.js | 2 +- package-lock.json | 328 ++++------------------------ package.json | 4 +- src/accordproject/contract.cto | 38 ++++ src/accordproject/obligation.cto | 35 +++ src/accordproject/runtime.cto | 57 +++++ src/cicero/runtime@0.2.0.cto | 83 ------- src/docusign/connect@0.3.0.cto | 4 +- src/markdown/ciceromark@0.3.1.cto | 4 +- src/markdown/templatemark@0.1.1.cto | 4 +- src/payment/payment@0.2.0.cto | 5 +- src/signature/block@0.2.0.cto | 28 +++ src/signature/signature@0.2.0.cto | 12 +- 13 files changed, 219 insertions(+), 385 deletions(-) create mode 100644 src/accordproject/contract.cto create mode 100644 src/accordproject/obligation.cto create mode 100644 src/accordproject/runtime.cto delete mode 100644 src/cicero/runtime@0.2.0.cto create mode 100644 src/signature/block@0.2.0.cto diff --git a/build.js b/build.js index 48789ab..c5f7299 100644 --- a/build.js +++ b/build.js @@ -299,7 +299,7 @@ function isCompatible(concertoVersion, modelText) { } } else { - console.log(`✋ Skipped ${file} due to incompatability.`); + console.log(`✋ Skipped ${file} due to incompatibility.`); } }; // for diff --git a/package-lock.json b/package-lock.json index 2ed7f28..90ca2f7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5,29 +5,28 @@ "requires": true, "dependencies": { "@accordproject/concerto-core": { - "version": "0.82.11", - "resolved": "https://registry.npmjs.org/@accordproject/concerto-core/-/concerto-core-0.82.11.tgz", - "integrity": "sha512-65gZqlC3NqfGsZ68H9a97U96EDdUA4bW5achtqkv/W2YvL2LU1is+FUkoQFNFltpZJp9KfitUqFC0SQ84sAHAA==", + "version": "1.0.0-alpha.3", + "resolved": "https://registry.npmjs.org/@accordproject/concerto-core/-/concerto-core-1.0.0-alpha.3.tgz", + "integrity": "sha512-TmyHqHX98g5vNJP9kr4LOPdMRUTFfs0ZXIAhH8wmGZhf+VGCS4QrB36xQiEl5WM0vshqRiL3CxzhAs3qwSod8A==", "requires": { - "axios": "0.19.0", + "axios": "0.21.1", + "colors": "1.4.0", + "dayjs": "1.10.2", "debug": "4.1.1", - "fast-safe-stringify": "2.0.7", "jsome": "2.5.0", "lorem-ipsum": "1.0.6", - "moment-mini": "2.22.1", + "randexp": "0.5.3", "slash": "3.0.0", - "triple-beam": "1.3.0", - "urijs": "1.19.1", - "uuid": "3.3.2", - "winston": "3.2.1" + "urijs": "1.19.6", + "uuid": "3.3.2" } }, "@accordproject/concerto-tools": { - "version": "0.82.11", - "resolved": "https://registry.npmjs.org/@accordproject/concerto-tools/-/concerto-tools-0.82.11.tgz", - "integrity": "sha512-v7fpt9tcXNxG8NA0hpve2L23fvHryS6A6j4D8XKchYZT3Ym3YkJHkHr9lKmY9E1qyCj84BLIsJV6bbGHZmzrcw==", + "version": "1.0.0-alpha.3", + "resolved": "https://registry.npmjs.org/@accordproject/concerto-tools/-/concerto-tools-1.0.0-alpha.3.tgz", + "integrity": "sha512-UqJqzSQ26RISXV355wYFEasHwizZrqsU6kcfN8e7OOF/p5HoQT4AllEh42hwVKLAiVJObBCk47lVrY8IR0zP4Q==", "requires": { - "@accordproject/concerto-core": "0.82.11", + "@accordproject/concerto-core": "1.0.0-alpha.3", "debug": "4.1.1", "mkdirp": "0.5.1", "yargs": "13.2.4" @@ -214,21 +213,12 @@ "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz", "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY=" }, - "async": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/async/-/async-2.6.3.tgz", - "integrity": "sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==", - "requires": { - "lodash": "^4.17.14" - } - }, "axios": { - "version": "0.19.0", - "resolved": "https://registry.npmjs.org/axios/-/axios-0.19.0.tgz", - "integrity": "sha512-1uvKqKQta3KBxIz14F2v06AEHZ/dIoeKfbTRkK1E5oqjDnuEerLmYTgJB5AiQZHJcljpg1TuRzdjDR06qNk0DQ==", + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.1.tgz", + "integrity": "sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA==", "requires": { - "follow-redirects": "1.5.10", - "is-buffer": "^2.0.2" + "follow-redirects": "^1.10.0" } }, "balanced-match": { @@ -311,15 +301,6 @@ "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" }, - "color": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/color/-/color-3.0.0.tgz", - "integrity": "sha512-jCpd5+s0s0t7p3pHQKpnJ0TpQKKdleP71LWcA0aqiljpiuAkOSUFN/dyH8ZwF0hRmFlrIuRhufds1QyEP9EB+w==", - "requires": { - "color-convert": "^1.9.1", - "color-string": "^1.5.2" - } - }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -333,34 +314,11 @@ "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" }, - "color-string": { - "version": "1.5.4", - "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.5.4.tgz", - "integrity": "sha512-57yF5yt8Xa3czSEW1jfQDE79Idk0+AkN/4KWad6tbdxUmAs3MvjxlWSWD4deYytcRfoZ9nhKyFl1kj5tBvidbw==", - "requires": { - "color-name": "^1.0.0", - "simple-swizzle": "^0.2.2" - } - }, - "colornames": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/colornames/-/colornames-1.1.1.tgz", - "integrity": "sha1-+IiQMGhcfE/54qVZ9Qd+t2qBb5Y=" - }, "colors": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==" }, - "colorspace": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/colorspace/-/colorspace-1.1.2.tgz", - "integrity": "sha512-vt+OoIP2d76xLhjwbBaucYlNSpPsrJWPlBTtwCpQKIu6/CSMutyzX93O/Do0qzpH3YoHEes8YEFXyZ797rEhzQ==", - "requires": { - "color": "3.0.x", - "text-hex": "1.0.x" - } - }, "commander": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/commander/-/commander-5.1.0.tgz", @@ -371,11 +329,6 @@ "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, - "core-util-is": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", - "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" - }, "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", @@ -395,19 +348,17 @@ } } }, + "dayjs": { + "version": "1.10.2", + "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.10.2.tgz", + "integrity": "sha512-h/YtykNNTR8Qgtd1Fxl5J1/SFP1b7SOk/M1P+Re+bCdFMV0IMkuKNgHPN7rlvvuhfw24w0LX78iYKt4YmePJNQ==" + }, "debug": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", "integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==", "requires": { "ms": "^2.1.1" - }, - "dependencies": { - "ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" - } } }, "decamelize": { @@ -415,29 +366,16 @@ "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" }, - "diagnostics": { + "drange": { "version": "1.1.1", - "resolved": "https://registry.npmjs.org/diagnostics/-/diagnostics-1.1.1.tgz", - "integrity": "sha512-8wn1PmdunLJ9Tqbx+Fx/ZEuHfJf4NKSN2ZBj7SJC/OWRWha843+WsTjqMe1B5E3p28jqBlp+mJ2fPVxPyNgYKQ==", - "requires": { - "colorspace": "1.1.x", - "enabled": "1.0.x", - "kuler": "1.0.x" - } + "resolved": "https://registry.npmjs.org/drange/-/drange-1.1.1.tgz", + "integrity": "sha512-pYxfDYpued//QpnLIm4Avk7rsNtAtQkUES2cwAYSvD/wd2pKD71gN2Ebj3e7klzXwjocvE8c5vx/1fxwpqmSxA==" }, "emoji-regex": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==" }, - "enabled": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/enabled/-/enabled-1.0.2.tgz", - "integrity": "sha1-ll9lE9LC0cX0ZStkouM5ZGf8L5M=", - "requires": { - "env-variable": "0.0.x" - } - }, "end-of-stream": { "version": "1.4.4", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", @@ -446,11 +384,6 @@ "once": "^1.4.0" } }, - "env-variable": { - "version": "0.0.6", - "resolved": "https://registry.npmjs.org/env-variable/-/env-variable-0.0.6.tgz", - "integrity": "sha512-bHz59NlBbtS0NhftmR8+ExBEekE7br0e01jw+kk0NDro7TtZzBYZ5ScGPs3OmwnpyfHTHOtr1Y6uedCdrIldtg==" - }, "escape-string-regexp": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", @@ -470,16 +403,6 @@ "strip-eof": "^1.0.0" } }, - "fast-safe-stringify": { - "version": "2.0.7", - "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.0.7.tgz", - "integrity": "sha512-Utm6CdzT+6xsDk2m8S6uL8VHxNwI6Jub+e9NYTcAms28T84pTa25GJQV9j0CY0N1rM8hK4x6grpF2BQf+2qwVA==" - }, - "fecha": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/fecha/-/fecha-4.2.0.tgz", - "integrity": "sha512-aN3pcx/DSmtyoovUudctc8+6Hl4T+hI9GBBHLjA76jdZl7+b1sgh5g4k+u/GL3dTy1/pnYzKp69FpJ0OicE3Wg==" - }, "fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", @@ -498,22 +421,9 @@ } }, "follow-redirects": { - "version": "1.5.10", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.5.10.tgz", - "integrity": "sha512-0V5l4Cizzvqt5D44aTXbFZz+FtyXV1vrDN6qrelxtfYQKW0KO0W2T/hkE8xvGa/540LkZlkaUjO4ailYTFtHVQ==", - "requires": { - "debug": "=3.1.0" - }, - "dependencies": { - "debug": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", - "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", - "requires": { - "ms": "2.0.0" - } - } - } + "version": "1.13.3", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.3.tgz", + "integrity": "sha512-DUgl6+HDzB0iEptNQEXLx/KhTmDb8tZUHSeLqpnjpknR70H0nC2t9N73BK6fN4hOvJ84pKlIQVQ4k5FFlBedKA==" }, "fs-extra": { "version": "6.0.1", @@ -600,11 +510,6 @@ "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" }, - "is-arrayish": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", - "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==" - }, "is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -614,11 +519,6 @@ "binary-extensions": "^2.0.0" } }, - "is-buffer": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-2.0.5.tgz", - "integrity": "sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==" - }, "is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", @@ -650,11 +550,6 @@ "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" }, - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" - }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", @@ -683,14 +578,6 @@ "graceful-fs": "^4.1.6" } }, - "kuler": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/kuler/-/kuler-1.0.1.tgz", - "integrity": "sha512-J9nVUucG1p/skKul6DU3PUZrhs0LPulNaeUOox0IyXDi8S4CztTHs1gQphhuZmzXG7VOQSf6NJfKuzteQLv9gQ==", - "requires": { - "colornames": "^1.1.1" - } - }, "lcid": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", @@ -713,25 +600,6 @@ "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", "integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==" }, - "logform": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/logform/-/logform-2.2.0.tgz", - "integrity": "sha512-N0qPlqfypFx7UHNn4B3lzS/b0uLqt2hmuoa+PpuXNYgozdJYAyauF5Ky0BWVjrxDlMWiT3qN4zPq3vVAfZy7Yg==", - "requires": { - "colors": "^1.2.1", - "fast-safe-stringify": "^2.0.4", - "fecha": "^4.2.0", - "ms": "^2.1.1", - "triple-beam": "^1.3.0" - }, - "dependencies": { - "ms": { - "version": "2.1.3", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" - } - } - }, "lorem-ipsum": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/lorem-ipsum/-/lorem-ipsum-1.0.6.tgz", @@ -784,15 +652,10 @@ "minimist": "^1.2.5" } }, - "moment-mini": { - "version": "2.22.1", - "resolved": "https://registry.npmjs.org/moment-mini/-/moment-mini-2.22.1.tgz", - "integrity": "sha512-OUCkHOz7ehtNMYuZjNciXUfwTuz8vmF1MTbAy59ebf+ZBYZO5/tZKuChVWCX+uDo+4idJBpGltNfV8st+HwsGw==" - }, "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" }, "nice-try": { "version": "1.0.5", @@ -837,11 +700,6 @@ "wrappy": "1" } }, - "one-time": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/one-time/-/one-time-0.0.4.tgz", - "integrity": "sha1-+M33eISCb+Tf+T46nMN7HkSAdC4=" - }, "os-locale": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", @@ -914,11 +772,6 @@ "resolved": "https://registry.npmjs.org/plantuml-encoder/-/plantuml-encoder-1.4.0.tgz", "integrity": "sha512-sxMwpDw/ySY1WB2CE3+IdMuEcWibJ72DDOsXLkSmEaSzwEUaYBT6DWgOfBiHGCux4q433X6+OEFWjlVqp7gL6g==" }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" - }, "pump": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", @@ -928,14 +781,13 @@ "once": "^1.3.1" } }, - "readable-stream": { - "version": "3.6.0", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.0.tgz", - "integrity": "sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==", + "randexp": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/randexp/-/randexp-0.5.3.tgz", + "integrity": "sha512-U+5l2KrcMNOUPYvazA3h5ekF80FHTUG+87SEAmHZmolh1M+i/WyTCxVzmi+tidIa1tM4BSe8g2Y/D3loWDjj+w==", "requires": { - "inherits": "^2.0.3", - "string_decoder": "^1.1.1", - "util-deprecate": "^1.0.1" + "drange": "^1.0.2", + "ret": "^0.2.0" } }, "readdirp": { @@ -957,6 +809,11 @@ "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz", "integrity": "sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE=" }, + "ret": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/ret/-/ret-0.2.2.tgz", + "integrity": "sha512-M0b3YWQs7R3Z917WRQy1HHA7Ba7D8hvZg6UE5mLykJxQVE2ju0IXbGlaHPPlkY+WN7wFP+wUMXmBFA0aV6vYGQ==" + }, "rimraf": { "version": "2.7.1", "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", @@ -965,11 +822,6 @@ "glob": "^7.1.3" } }, - "safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" - }, "semver": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", @@ -1136,24 +988,11 @@ "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==" }, - "simple-swizzle": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", - "integrity": "sha1-pNprY1/8zMoz9w0Xy5JZLeleVXo=", - "requires": { - "is-arrayish": "^0.3.1" - } - }, "slash": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==" }, - "stack-trace": { - "version": "0.0.10", - "resolved": "https://registry.npmjs.org/stack-trace/-/stack-trace-0.0.10.tgz", - "integrity": "sha1-VHxws0fo0ytOEI6hoqFZ5f3eGcA=" - }, "string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", @@ -1163,14 +1002,6 @@ "strip-ansi": "^4.0.0" } }, - "string_decoder": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", - "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", - "requires": { - "safe-buffer": "~5.2.0" - } - }, "strip-ansi": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", @@ -1192,11 +1023,6 @@ "has-flag": "^3.0.0" } }, - "text-hex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/text-hex/-/text-hex-1.0.0.tgz", - "integrity": "sha512-uuVGNWzgJ4yhRaNSiubPY7OjISw4sw4E5Uv0wbjp+OzcbmVU/rsT8ujgcXJhn9ypzsgr5vlzpPqP+MBBKcGvbg==" - }, "to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", @@ -1206,25 +1032,15 @@ "is-number": "^7.0.0" } }, - "triple-beam": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/triple-beam/-/triple-beam-1.3.0.tgz", - "integrity": "sha512-XrHUvV5HpdLmIj4uVMxHggLbFSZYIn7HEWsqePZcI50pco+MPqJ50wMGY794X7AOOhxOBAjbkqfAbEe/QMp2Lw==" - }, "universalify": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==" }, "urijs": { - "version": "1.19.1", - "resolved": "https://registry.npmjs.org/urijs/-/urijs-1.19.1.tgz", - "integrity": "sha512-xVrGVi94ueCJNrBSTjWqjvtgvl3cyOTThp2zaMaFNGp3F542TR6sM3f2o8RqZl+AwteClSVmoCyt0ka4RjQOQg==" - }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + "version": "1.19.6", + "resolved": "https://registry.npmjs.org/urijs/-/urijs-1.19.6.tgz", + "integrity": "sha512-eSXsXZ2jLvGWeLYlQA3Gh36BcjF+0amo92+wHPyN1mdR8Nxf75fuEuYTd9c0a+m/vhCjRK0ESlE9YNLW+E1VEw==" }, "uuid": { "version": "3.3.2", @@ -1244,60 +1060,6 @@ "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" }, - "winston": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/winston/-/winston-3.2.1.tgz", - "integrity": "sha512-zU6vgnS9dAWCEKg/QYigd6cgMVVNwyTzKs81XZtTFuRwJOcDdBg7AU0mXVyNbs7O5RH2zdv+BdNZUlx7mXPuOw==", - "requires": { - "async": "^2.6.1", - "diagnostics": "^1.1.1", - "is-stream": "^1.1.0", - "logform": "^2.1.1", - "one-time": "0.0.4", - "readable-stream": "^3.1.1", - "stack-trace": "0.0.x", - "triple-beam": "^1.3.0", - "winston-transport": "^4.3.0" - } - }, - "winston-transport": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/winston-transport/-/winston-transport-4.4.0.tgz", - "integrity": "sha512-Lc7/p3GtqtqPBYYtS6KCN3c77/2QCev51DvcJKbkFPQNoj1sinkGwLGFDxkXY9J6p9+EPnYs+D90uwbnaiURTw==", - "requires": { - "readable-stream": "^2.3.7", - "triple-beam": "^1.2.0" - }, - "dependencies": { - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, - "safe-buffer": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", - "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "requires": { - "safe-buffer": "~5.1.0" - } - } - } - }, "wrap-ansi": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", diff --git a/package.json b/package.json index 73d35b7..36a8f6f 100644 --- a/package.json +++ b/package.json @@ -7,8 +7,8 @@ "npm": ">=5" }, "dependencies": { - "@accordproject/concerto-core": "^0.82.11", - "@accordproject/concerto-tools": "^0.82.11", + "@accordproject/concerto-core": "1.0.0-alpha.3", + "@accordproject/concerto-tools": "1.0.0-alpha.3", "adm-zip": "^0.4.16", "bulma": "^0.7.5", "fs-extra": "^6.0.1", diff --git a/src/accordproject/contract.cto b/src/accordproject/contract.cto new file mode 100644 index 0000000..a561ed4 --- /dev/null +++ b/src/accordproject/contract.cto @@ -0,0 +1,38 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// requires: concerto-core:>= 1.0.0-alpha.3 + +namespace org.accordproject.contract + +/** + * Contract Data + * -- Describes the structure of contracts and clauses + */ + +/* A party to a contract */ +participant Party identified by partyId { + o String partyId +} + +/* A contract is a asset -- This contains the contract data */ +abstract asset ContractData identified by contractId { + o String contractId + --> Party[] parties optional +} + +/* A clause is an asset -- This contains the clause data */ +abstract asset ClauseData identified by clauseId { + o String clauseId +} diff --git a/src/accordproject/obligation.cto b/src/accordproject/obligation.cto new file mode 100644 index 0000000..688b6b9 --- /dev/null +++ b/src/accordproject/obligation.cto @@ -0,0 +1,35 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// requires: concerto-core:>= 1.0.0-alpha.3 + +namespace org.accordproject.obligation + +import org.accordproject.runtime.Obligation from https://concerto-1-0--accordproject-models.netlify.com/accordproject/runtime.cto +import org.accordproject.money.MonetaryAmount from https://concerto-1-0--accordproject-models.netlify.com/money@0.2.0.cto + +/** + * Useful Obligations + * -- Predefined obligations for general use in Accord Project templates + */ + +event PaymentObligation extends Obligation { + o MonetaryAmount amount + o String description +} + +event NotificationObligation extends Obligation { + o String title + o String message +} diff --git a/src/accordproject/runtime.cto b/src/accordproject/runtime.cto new file mode 100644 index 0000000..a2926ed --- /dev/null +++ b/src/accordproject/runtime.cto @@ -0,0 +1,57 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// requires: concerto-core:>= 1.0.0-alpha.3 + +namespace org.accordproject.runtime + +import org.accordproject.contract.Party from https://concerto-1-0--accordproject-models.netlify.com/accordproject/contract.cto +import org.accordproject.contract.ContractData from https://concerto-1-0--accordproject-models.netlify.com/accordproject/contract.cto + +/** + * Runtime API + * -- Describes input and output of calls to a contract's clause + */ + +/* A request is a transaction */ +transaction Request { +} + +/* A response is a transaction */ +transaction Response { +} + +/* An Error is a concept */ +abstract concept ErrorResponse { +} + +/* An event that represents an obligation that needs to be fulfilled */ +abstract event Obligation { + /* A back reference to the governing contract that emitted this obligation */ + --> ContractData contractData + + /* The party that is obligated */ + --> Party promisor + + /* The party that receives the performance */ + --> Party promisee + + /* The time before which the obligation is fulfilled */ + o DateTime deadline optional +} + +/* A contract state is an asset -- The runtime state of the contract */ +asset ContractState { + --> Obligation[] obligations // Should we allow for a standard way to store obligations on the contract in the state? +} diff --git a/src/cicero/runtime@0.2.0.cto b/src/cicero/runtime@0.2.0.cto deleted file mode 100644 index 1b97448..0000000 --- a/src/cicero/runtime@0.2.0.cto +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// requires: concerto-core:>= 1.0.0-20210215133932 -namespace org.accordproject.cicero.runtime - -import org.accordproject.cicero.contract.AccordContract from https://models.accordproject.org/cicero/contract.cto -import org.accordproject.cicero.contract.AccordContractState from https://models.accordproject.org/cicero/contract.cto -import org.accordproject.money.MonetaryAmount from https://models.accordproject.org/money.cto -import concerto.Participant -import concerto.Event - -/** - * Contract API - * -- Describes input and output of calls to a contract's clause - */ - -/* A request is a transaction */ -transaction Request {} - -/* A response is a transaction */ -transaction Response {} - -/* An Error is a transaction */ -abstract transaction ErrorResponse {} - -/* An event that represents an obligation that needs to be fulfilled */ -abstract event Obligation { - /* A back reference to the governing contract that emitted this obligation */ - --> AccordContract contract - - /* The party that is obligated */ - --> Participant promisor optional // TODO make this mandatory once proper party support is in place - - /* The party that receives the performance */ - --> Participant promisee optional // TODO make this mandatory once proper party support is in place - - /* The time before which the obligation is fulfilled */ - o DateTime deadline optional -} - -event PaymentObligation extends Obligation{ - o MonetaryAmount amount - o String description -} - -event NotificationObligation extends Obligation { - o String title - o String message -} - -/* A payload has contract data, a request and a state */ -concept Payload { - o AccordContract contract // the contract data - o Request request - o AccordContractState state optional -} - -/* If the call to a contract's clause succeeds, it returns a response, a list of events and a new state */ -concept Success { - o Response response - o AccordContractState state - o Event[] emit -} -/* If the call to a contract's clause fails, it returns and error */ -concept Failure { - o ErrorResponse error -} - -/** - * The functional signature for a contract call is as follows: - * clausecall : String contractName -> String clauseName -> Payload payload -> Success | Failure - */ diff --git a/src/docusign/connect@0.3.0.cto b/src/docusign/connect@0.3.0.cto index 20ff180..cace1ec 100644 --- a/src/docusign/connect@0.3.0.cto +++ b/src/docusign/connect@0.3.0.cto @@ -11,14 +11,14 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -// requires: concerto-core:>= 1.0.0-20210215133932 +// requires: concerto-core:>= 1.0.0-alpha.3 /** * Based on https://www.docusign.net/api/3.0/schema/dsx.xsd */ namespace com.docusign.connect -import org.accordproject.cicero.runtime.Request from https://models.accordproject.org/cicero/runtime@0.2.0.cto +import org.accordproject.runtime.Request from https://concerto-1-0--accordproject-models.netlify.com/accordproject/runtime.cto import org.accordproject.binary.BinaryResource from https://models.accordproject.org/binary.cto enum EnvelopeStatusCode { diff --git a/src/markdown/ciceromark@0.3.1.cto b/src/markdown/ciceromark@0.3.1.cto index 0cb007d..8cae2e9 100644 --- a/src/markdown/ciceromark@0.3.1.cto +++ b/src/markdown/ciceromark@0.3.1.cto @@ -14,8 +14,8 @@ namespace org.accordproject.ciceromark -import org.accordproject.commonmark.Child from https://models.accordproject.org/markdown/commonmark@0.2.0.cto -import concerto.metamodel.Decorator from https://models.accordproject.org/concerto/metamodel.cto +import org.accordproject.commonmark.Child from https://concerto-1-0--accordproject-models.netlify.com/markdown/commonmark@0.2.0.cto +import concerto.metamodel.Decorator from https://concerto-1-0--accordproject-models.netlify.com/concerto/metamodel.cto /** * A model for Accord Project extensions to commonmark diff --git a/src/markdown/templatemark@0.1.1.cto b/src/markdown/templatemark@0.1.1.cto index b4da2a3..be2f162 100644 --- a/src/markdown/templatemark@0.1.1.cto +++ b/src/markdown/templatemark@0.1.1.cto @@ -14,8 +14,8 @@ namespace org.accordproject.templatemark -import org.accordproject.commonmark.Child from https://models.accordproject.org/markdown/commonmark@0.2.0.cto -import concerto.metamodel.Decorator from https://models.accordproject.org/concerto/metamodel.cto +import org.accordproject.commonmark.Child from https://concerto-1-0--accordproject-models.netlify.com/markdown/commonmark@0.2.0.cto +import concerto.metamodel.Decorator from https://concerto-1-0--accordproject-models.netlify.com/concerto/metamodel.cto /** * A model for Accord Project template extensions to commonmark diff --git a/src/payment/payment@0.2.0.cto b/src/payment/payment@0.2.0.cto index c594cd9..c487774 100644 --- a/src/payment/payment@0.2.0.cto +++ b/src/payment/payment@0.2.0.cto @@ -11,11 +11,10 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -// requires: concerto-core:>= 1.0.0-20210215133932 +// requires: concerto-core:>= 1.0.0-alpha.3 namespace org.accordproject.payment -import org.accordproject.cicero.runtime.Request from https://models.accordproject.org/cicero/runtime@0.2.0.cto -import org.accordproject.cicero.contract.AccordContract from https://models.accordproject.org/cicero/contract.cto +import org.accordproject.runtime.Request from https://concerto-1-0--accordproject-models.netlify.com/accordproject/runtime.cto /** * A request that indicates that a payment has been received diff --git a/src/signature/block@0.2.0.cto b/src/signature/block@0.2.0.cto new file mode 100644 index 0000000..aed33c3 --- /dev/null +++ b/src/signature/block@0.2.0.cto @@ -0,0 +1,28 @@ +/* + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +// requires: concerto-core:>= 1.0.0-alpha.3 +namespace org.accordproject.signature.block + +import org.accordproject.contract.ClauseData from https://concerto-1-0--accordproject-models.netlify.com/accordproject/contract.cto +import org.accordproject.contract.Party from https://concerto-1-0--accordproject-models.netlify.com/accordproject/contract.cto + +/** + * An abstract clause for a party scoped signature block + */ +abstract asset SignatureClause extends ClauseData { + @Pdf("style", "background") + @ContractEditor("readOnly", true, "opacity", 0) + --> Party signatory +} \ No newline at end of file diff --git a/src/signature/signature@0.2.0.cto b/src/signature/signature@0.2.0.cto index 31bc36d..a4cd116 100644 --- a/src/signature/signature@0.2.0.cto +++ b/src/signature/signature@0.2.0.cto @@ -11,17 +11,15 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -// requires: concerto-core:>= 1.0.0-20210215133932 +// requires: concerto-core:>= 1.0.0-alpha.3 namespace org.accordproject.signature -import org.accordproject.cicero.runtime.Request from https://models.accordproject.org/cicero/runtime@0.2.0.cto -import org.accordproject.cicero.contract.AccordContract from https://models.accordproject.org/cicero/contract.cto -import org.accordproject.cicero.contract.AccordClause from https://models.accordproject.org/cicero/contract.cto -import org.accordproject.cicero.contract.AccordParty from https://models.accordproject.org/cicero/contract.cto +import org.accordproject.runtime.Request from https://concerto-1-0--accordproject-models.netlify.com/accordproject/runtime.cto +import org.accordproject.contract.ContractData from https://concerto-1-0--accordproject-models.netlify.com/accordproject/contract.cto /** * A request that indicates that a contract has been signed by all parties */ transaction ContractSigned extends Request { - --> AccordContract contract -} \ No newline at end of file + --> ContractData contract +}